HDK
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
RE_UniformNames.h
Go to the documentation of this file.
1 /*
2  * PROPRIETARY INFORMATION. This software is proprietary to
3  * Side Effects Software Inc., and is not to be reproduced,
4  * transmitted, or disclosed in any way without written permission.
5  *
6  * NAME: RE_Uniform.h (Library, C++)
7  *
8  * COMMENTS:
9  */
10 
11 #ifndef __RE_UNIFORMNAMES_H__
12 #define __RE_UNIFORMNAMES_H__
13 
14 #include "RE_API.h"
15 
16 #include <UT/UT_StringHolder.h>
17 #include <UT/UT_StringMap.h>
18 
19 #define RE_DECL_UNIFORM_NAME(X) static const UT_StringHolder X;
20 
21 #define RE_UNIFORM_NAME_LIST(X) \
22 X(GeometryHasColor) \
23 X(Normalize) \
24 X(OsdGregoryQuadOffsetBase) \
25 X(OsdPrimitiveIdBase) \
26 X(OsdPrimitiveMultiplier) \
27 X(TessLevel) \
28 X(ZoneMatrix) \
29 X(absorptionRatio) \
30 X(albedoPerLength) \
31 X(all_vertices_valid) \
32 X(alpha) \
33 X(alphaLayer) \
34 X(area_width) \
35 X(astep) \
36 X(avoid_edges) \
37 X(axisAgg) \
38 X(axisRulerOnly) \
39 X(backBottomColor) \
40 X(backColor) \
41 X(backFacing) \
42 X(bboxmat) \
43 X(beauty) \
44 X(blackPass) \
45 X(bloom) \
46 X(boldInc) \
47 X(bottomColor) \
48 X(boxDims) \
49 X(checkDepth) \
50 X(check_size) \
51 X(clampedRange) \
52 X(color) \
53 X(colscale) \
54 X(colshift) \
55 X(compselect) \
56 X(const_alpha) \
57 X(coordScale) \
58 X(colorTex) \
59 X(countTex) \
60 X(crop_offset) \
61 X(cscale) \
62 X(cshift) \
63 X(cutoff) \
64 X(decorationScale) \
65 X(densityScale) \
66 X(densityTex) \
67 X(depthTexture) \
68 X(depth_offset) \
69 X(destVoxels) \
70 X(destVoxels08) \
71 X(destVoxels16) \
72 X(destVoxels32) \
73 X(destVoxelIdx) \
74 X(diff_depth_resolution) \
75 X(discTex) \
76 X(discard_filter) \
77 X(doMatteCheck) \
78 X(do_matte) \
79 X(drawComponents) \
80 X(dst) \
81 X(emissionScale) \
82 X(emitgnomons) \
83 X(emittails) \
84 X(end) \
85 X(envSamples) \
86 X(env_color) \
87 X(env_orient) \
88 X(eyePos) \
89 X(fade_color) \
90 X(firstPassVolume) \
91 X(fixedVoxelSize) \
92 X(floorAlpha) \
93 X(fontColors) \
94 X(fontMap) \
95 X(fontParms) \
96 X(gamma) \
97 X(glowColor) \
98 X(glowMatteTex) \
99 X(gridAlpha) \
100 X(gridArea) \
101 X(gridColor) \
102 X(gridLevelBlend) \
103 X(gridLineWidth) \
104 X(gridNextLevelWideStep) \
105 X(gridNormal) \
106 X(gridOffset) \
107 X(gridStep) \
108 X(gridWideStep) \
109 X(gridmax) \
110 X(gridmin) \
111 X(hasPickMask) \
112 X(hasRamp) \
113 X(has_alpha_pass) \
114 X(height) \
115 X(hide_selected) \
116 X(hq_transparency) \
117 X(iViewHeight) \
118 X(iViewSize) \
119 X(iboldinc) \
120 X(iboldnextinc) \
121 X(iconTexture) \
122 X(igamma) \
123 X(imageIndex) \
124 X(imageTex) \
125 X(imageTexture) \
126 X(image_texture) \
127 X(increaseSteps) \
128 X(invertMask) \
129 X(invert_opacitymap) \
130 X(invert_roughmap) \
131 X(invRange) \
132 X(invVoxelSizeSq) \
133 X(isVerticalPass) \
134 X(is_vertical_pass) \
135 X(iscale) \
136 X(ishift) \
137 X(kernel) \
138 X(kernel_parm_0) \
139 X(kernel_parm_1) \
140 X(kernel_size) \
141 X(ksize) \
142 X(labelHeight) \
143 X(layered) \
144 X(layers) \
145 X(length) \
146 X(levelBlend) \
147 X(levelMultiplier) \
148 X(levels) \
149 X(lightAttenuation) \
150 X(lightColor) \
151 X(lightConeFalloff) \
152 X(lightDir) \
153 X(lightDirection) \
154 X(lightLocation) \
155 X(lightMask) \
156 X(lightPos) \
157 X(lightType) \
158 X(line_scale) \
159 X(lmask) \
160 X(lod_parms) \
161 X(lscale) \
162 X(lshift) \
163 X(lutidx) \
164 X(lutsize) \
165 X(maskTex) \
166 X(maxFixedDecimalDigits) \
167 X(minVal) \
168 X(msSampling) \
169 X(msTex) \
170 X(nextLabelHeight) \
171 X(nontrTransform) \
172 X(nontrTransformDif) \
173 X(nontrTransformEmit) \
174 X(nontrTransformEmitColor) \
175 X(normalizing_scale) \
176 X(numSamples) \
177 X(num_bones) \
178 X(num_rings) \
179 X(object_selected) \
180 X(objselection) \
181 X(off) \
182 X(offset) \
183 X(omegaSOR) \
184 X(orient_discs) \
185 X(output_res) \
186 X(output_size) \
187 X(overlapFillColor) \
188 X(overlapTex) \
189 X(patternTexture) \
190 X(pickHighTex) \
191 X(pickHighTexture) \
192 X(pickLowTex) \
193 X(pickLowTexture) \
194 X(pickMask) \
195 X(pick_back_face) \
196 X(pick_front_face) \
197 X(pick_outside) \
198 X(pointSize) \
199 X(pos) \
200 X(postBlurScale) \
201 X(prelut) \
202 X(preshift) \
203 X(qualityMult) \
204 X(radius) \
205 X(randTex) \
206 X(resAdjustments) \
207 X(resM1) \
208 X(roffset) \
209 X(scalarDiffuse) \
210 X(scalarEmitColor) \
211 X(scale) \
212 X(selectcomp) \
213 X(selectvec) \
214 X(show_interior) \
215 X(skin_alpha) \
216 X(skin_post_tint) \
217 X(skin_pre_tint) \
218 X(sliceNum) \
219 X(src) \
220 X(srcVoxels08) \
221 X(srcVoxels16) \
222 X(srcVoxels32) \
223 X(start) \
224 X(stencil) \
225 X(stencil_parms) \
226 X(stereoLine) \
227 X(strideY) \
228 X(strideZ) \
229 X(target8) \
230 X(texsize) \
231 X(textureidx) \
232 X(thinAlpha) \
233 X(topColor) \
234 X(total_layers) \
235 X(transparency) \
236 X(transparent) \
237 X(uValues) \
238 X(uniform_scale) \
239 X(useMask) \
240 X(use_cd) \
241 X(use_depth_diff_resolution) \
242 X(use_discard_filter) \
243 X(use_discs) \
244 X(use_fade_color) \
245 X(use_material) \
246 X(use_ms_buffers) \
247 X(use_ramp) \
248 X(use_square_kernel) \
249 X(use_varying_id) \
250 X(user_string_count) \
251 X(user_string_index) \
252 X(vValues) \
253 X(vector_size) \
254 X(vertex_offset) \
255 X(view_lod) \
256 X(viewarea) \
257 X(volumeSelected) \
258 X(volumeSize) \
259 X(volumeTaper) \
260 X(volume_color_scale) \
261 X(volume_dir) \
262 X(volume_map) \
263 X(volume_res) \
264 X(volume_selected) \
265 X(volume_taper) \
266 X(volume_xform) \
267 X(voxelLength) \
268 X(voxelSize) \
269 X(voxel_size) \
270 X(wideAlpha) \
271 X(width) \
272 X(wire_alpha) \
273 X(wiredraw) \
274 X(wireframe_check) \
275 X(xAxis) \
276 X(xValues) \
277 X(xraySampleMask) \
278 X(xrayStrength) \
279 X(yAxis) \
280 X(yValues) \
281 X(zStart) \
282 X(zValues) \
283 X(zrange) \
284 X(zstep) \
285 X(diffuseTex) \
286 X(emitColorTex) \
287 X(emitTex) \
288 X(transformRamp) \
289 X(transformRampDif) \
290 X(transformRampEmitColor) \
291 X(glH_ProjectMatrix) \
292 X(glH_ViewMatrix)
293 
294 
295 // This holds UT_StringHolder string constants for faster lookups into symbol maps.
296 // To add a new uniform name you simply need to add a new line in RE_UNIFORM_NAME_LIST
297 // The variable name and the string content use the same token.
299 {
300 public:
302 
303  static void initializeNames();
304 
305  // call to translate an allocated uniform name into one that's sharable
306  // and fast to compare with the above constants.
307  static const UT_StringHolder &sharedString(const UT_StringHolder &name);
308 private:
309  UT_StringMap<int> myNameMap;
310 };
311 
312 #endif
313 
GLuint const GLchar * name
Definition: glew.h:1814
#define RE_API
Definition: RE_API.h:10
#define RE_UNIFORM_NAME_LIST(X)
#define RE_DECL_UNIFORM_NAME(X)