Post

Replies

Boosts

Views

Activity

Reply to VisionOS Metal Sample issue with clearColor
Hey everyone, I found a better workaround for this issue. After debugging it further with a GPU Frame capture, it came to my attention that the compositor will create a segmentation mask for safety reason based on the depth of the rendered content. The mask will cut off roughly at the edges where the depth goes from 0.0 to a non-zero value, creating the jaggies seen on the screenshot above. The solution to this problem was to simply set the depth clear value to a very small non-zero value: depthStateDescriptor.depthCompareFunction = .greater // Back to normal renderPassDescriptor.depthAttachment.clearDepth = Double.ulpOfOne // slightly-higher-than-zero depth value by default Hope this helps other people. The
Topic: Graphics & Games SubTopic: General Tags:
May ’24
Reply to [Metal Passthrough] upperLimbVisibility not respected in sample code
I believe this is fixed in the VisionOS Beta 2.
Topic: Spatial Computing SubTopic: General Tags:
Replies
Boosts
Views
Activity
Jul ’24
Reply to VisionOS Metal Sample issue with clearColor
Hey everyone, I found a better workaround for this issue. After debugging it further with a GPU Frame capture, it came to my attention that the compositor will create a segmentation mask for safety reason based on the depth of the rendered content. The mask will cut off roughly at the edges where the depth goes from 0.0 to a non-zero value, creating the jaggies seen on the screenshot above. The solution to this problem was to simply set the depth clear value to a very small non-zero value: depthStateDescriptor.depthCompareFunction = .greater // Back to normal renderPassDescriptor.depthAttachment.clearDepth = Double.ulpOfOne // slightly-higher-than-zero depth value by default Hope this helps other people. The
Topic: Graphics & Games SubTopic: General Tags:
Replies
Boosts
Views
Activity
May ’24
Reply to VisionOS Metal Sample issue with clearColor
It seems that a (not ideal) workaround is to do the following: renderPassDescriptor.depthAttachment.clearDepth = 1.0 // instead of 0.0 and depthStateDescriptor.depthCompareFunction = .always // instead of MTLCompareFunction.greater
Topic: Graphics & Games SubTopic: General Tags:
Replies
Boosts
Views
Activity
Apr ’24