Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
G
glslang
Project
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Chen Yisong
glslang
Commits
00b3e384
Commit
00b3e384
authored
Aug 23, 2017
by
John Kessenich
Committed by
GitHub
Aug 23, 2017
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #1025 from amdrexu/feature
SPV: Implement extension SPV_EXT_shader_stencil_export
parents
3d1b7096
e8fdd79f
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
15 additions
and
5 deletions
+15
-5
GLSL.ext.KHR.h
SPIRV/GLSL.ext.KHR.h
+1
-0
GlslangToSpv.cpp
SPIRV/GlslangToSpv.cpp
+3
-2
doc.cpp
SPIRV/doc.cpp
+3
-0
spirv.hpp
SPIRV/spirv.hpp
+5
-2
spv.shaderStencilExport.frag.out
Test/baseResults/spv.shaderStencilExport.frag.out
+3
-1
No files found.
SPIRV/GLSL.ext.KHR.h
View file @
00b3e384
...
...
@@ -42,5 +42,6 @@ static const char* const E_SPV_KHR_shader_draw_parameters = "SPV_KHR_shade
static
const
char
*
const
E_SPV_KHR_16bit_storage
=
"SPV_KHR_16bit_storage"
;
static
const
char
*
const
E_SPV_KHR_storage_buffer_storage_class
=
"SPV_KHR_storage_buffer_storage_class"
;
static
const
char
*
const
E_SPV_KHR_post_depth_coverage
=
"SPV_KHR_post_depth_coverage"
;
static
const
char
*
const
E_SPV_EXT_shader_stencil_export
=
"SPV_EXT_shader_stencil_export"
;
#endif // #ifndef GLSLextKHR_H
SPIRV/GlslangToSpv.cpp
View file @
00b3e384
...
...
@@ -522,8 +522,9 @@ spv::BuiltIn TGlslangToSpvTraverser::TranslateBuiltInDecoration(glslang::TBuiltI
return
spv
::
BuiltInPrimitiveId
;
case
glslang
:
:
EbvFragStencilRef
:
logger
->
missingFunctionality
(
"shader stencil export"
);
return
spv
::
BuiltInMax
;
builder
.
addExtension
(
spv
::
E_SPV_EXT_shader_stencil_export
);
builder
.
addCapability
(
spv
::
CapabilityStencilExportEXT
);
return
spv
::
BuiltInFragStencilRefEXT
;
case
glslang
:
:
EbvInvocationId
:
return
spv
::
BuiltInInvocationId
;
case
glslang
:
:
EbvTessLevelInner
:
return
spv
::
BuiltInTessLevelInner
;
...
...
SPIRV/doc.cpp
View file @
00b3e384
...
...
@@ -331,6 +331,7 @@ const char* BuiltInString(int builtIn)
case
4424
:
return
"BaseVertex"
;
case
4425
:
return
"BaseInstance"
;
case
4426
:
return
"DrawIndex"
;
case
5014
:
return
"FragStencilRefEXT"
;
#ifdef AMD_EXTENSIONS
case
4992
:
return
"BaryCoordNoPerspAMD"
;
...
...
@@ -842,6 +843,8 @@ const char* CapabilityString(int info)
case
4437
:
return
"DeviceGroup"
;
case
4439
:
return
"MultiView"
;
case
5013
:
return
"StencilExportEXT"
;
#ifdef AMD_EXTENSIONS
case
5009
:
return
"ImageGatherBiasLodAMD"
;
#endif
...
...
SPIRV/spirv.hpp
View file @
00b3e384
...
...
@@ -47,11 +47,11 @@ namespace spv {
typedef
unsigned
int
Id
;
#define SPV_VERSION 0x10000
#define SPV_REVISION 1
1
#define SPV_REVISION 1
2
static
const
unsigned
int
MagicNumber
=
0x07230203
;
static
const
unsigned
int
Version
=
0x00010000
;
static
const
unsigned
int
Revision
=
1
1
;
static
const
unsigned
int
Revision
=
1
2
;
static
const
unsigned
int
OpCodeMask
=
0xffff
;
static
const
unsigned
int
WordCountShift
=
16
;
...
...
@@ -444,6 +444,7 @@ enum BuiltIn {
BuiltInBaryCoordSmoothCentroidAMD
=
4996
,
BuiltInBaryCoordSmoothSampleAMD
=
4997
,
BuiltInBaryCoordPullModelAMD
=
4998
,
BuiltInFragStencilRefEXT
=
5014
,
BuiltInViewportMaskNV
=
5253
,
BuiltInSecondaryPositionNV
=
5257
,
BuiltInSecondaryViewportMaskNV
=
5258
,
...
...
@@ -640,8 +641,10 @@ enum Capability {
CapabilityAtomicStorageOps
=
4445
,
CapabilitySampleMaskPostDepthCoverage
=
4447
,
CapabilityImageGatherBiasLodAMD
=
5009
,
CapabilityStencilExportEXT
=
5013
,
CapabilitySampleMaskOverrideCoverageNV
=
5249
,
CapabilityGeometryShaderPassthroughNV
=
5251
,
CapabilityShaderViewportIndexLayerEXT
=
5254
,
CapabilityShaderViewportIndexLayerNV
=
5254
,
CapabilityShaderViewportMaskNV
=
5255
,
CapabilityShaderStereoViewNV
=
5259
,
...
...
Test/baseResults/spv.shaderStencilExport.frag.out
View file @
00b3e384
spv.shaderStencilExport.frag
Missing functionality: shader stencil export
// Module Version 10000
// Generated by (magic number): 80001
// Id's are bound by 10
Capability Shader
Capability StencilExportEXT
Extension "SPV_EXT_shader_stencil_export"
1: ExtInstImport "GLSL.std.450"
MemoryModel Logical GLSL450
EntryPoint Fragment 4 "main" 8
...
...
@@ -13,6 +14,7 @@ Missing functionality: shader stencil export
SourceExtension "GL_ARB_shader_stencil_export"
Name 4 "main"
Name 8 "gl_FragStencilRefARB"
Decorate 8(gl_FragStencilRefARB) BuiltIn FragStencilRefEXT
2: TypeVoid
3: TypeFunction 2
6: TypeInt 32 1
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment