Commit Graph

157 Commits

Author SHA1 Message Date
baldurk 6cb65e8569 Handle SemanticName being NULL in D3D11_SO_DECLARATION_ENTRY
* NULL specifies that a gap should be made/skipped in the output data.
* This would crash before but now serialises NULL as "" since that's an
  invalid SemanticName (must be NULL or name a semantic). This will still
  read old logs fine but old programs will not do the right thing on new
  logs.
2014-07-05 12:49:14 +01:00
baldurk 344d927c03 Skip geometry shader streams > 0 for now. Referencing #27 2014-07-05 12:47:14 +01:00
baldurk c274169de3 Implement indexable temps in shader debugging.
* These often come up when you have an inline array that are dynamically
  indexed into (e.g. an array of offsets in a poisson disk used in a loop
  that isn't unrolled).
2014-07-04 22:52:04 +01:00
baldurk 7799f107f8 Can only have up to 2 double components in a vector 2014-07-04 22:51:05 +01:00
baldurk 8d73d24cab Handle matrices having each row/column padded out. Closes #69 2014-07-04 21:15:31 +01:00
baldurk 75353bd190 Add toggle to disable gamma 'correction' of linear data. Closes #58
* The explanation is in the FAQ but the short explanation is that most
  data e.g. normal maps are conventionally displayed as if they contained
  SRGB data, so RenderDoc does the same so things look as expected.
2014-07-04 17:02:11 +01:00
baldurk 0fbdcbc83c If a constant buffer is unused, open raw buffer viewer. Closes #60 2014-07-01 00:52:18 +01:00
baldurk 443ad1e967 Allow choosing background display even for no alpha. Closes #69
* Defaults to black, legacy behaviour. Colour (or checkerboard) is saved
  in persist data for texture viewer between sessions.
2014-07-01 00:37:23 +01:00
baldurk 185bbea851 Clamp picked pixel co-ords to texture size. Closes #68
* "Hover" co-ords still show larger values, in []s.
2014-07-01 00:02:57 +01:00
baldurk 662be4e657 Merge pull request #71 from Kamayuq/master
Added bit visualization to the Debugger
2014-06-28 15:22:51 +01:00
Arne Schober 5d73a581a3 Added bit visualization to the Debugger 2014-06-28 16:16:31 +02:00
baldurk 927847325e Try and track cases of duplicate/bad wrappers by returning error
* Print out the type via guid - if we can track which resources are
  creating duplicates we can pass the error further back to the Create*
  function so we can dump descriptor etc.
2014-06-28 12:53:24 +01:00
baldurk 33049558c5 Bail out if the wrapper isn't valid, otherwise erase() will crash 2014-06-28 12:52:43 +01:00
baldurk 711f4aadf6 Print error first for unsupported operand, and check name is valid
* Got a crash report here but from the minidump can't see what's wrong.
  It was debugging a compute shader which shouldn't have outputs.
2014-06-28 12:52:16 +01:00
baldurk f0576ae431 Rename GL context to ctx to match linux 2014-06-28 12:50:19 +01:00
Baldur Karlsson 29792558e1 call Serialise_ functions, not real functions 2014-06-27 14:39:41 +01:00
Baldur Karlsson fb7181e41e Don't waste time making redundant copy of textures array 2014-06-27 14:39:40 +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 e5664a0838 Add global lock on all GL hook entry points
* This could be improved and moved further down, not all functions would
  need a lock (only things modifying shared resources), but it suffices
  for now.
2014-06-27 13:06:59 +01:00
Baldur Karlsson 8d44497712 Simple tracking of active context per thread
* Should change this to TLS
2014-06-27 13:02:12 +01:00
Baldur Karlsson 740a6c80e9 Fetch initial buffer contents for dirty resources in GL
* Huge hack, but it works for now...
2014-06-27 12:36:44 +01:00
Baldur Karlsson de9fb483f0 Also pass-through glXChooseFBConfig (for SDL contexts > 3.0) 2014-06-27 11:59:01 +01:00
Baldur Karlsson c13a230e3e typo - use TextureRes for textures 2014-06-26 17:01:38 +01:00
Baldur Karlsson b30314e644 fixes for hooking programs that use SDL
* Pass-through a few functions in glXGetProcAddress
* Hook dlopen() and redirect any attempts to open libGL.so
2014-06-26 15:19:20 +01:00
Baldur Karlsson b21c0e62ba Update qt creator file list 2014-06-26 15:17:38 +01:00
Baldur Karlsson b9dd24e950 Also export glXGetProcAddressARB() 2014-06-26 11:42:30 +01:00
Baldur Karlsson f00815818a Include stddef.h for size_t 2014-06-26 11:42:08 +01:00
Baldur Karlsson efa520474a Minor optimisation to reduce recording of redundant chunks 2014-06-25 09:23:19 +01:00
Baldur Karlsson 4bb512a174 Support half-float in GetByteSize 2014-06-25 09:22:32 +01:00
Baldur Karlsson 052694d39f Track enabled caps in the renderstate only when not capframing 2014-06-25 09:22:15 +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 aae6208b22 Account for UNPACK_ROW_LENGTH and UNPACK_IMAGE_HEIGHT 2014-06-24 16:00:27 +01:00
Baldur Karlsson 038bcff106 GL_TEXTURE_SWIZZLE_RGBA is 4 parameters not 1 2014-06-24 16:00:26 +01:00
Baldur Karlsson a10770defb Handle setting datatype on records/texture data correctly 2014-06-24 16:00:26 +01:00
Baldur Karlsson fdbced5292 glUseProgramStages should always go into pipeline record 2014-06-24 16:00:24 +01:00
Baldur Karlsson e757f0aad6 Fix using wrong program name (parameter not valid when reading) 2014-06-24 16:00:23 +01:00
Baldur Karlsson 9441c0aa1d glDetachShader should remove, not add the shader if unlinked 2014-06-24 16:00:23 +01:00
Baldur Karlsson e778ad7b74 Create map for pipeline objects to store child programs 2014-06-24 16:00:22 +01:00
Baldur Karlsson 12019c3844 For now handle no program being bound, e.g. if pipeline is bound 2014-06-24 16:00:21 +01:00
Baldur Karlsson 4bcb81e294 Bump up number of texture records 2014-06-24 16:00:21 +01:00
Baldur Karlsson c25c0dae9d Call real, not wrapped function 2014-06-24 16:00:20 +01:00
Baldur Karlsson 0f715059c8 Return a few extension strings that programs might query for 2014-06-24 16:00:19 +01:00
Baldur Karlsson 20e045cc12 Ignore buffers that don't have a type
* This won't be a problem eventually as these buffers aren't referenced
  so will be dropped from the log in most cases.
2014-06-24 16:00:19 +01:00
Baldur Karlsson 2357921180 Silently drop waits on non-existant syncs (from previous frames) 2014-06-24 16:00:18 +01:00
Baldur Karlsson f53f79c2ad Handle calls to bind 0 object (unbinding) 2014-06-24 16:00:17 +01:00
Baldur Karlsson d0b63f6ae3 When in CAPFRAME save uniform sets to context record
* It was the wrong way around. When not capturing frame we save uniform
  sets to the program's record, but really we shouldn't do this and we
  should grab these as 'initial state' of the program resources
2014-06-24 15:46:22 +01:00
Baldur Karlsson 6e1d976a48 Return pixel format WGL extensions and add do-nothing hooks 2014-06-24 15:45:04 +01:00