Getting the Metal from vulkan types to call insertDebugCaptureBoundary


Viewing 6 posts - 1 through 6 (of 6 total)
  • Author
    Posts
  • #1251
    ch
    Participant

      Hey I’m trying to debug something and I can’t capture Metal frames with the debugger because I’m not directly presenting this render pass to the UI, is there a way to manually invoke insertDebugCaptureBoundary or get the MTLCommandQueue from a vulkan type?

      #1252
      Bill Hollings
      Keymaster

        @ch

        MoltenVK automatically handles that for you as part of the Vulkan vkQueuePresentKHR() call…so that you can capture GPU frames.

        As with any app, you need to ensure that within your Xcode Scheme, your app is being run in Debug mode and GPU Frame Capture is enabled.

        Please try it out with the Demo apps that come with MoltenVK, and confirm that it is working. If you are still having trouble, please expand on how you are using it, and what might be different between your app and the MoltenVK Demo apps.

        …Bill

        #1253
        ch
        Participant

          @bill I know the Molten does it as part of queue present however I am trying to write the equivalent of a glReadPixel thing, I’m rendering into a VkImage and transferring that to a staging VkImage, mapping it, and using the pixel data for something else. There is no need to present the image to the swapchain. This currently isn’t working under Molten and I’d like to run a frame capture on the queue to see what’s missing. I previously had it backed with a swapchain image and it rendered fine.

          #1254
          Bill Hollings
          Keymaster

            @ch

            Is the problem that your effort is not happening in a queue that ends up being presented at all?

            …Bill

            #1255
            ch
            Participant

              correct, that queue is not presented to the swapchain, so the implicit insertDebugCaptureBoundary do not get submitted

              #1256
              Bill Hollings
              Keymaster

                @ch

                Right. Unfortunately…there is nothing in the current version of MoltenVK that can help with that. We can look to add the capability to make a distinct call to insert a debug capture boundary in a future release.

                In the meantime…I assume you are using multiple queues for performance through concurrency? Is it possible to temporarily use your presentation queue for your texture manipulation efforts, until you determine what the problem is through a GPU frame trace?

                …Bill

              Viewing 6 posts - 1 through 6 (of 6 total)
              • The forum ‘MoltenVK Support’ is closed to new topics and replies.