MCPcopy Create free account
hub / github.com/MeshInspector/MeshLib / getFragmentShaderHeaderBlock

Function getFragmentShaderHeaderBlock

source/MRViewer/MRShaderBlocks.cpp:86–114  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

84}
85
86std::string getFragmentShaderHeaderBlock( bool gl4, bool alphaSort )
87{
88 if ( !gl4 )
89 return MR_GLSL_VERSION_LINE R"(
90 precision highp float;
91 precision highp int;)";
92 else if ( !alphaSort )
93 return R"(#version 430 core)";
94 else
95 return R"(#version 430 core
96
97 layout (early_fragment_tests) in;
98
99 struct Node
100 {
101 vec4 color;
102 float depth;
103 uint next;
104 };
105
106 layout (binding = 0, r32ui) uniform uimage2D heads;
107 layout (binding = 0, offset = 0) uniform atomic_uint numNodes;
108
109 layout (binding = 0, std430 ) buffer Lists
110 {
111 Node nodes [];
112 };
113)";
114}
115
116std::string getFragmentShaderEndBlock( ShaderTransparencyMode transparencyMode )
117{

Callers 3

getLinesFragmentShaderFunction · 0.85
getMeshFragmentShaderFunction · 0.85
getPointsFragmentShaderFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected