Commit Graph

6770 Commits

Author SHA1 Message Date
baldurk fdfdda71ac Add helper #defines to allow declaring embedded resources by name
* We want to be able to declare a 'name' of a resource and then fetch it
  later. To do this we create a tiny little reference (either an int on
  windows, or a pointer+length elsewhere), then actually fetch the data
  later.
2018-01-12 10:55:18 +00:00
baldurk f87d058cfb Split out texture rendering and preparation into separate files 2018-01-12 10:55:17 +00:00
baldurk 770e6756f8 Split out conversion between MSAA textures and 2D arrays. 2018-01-12 10:55:16 +00:00
baldurk 013457ab5f Split out mesh rendering to separate files 2018-01-12 10:55:16 +00:00
baldurk 635a58280e Split output window handling out of debug files 2018-01-12 10:55:15 +00:00
baldurk 69f8571f43 Remove d3d11_analyse.cpp and merge code in elsewhere
* This is temporary until we split up the debug file further, but it
  makes the D3D11 codebase more consistent with the other APIs.
2018-01-12 10:55:14 +00:00
baldurk e287664730 Split apart pixel history and shader debugging from d3d11_analyse.cpp 2018-01-12 10:55:13 +00:00
baldurk db59ffddc6 Split overlay rendering out into separate files in each driver 2018-01-12 10:55:13 +00:00
baldurk 60ed3e2867 Split PostVS implementation out into separate files in each driver 2018-01-12 10:55:12 +00:00
baldurk e7991c07eb Add ability to create a mapping from RGP linear/interopId <=> eventId 2018-01-11 16:44:57 +00:00
baldurk 4b7e7f5df1 Add section type for embedded AMD RGP profiles 2018-01-11 15:33:43 +00:00
baldurk 21a16e051b Add support for pre-instance layer functions
* Added to the vulkan loader after 1.0.65, this lets us intercept the
  enumeration of instance extensions (before our layer is actually
  initialised) so that we can filter out unsupported extensions.
2018-01-11 13:48:35 +00:00
baldurk 32d57f4019 Enable sorting in debug messages 2018-01-11 13:48:34 +00:00
baldurk 3170d8fa53 Add option to fetch debug messages at runtime and display them in the UI
* By default this is off as it will continually add more and more
  messages each time the frame is replayed. It could be useful to turn
  on to
* We also enable VK_EXT_debug_report any time it's available, not just
  when we're enabling the validation layers.
2018-01-11 13:48:34 +00:00
baldurk da5cefbac2 Add workaround for when vulkan ICD is libGL.so and we repoint it to us
* Some distribution packages (Ubuntu at least I think) point the nvidia
  vulkan ICD registration at libGL.so. Since for libGL hooking we have
  to redirect dlopen("libGL.so") to ourselves, this means the vulkan
  loader loads librenderdoc instead of libGL. If we don't export the VK
  ICD entry points, it will fail to load that ICD.
* This solution isn't perfect - we export all three main ICD entry
  points. If the real ICD doesn't export one, we will fail and cause
  problems, since the loader won't fall back to older paths unless the
  symbol is completely missing. For now though this is fine since the
  nvidia ICD exports all three.
* The only way to solve that properly would be to intercept all calls to
  dlsym and redirect these functions by name to go to the real handle
  instead of ourselves - vastly overcomplicated for this edge case.
2018-01-11 13:48:34 +00:00
baldurk b5d9034698 When opening raw index buffer view, multiply offset by index width 2018-01-11 13:48:33 +00:00
baldurk 316b57e06f Initialise buffer view information with wrapped create info 2018-01-11 13:48:33 +00:00
baldurk d7f5d7f1c6 Don't try and enable validation layers on android even if enabled
* We'd have to bundle the layers with our apk and we don't do that, it
  just causes replay to fail.
2018-01-11 13:48:33 +00:00
baldurk dc98914eef Don't add android hosts synchronously in menu popup (it started slowing)
* This was fast before but I started noticing the lag. Instead, we can
  do it asynchronously when polling for remote host status, every few
  seconds. This should still be good enough as people are probably going
  to be used to devices taking a moment to appear.
2018-01-11 13:48:33 +00:00
baldurk 01ee0e32ba Update preview settings after fetching PostVS data 2018-01-11 13:48:32 +00:00
baldurk 079c255bd8 Fix some missing whitespace around rst references in docs 2018-01-11 13:48:32 +00:00
baldurk ef788c7e4f Account correctly for UAV mip slice when fetching 2D texture data 2018-01-11 13:48:30 +00:00
baldurk 565f8e2f97 Fix circular loop when adding debug messages in D3D12 2018-01-11 13:47:43 +00:00
baldurk 8fdf2bed62 Discard debug messages after starting the frame capture
* This prevents us from serialising debug messages caused by the
  initial state preparation accidentally.
2018-01-11 13:47:43 +00:00
baldurk 8220b98601 Remove use of renderdoc.props with git commit hash where it's not needed
* This causes a full rebuild in VS because the command line has changed
  every time you commit or checkout in git (because the git commit
  /D parameter has changed).
* Since we only need it in UI-facing projects we remove it from
  every project except qrenderdoc, core renderdoc, and renderdoccmd.
  They will still rebuild when the commit changes but technically VS is
  right to do so.
2018-01-04 21:46:41 +00:00
baldurk a6f856d2d9 Fix mistaken && insteasd of & checking control key modifier 2018-01-04 21:46:41 +00:00
baldurk 0991642393 Add error message in case reading from file fails while embedding 2018-01-04 21:46:41 +00:00
baldurk 3c4d9147fb Fix potential NULL dereference if no draw is found rendering overlay 2018-01-04 21:46:41 +00:00
baldurk dec06a19fb Don't pass NULL f to fclose, passing --no-clobber if file doesn't exist 2018-01-04 21:46:41 +00:00
David McFarland 9013c1babf image_viewer: fix corruption when viewing rgba32_float images 2018-01-04 12:32:27 +01:00
michaelrgb 89eb933be5 If user resumes APK after server shutdown, restart cmdthread.
Also make sure ANativeActivity_finish/DetachCurrentThread are called.
2018-01-03 11:11:25 +01:00
David McFarland b9be6a70e3 gl: Fix initial data preparation on wrong context. 2018-01-03 11:11:17 +01:00
David McFarland c32f5902e9 gl: Avoid passing initial data pointers through the queue.
This reduces the possibility of a logic error leading to memory
corruption by using a dangling pointer.
2018-01-03 11:11:17 +01:00
David McFarland e63f696ddb gl: Delete context owned resources from resource manager.
This fixes tracking problems when a context id is reused.
2018-01-03 11:11:17 +01:00
baldurk 089b9c1ece Don't use ToQStr for converting rdcstr to QString, just cast 2018-01-02 17:19:54 +00:00
baldurk 1b50521704 Add check against empty files somehow adding to recent file lists 2018-01-02 16:06:13 +00:00
baldurk e3ead220f6 Refresh list of android hosts whenever context switcher is opened
* It's very fast, and means we update whenever a device is plugged in or
  unplugged.
2018-01-02 15:50:22 +00:00
baldurk c30511e523 For the remote server preview, display at 90% scale
* This makes it more clear that the preview is coming from renderdoc's
  replay, not the original program.
2018-01-02 15:50:21 +00:00
baldurk 6f6ee4ce01 Add workaround for Qualcomm chips where uniform buffer offsets 'leak'
* There's weird behaviour seen where after binding a descriptor set with
  an offset, subsequent work in other command buffers doesn't behave
  correctly. Re-binding the descriptor set with a 0 offset seems to fix
  it, so I assume the offset is leaking and applying to subsequent
  binds that don't have any dynamic offsets.
2018-01-02 15:50:21 +00:00
baldurk 4496e4ff32 Add alternative for rendering checkerboard with pure clears
* For some reason the checkerboard pipeline fails to create on Mali-G71
  so we fall back to just clearing with many many rects.
2018-01-02 15:18:14 +00:00
baldurk 65724841b6 Shader discard doesn't seem to work well on mobile, remove it
* Instead we write transparent black when out of bounds. This only works
  when we're blending, but the cases that we don't blend are when we do
  a blit to a precisely sized output target with no offset, so it
  shouldn't cause a problem.
2018-01-02 15:13:07 +00:00
baldurk 0ea854a9da Don't return android windowing data if we have no window 2018-01-02 14:34:34 +00:00
baldurk 7347e19d8c Add check & print of shader compile and program link status 2018-01-02 12:34:46 +00:00
baldurk 7abc319a2c Add default precision for logo fragment shader 2018-01-02 12:34:26 +00:00
baldurk 1fe04d13ec Add new posix network files to VS solution 2018-01-01 18:20:38 +00:00
baldurk e305029ddd Update copyright years to 2018 2018-01-01 17:55:29 +00:00
baldurk 96e39cb781 Add a preview window ability to remote servers. Always on for android
* On android in particular this shows some sense of what's happening on
  the device and gives user feedback that it's not completely dead.
2018-01-01 17:31:23 +00:00
baldurk 7a2305ae31 Change by-ref passed float or bool parameters to callbacks in public API
* Mostly used for passing a progress float back during a long blocking
  call like opening a capture or doing a copy.
* This is much more feasible for python to bind to.
* In several cases we just use a tiny lambda that updates a float anyway
  since we can't push the progress directly into a progress dialog, but
  need to let it query from a temporary in-between float.
2018-01-01 17:31:23 +00:00
baldurk 2e74989b69 Allow None when converting std::function types
* It just creates an empty callback
2018-01-01 17:31:22 +00:00
baldurk 4c0347f856 Fix compile errors with python bindings on callbacks with return values 2018-01-01 17:31:21 +00:00