support SPV_NV_viewport_array2 and SPV_NV_stereo_view_rendering
This commit is contained in:
parent
22f25d80c6
commit
771d89fc36
21 changed files with 654 additions and 36 deletions
|
|
@ -203,6 +203,11 @@ enum TBuiltInVariable {
|
|||
EbvBaryCoordPullModel,
|
||||
#endif
|
||||
|
||||
#ifdef NV_EXTENSIONS
|
||||
EbvViewportMaskNV,
|
||||
EbvSecondaryPositionNV,
|
||||
EbvSecondaryViewportMaskNV,
|
||||
#endif
|
||||
// HLSL built-ins that live only temporarily, until they get remapped
|
||||
// to one of the above.
|
||||
EbvFragDepthGreater,
|
||||
|
|
@ -316,6 +321,11 @@ __inline const char* GetBuiltInVariableString(TBuiltInVariable v)
|
|||
case EbvBaryCoordSmoothSample: return "BaryCoordSmoothSample";
|
||||
case EbvBaryCoordPullModel: return "BaryCoordPullModel";
|
||||
#endif
|
||||
#ifdef NV_EXTENSIONS
|
||||
case EbvViewportMaskNV: return "ViewportMaskNV";
|
||||
case EbvSecondaryPositionNV: return "SecondaryPositionNV";
|
||||
case EbvSecondaryViewportMaskNV: return "SecondaryViewportMaskNV";
|
||||
#endif
|
||||
default: return "unknown built-in variable";
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -601,6 +601,9 @@ public:
|
|||
layoutPushConstant = false;
|
||||
#ifdef NV_EXTENSIONS
|
||||
layoutPassthrough = false;
|
||||
layoutViewportRelative = false;
|
||||
// -2048 as the default vaule indicating layoutSecondaryViewportRelative is not set
|
||||
layoutSecondaryViewportRelativeOffset = -2048;
|
||||
#endif
|
||||
}
|
||||
bool hasLayout() const
|
||||
|
|
@ -657,6 +660,8 @@ public:
|
|||
|
||||
#ifdef NV_EXTENSIONS
|
||||
bool layoutPassthrough;
|
||||
bool layoutViewportRelative;
|
||||
int layoutSecondaryViewportRelativeOffset;
|
||||
#endif
|
||||
|
||||
bool hasUniformLayout() const
|
||||
|
|
@ -1336,6 +1341,12 @@ public:
|
|||
case EbvPointSize:
|
||||
case EbvClipDistance:
|
||||
case EbvCullDistance:
|
||||
#ifdef NV_EXTENSIONS
|
||||
case EbvLayer:
|
||||
case EbvViewportMaskNV:
|
||||
case EbvSecondaryPositionNV:
|
||||
case EbvSecondaryViewportMaskNV:
|
||||
#endif
|
||||
return true;
|
||||
default:
|
||||
return false;
|
||||
|
|
@ -1604,6 +1615,10 @@ public:
|
|||
#ifdef NV_EXTENSIONS
|
||||
if (qualifier.layoutPassthrough)
|
||||
p += snprintf(p, end - p, "passthrough ");
|
||||
if (qualifier.layoutViewportRelative)
|
||||
p += snprintf(p, end - p, "layoutViewportRelative ");
|
||||
if (qualifier.layoutSecondaryViewportRelativeOffset != -2048)
|
||||
p += snprintf(p, end - p, "layoutSecondaryViewportRelativeOffset=%d ", qualifier.layoutSecondaryViewportRelativeOffset);
|
||||
#endif
|
||||
|
||||
p += snprintf(p, end - p, ") ");
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue