FragDepth(3)
Description
FragDepthTo have a shader supply a fragment-depth value, the shadermust declare the
DepthReplacingexecution mode.Such a shader’s fragment-depth value will come from the variable decoratedwith theFragDepthbuilt-in decoration.This value will be used for any subsequent depth testing performed by theimplementation or writes to the depth attachment.Seefragment shader depth replacementfor details.
VUID-FragDepth-FragDepth-04213
TheFragDepthdecorationmust be used only within theFragmentExecutionModelVUID-FragDepth-FragDepth-04214
The variable decorated withFragDepthmust be declared using theOutputStorageClassVUID-FragDepth-FragDepth-04215
The variable decorated withFragDepthmust be declared as a scalar32-bit floating-point valueVUID-FragDepth-FragDepth-04216
If the shader dynamically writes to the variable decorated withFragDepth, theDepthReplacingExecutionModemust bedeclared
Document Notes
For more information, see theVulkan Specification (NOTE: cannot determine Specification page containing this refpage).
This page is extracted from the Vulkan Specification.Fixes and changes should be made to the Specification, not directly.