Closed manuel-woelker closed 3 years ago
Implementing this for the other backends (DX11, DX12, GL) should be fairly similar.
Any preferences on having one PR per backend, or all in one?
All in one is fine, but let's first figure out the proper way to do this on one backend.
Next iteration, using renderdoc-sys and some pointer wrangling. RenderDoc still seems to be happy :-)
Any thoughts on how to handle this in the example code? There is currently a crude solution that allows starting and stopping a frame capture using "S" and "E"respectively. Any recommended approach?
If the plan is to encapsulate and reuse this functionality in other backends, where would the best place to put it be? gfx-hal?
Thanks for the review and advice, much appreciated!
Any thoughts on how to handle this in the example code? There is currently a crude solution that allows starting and stopping a frame capture using "S" and "E"respectively. Any recommended approach?
I recommend just unconditionally starting the capture in the compute example at start, and finishing it at the end. This would mean you don't need to write any input handling code.
If the plan is to encapsulate and reuse this functionality in other backends, where would the best place to put it be? gfx-hal?
It's already in gfx-hal. The start/stop capture API is on the hal::Device
Pushed another version, with removed feature flag and some cleanup :-)
Ready for another review, I cleaned up the match expressions and marked load_renderdoc_entrypoint()
unsafe
I reordered the cfg!(debug_assertions)
and cleaned up the brace nesting.
Great! bors r+
👍 Thanks for the through review @kvark, and shoutout to @adamnemecek for pointing me this way 😃
Thank you for tirelessly addressing my concerns! I'm excited to finally remove all renderdoc-specific code from downstream crates :)
@manuel-woelker This is all you.
TODOs:
find a way to use the correct device/window pointers instead of NULLNull pointers should be fine for the majority of use casesImplement DX11, DX12, GL backends?TBD in a separate PRThis is a follow up on #3708
Fixes #issue PR checklist:
make
succeeds (on *nix)make reftests
succeeds