Commit Graph
17 Commits
Author SHA1 Message Date
baldurk d520443fd3 Remove hackish tracking of VAO chunks, mark as dirty resource instead
* The VAO will then have initial contents grabbed and applied
2014-08-15 21:22:47 +01:00
baldurk deead1c90e Assert on record should only happen when writing 2014-08-15 18:57:27 +01:00
baldurk 5f206da36d Add hooks for vertex attrib format/binding functions 2014-08-15 16:09:53 +01:00
baldurk 56430387db Hook Vertex Buffer binding functions and save as initial state
* Vertex attrib state is a property of the VAO so should be saved as
  initial resource contents.
2014-08-15 14:26:13 +01:00
Baldur Karlsson 5e32950195 Change GLResource tuple to be three components including Context
* This lets us distinguish framebuffer object 1 on context A from
  FBO 1 on context B.
* At the moment we assume that all shareable objects are shared between
  all contexts. I think this is sensible and fairly common, but it will
  break if some contexts don't share as the objects will alias.
2014-06-27 13:24:19 +01:00
Baldur Karlsson 5cb6edffb8 For VAOs, track and deduplicate redundant chunks
* This is really a spot optimisation but I have a feeling it might be
  useful for more programs.
* If a program uses a single VAO and updates the attrib pointers/enables
  and disables them, then this will prevent an unbounded number of chunks
  building up pointlessly while READING and pushing into the record.
* A 'better' fix for this would be to gather pointer/enabled state as
  initial contents and not tracking any of this except for in CAPFRAME,
  but that isn't happening at the moment.
2014-06-27 13:13:46 +01:00
Baldur Karlsson dcf243ad63 Quick optimisation - detect case of glBufferData just to orphan 2014-06-24 16:00:29 +01:00
Baldur Karlsson 47ed54fa91 When capturing frame, track VAO modifications in context record 2014-06-24 16:00:28 +01:00
Baldur Karlsson b3ac0619ba Improve glMap() handling, handle non-invalidate case etc. 2014-06-24 16:00:28 +01:00
Baldur Karlsson f53f79c2ad Handle calls to bind 0 object (unbinding) 2014-06-24 16:00:17 +01:00
Baldur Karlsson 75495bda38 Set BufferRecords in the right spot, before serialising 2014-06-19 16:05:03 +01:00
Baldur Karlsson d568851994 Only look up live resource when not writing 2014-06-19 15:23:51 +01:00
Baldur Karlsson c9d8ab2dcf Add a few last buffer related hooks 2014-06-19 13:00:33 +01:00
Baldur Karlsson b345b9ceb7 Hook the EXT_direct_state_access functions.
* Normal selector functions are implemented via these, which requires
  EXT_direct_state_access to be available, but this isn't hard to work
  around with some wrapper functions should that become necessary.
2014-06-19 12:05:49 +01:00
Baldur Karlsson acb36a5308 A few more assorted functions wrapped.
* Also rearranged and organised the ProcessChunk() switch to match the
  enum in gl_common.h for easier reference
2014-06-18 17:23:07 +01:00
Baldur Karlsson eeadec99f6 Tidy up RDCUNIMPLEMENTED() macros, adding text comments to each 2014-06-18 16:08:21 +01:00
Baldur Karlsson 72de770e22 Tidy up wrapped functions and reorganise into logical files
* Remove legacy wrapped functions that were only hacked-in to get
  glxgears working as a proof of concept.
* Split out groups of wrapped functions into separate files by type
2014-06-18 15:19:56 +01:00