Home
last modified time | relevance | path

Searched refs:uniform (Results 1 - 25 of 185) sorted by relevance

12345678

/third_party/mesa3d/src/compiler/glsl/
H A Dgl_nir_link_uniforms.c42 /** List of dereferences of the uniform array. */
87 * Update the sizes of linked shader uniform arrays to the maximum
98 * active uniform reported by the GL per uniform array.
148 /* If this is a built-in uniform (i.e., it's backed by some in update_array_sizes()
212 struct gl_uniform_storage *uniform = &prog->data->UniformStorage[i]; in nir_setup_uniform_remap_tables() local
214 if (uniform->hidden) in nir_setup_uniform_remap_tables()
217 if (uniform->is_shader_storage || in nir_setup_uniform_remap_tables()
218 glsl_get_base_type(uniform->type) == GLSL_TYPE_SUBROUTINE) in nir_setup_uniform_remap_tables()
224 /* How many new entries for this uniform in nir_setup_uniform_remap_tables()
244 struct gl_uniform_storage *uniform = &prog->data->UniformStorage[i]; nir_setup_uniform_remap_tables() local
315 struct gl_uniform_storage *uniform = &prog->data->UniformStorage[i]; nir_setup_uniform_remap_tables() local
352 struct gl_uniform_storage *uniform = &prog->data->UniformStorage[i]; nir_setup_uniform_remap_tables() local
395 struct gl_uniform_storage *uniform = &prog->data->UniformStorage[i]; nir_setup_uniform_remap_tables() local
601 mark_stage_as_active(struct gl_uniform_storage *uniform, unsigned stage) mark_stage_as_active() argument
663 add_parameter(struct gl_uniform_storage *uniform, const struct gl_constants *consts, struct gl_shader_program *prog, const struct glsl_type *type, struct nir_link_uniforms_state *state) add_parameter() argument
728 get_next_index(struct nir_link_uniforms_state *state, const struct gl_uniform_storage *uniform, unsigned *next_index, bool *initialised) get_next_index() argument
763 update_uniforms_shader_info(struct gl_shader_program *prog, struct nir_link_uniforms_state *state, struct gl_uniform_storage *uniform, const struct glsl_type *type, unsigned stage) update_uniforms_shader_info() argument
969 struct gl_uniform_storage *uniform = &prog->data->UniformStorage[i]; find_and_update_named_uniform_storage() local
1032 struct gl_uniform_storage *uniform = NULL; find_and_update_previous_uniform_storage() local
1082 struct gl_uniform_storage *uniform = &prog->data->UniformStorage[i]; find_and_update_previous_uniform_storage() local
1209 struct gl_uniform_storage *uniform = NULL; nir_link_uniform() local
[all...]
/third_party/skia/third_party/externals/angle2/src/libANGLE/
H A DUniform.cpp68 LinkedUniform::LinkedUniform(const sh::ShaderVariable &uniform) in LinkedUniform() argument
69 : sh::ShaderVariable(uniform), in LinkedUniform()
78 LinkedUniform::LinkedUniform(const LinkedUniform &uniform) in LinkedUniform() argument
79 : sh::ShaderVariable(uniform), in LinkedUniform()
80 ActiveVariable(uniform), in LinkedUniform()
81 typeInfo(uniform.typeInfo), in LinkedUniform()
82 bufferIndex(uniform.bufferIndex), in LinkedUniform()
83 blockInfo(uniform.blockInfo), in LinkedUniform()
84 outerArraySizes(uniform.outerArraySizes) in LinkedUniform()
87 LinkedUniform &LinkedUniform::operator=(const LinkedUniform &uniform) in operator =() argument
[all...]
H A DProgramLinkedResources.cpp8 // uniform locations. Populates data structures related to uniforms so that they can be stored in
26 for (LinkedUniform &uniform : list) in FindUniform()
28 if (uniform.name == name) in FindUniform()
29 return &uniform; in FindUniform()
97 for (const sh::ShaderVariable &uniform : shaderToLink->getUniforms()) in ValidateGraphicsUniformsPerShader()
99 const auto &entry = linkedUniforms->find(uniform.name); in ValidateGraphicsUniformsPerShader()
105 LinkValidateUniforms(uniform, linkedUniform, &mismatchedStructFieldName); in ValidateGraphicsUniformsPerShader()
108 LogLinkMismatch(infoLog, uniform.name, "uniform", linkError, in ValidateGraphicsUniformsPerShader()
116 (*linkedUniforms)[uniform in ValidateGraphicsUniformsPerShader()
385 FlattenUniformVisitor(ShaderType shaderType, const sh::ShaderVariable &uniform, std::vector<LinkedUniform> *uniforms, std::vector<LinkedUniform> *samplerUniforms, std::vector<LinkedUniform> *imageUniforms, std::vector<LinkedUniform> *atomicCounterUniforms, std::vector<LinkedUniform> *inputAttachmentUniforms, std::vector<UnusedUniform> *unusedUniforms) FlattenUniformVisitor() argument
900 const LinkedUniform &uniform = mUniforms[uniformIndex]; indexUniforms() local
[all...]
/third_party/skia/third_party/externals/angle2/src/compiler/translator/tree_ops/
H A DEmulateMultiDrawShaderBuiltins.cpp7 // to a uniform int
10 // to a uniform int
13 // to a uniform int
139 ShaderVariable uniform; in EmulateGLDrawID() local
140 uniform.name = kEmulatedGLDrawIDName.data(); in EmulateGLDrawID()
141 uniform.mappedName = kEmulatedGLDrawIDName.data(); in EmulateGLDrawID()
142 uniform.type = GLVariableType(*type); in EmulateGLDrawID()
143 uniform.precision = GLVariablePrecision(*type); in EmulateGLDrawID()
144 uniform.staticUse = symbolTable->isStaticallyUsed(*builtInVariable); in EmulateGLDrawID()
145 uniform in EmulateGLDrawID()
[all...]
/third_party/skia/third_party/externals/angle2/src/libANGLE/renderer/d3d/
H A DDynamicImage2DHLSL.cpp47 Image2DHLSLGroup image2DHLSLGroup(const sh::ShaderVariable &uniform) in image2DHLSLGroup() argument
49 GLenum format = uniform.imageUnitFormat; in image2DHLSLGroup()
50 bool readonly = uniform.readonly; in image2DHLSLGroup()
51 switch (uniform.type) in image2DHLSLGroup()
718 for (const sh::ShaderVariable &uniform : group) in OutputHLSLImage2DUniformGroup()
720 if (!programD3D.hasNamedUniform(uniform.name)) in OutputHLSLImage2DUniformGroup()
724 for (unsigned int index = 0; index < uniform.getArraySizeProduct(); index++) in OutputHLSLImage2DUniformGroup()
726 switch (image2DBindLayout.at(uniform.binding + index)) in OutputHLSLImage2DUniformGroup()
760 out << "uniform " << Image2DHLSLTextureString(textureGroup, gl::TextureType::_2D) << " " in OutputHLSLImage2DUniformGroup()
767 out << "uniform " << Image2DHLSLTextureStrin in OutputHLSLImage2DUniformGroup()
[all...]
/third_party/skia/src/gpu/gl/
H A DGrGLUniformHandler.cpp40 // the uniform view matrix name in the GP, and the GP is immutable so it has to tell the PB in internalAddUniformArray()
41 // exactly what name it wants to use for the uniform view matrix. If we prefix anythings, then in internalAddUniformArray()
43 // uniform view matrix, they should upload the view matrix in their setData along with regular in internalAddUniformArray()
98 for (const UniformInfo& uniform : fUniforms.items()) { in appendUniformDecls()
99 if (uniform.fVisibility & visibility) { in appendUniformDecls()
100 uniform.fVariable.appendDecl(fProgramBuilder->shaderCaps(), out); in appendUniformDecls()
115 for (GLUniformInfo& uniform : fUniforms.items()) { in bindUniformLocations()
116 GL_CALL(BindUniformLocation(programID, currUniform, uniform.fVariable.c_str())); in bindUniformLocations()
117 uniform.fLocation = currUniform; in bindUniformLocations()
130 for (GLUniformInfo& uniform in getUniformLocations()
[all...]
/third_party/skia/third_party/externals/angle2/src/compiler/translator/
H A DResourcesHLSL.cpp58 // If uniform block's layout is std140 and translating it to StructuredBuffer, in InterfaceBlockFieldTypeString()
208 const ShaderVariable *uniform = findUniformByName(name); in assignUniformRegister() local
209 ASSERT(uniform); in assignUniformRegister()
225 if (uniform->name == "angle_DrawID" && uniform->mappedName == "angle_DrawID") in assignUniformRegister()
231 mUniformRegisterMap[uniform->name] = registerIndex; in assignUniformRegister()
234 if (uniform->name == "angle_BaseVertex" && uniform->mappedName == "angle_BaseVertex") in assignUniformRegister()
240 mUniformRegisterMap[uniform->name] = registerIndex; in assignUniformRegister()
243 if (uniform in assignUniformRegister()
517 const ShaderVariable *uniform = findUniformByName(variable.name()); uniformsHeader() local
557 const ShaderVariable *uniform = findUniformByName(variable.name()); uniformsHeader() local
[all...]
/third_party/glslang/gtests/
H A DVkRelaxed.FromFile.cpp121 const glslang::TObjectReflection& uniform = program.getUniform(i); in verifyIOMapping() local
122 std::string name = interfaceName(uniform); in verifyIOMapping()
123 programUniforms[name] = &uniform; in verifyIOMapping()
131 glslang::TObjectReflection uniform = it->getUniform(i); in verifyIOMapping() local
132 std::string name = interfaceName(uniform); in verifyIOMapping()
136 auto stageQualifier = uniform.getType()->getQualifier(); in verifyIOMapping()
150 // compare uniform blocks in each stage to the program table in verifyIOMapping()
155 const glslang::TObjectReflection& uniform = program.getUniformBlock(i); in verifyIOMapping() local
156 std::string name = interfaceName(uniform); in verifyIOMapping()
157 programUniforms[name] = &uniform; in verifyIOMapping()
165 glslang::TObjectReflection uniform = it->getUniformBlock(i); verifyIOMapping() local
[all...]
H A DGlslMapIO.FromFile.cpp166 const glslang::TObjectReflection& uniform = program.getUniform(i); in verifyIOMapping() local
167 std::string name = interfaceName(uniform); in verifyIOMapping()
168 programUniforms[name] = &uniform; in verifyIOMapping()
176 glslang::TObjectReflection uniform = it->getUniform(i); in verifyIOMapping() local
177 std::string name = interfaceName(uniform); in verifyIOMapping()
181 auto stageQualifier = uniform.getType()->getQualifier(); in verifyIOMapping()
195 // compare uniform blocks in each stage to the program table in verifyIOMapping()
200 const glslang::TObjectReflection& uniform = program.getUniformBlock(i); in verifyIOMapping() local
201 std::string name = interfaceName(uniform); in verifyIOMapping()
202 programUniforms[name] = &uniform; in verifyIOMapping()
210 glslang::TObjectReflection uniform = it->getUniformBlock(i); verifyIOMapping() local
[all...]
/third_party/mesa3d/src/gallium/drivers/d3d12/
H A Dd3d12_lower_point_sprite.c32 nir_variable *uniform; /* (1/w, 1/h, pt_sz, max_sz) */ member
111 /* State uniform contains: (1/ViewportWidth, 1/ViewportHeight, PointSize, MaxPointSize) */ in get_scaled_point_size()
112 nir_ssa_def *uniform = nir_load_var(b, state->uniform); in get_scaled_point_size() local
120 /* Use static point size (from uniform) if the shader output was not set */ in get_scaled_point_size()
121 point_size = nir_channel(b, uniform, 2); in get_scaled_point_size()
125 *x = nir_fmul(b, point_size, nir_channel(b, uniform, 0)); in get_scaled_point_size()
126 *y = nir_fmul(b, point_size, nir_channel(b, uniform, 1)); in get_scaled_point_size()
251 /* Create uniform to retrieve inverse of viewport size and point size: in d3d12_lower_point_sprite()
253 state.uniform in d3d12_lower_point_sprite()
[all...]
/third_party/skia/modules/skottie/src/effects/
H A DBuldgeEffect.cpp26 "uniform shader u_layer;"
28 "uniform float2 u_center;"
29 "uniform float2 u_radius;"
30 "uniform float u_h;"
31 "uniform float u_r;"
32 "uniform float u_asinInverseR;"
33 "uniform float u_rcpR;"
34 "uniform float u_rcpAsinInvR;"
35 "uniform float u_selector;"
109 builder.uniform("u_cente in buildEffectShader()
[all...]
H A DSphereEffect.cpp48 uniform shader child;
50 uniform half3x3 rot_matrix;
51 uniform half2 child_scale;
52 uniform half side_select;
99 uniform half l_coeff_ambient;
108 uniform half3 l_vec;
109 uniform half3 l_color;
110 uniform half l_coeff_ambient;
111 uniform half l_coeff_diffuse;
112 uniform hal
[all...]
/third_party/skia/third_party/externals/angle2/src/tests/perf_tests/
H A DUniformsPerf.cpp7 // Performance test for setting uniform data.
44 // This covers a performance problem in ANGLE where calling UseProgram reuploads uniform data.
186 // Verify the uniform counts are within the limits in initializeBenchmark()
221 FAIL() << "Vertex uniform vector count (" << numVertexUniformVectors << ")" in initializeBenchmark()
222 << " exceeds maximum vertex uniform vector count: " << maxVertexUniformVectors in initializeBenchmark()
227 FAIL() << "Fragment uniform vector count (" << numFragmentUniformVectors << ")" in initializeBenchmark()
228 << " exceeds maximum fragment uniform vector count: " << maxFragmentUniformVectors in initializeBenchmark()
304 vstrstr << "uniform " << typeString << " " << GetUniformLocationName(i, true) << ";\n"; in initShaders()
330 fstrstr << "uniform " << typeString << " " << GetUniformLocationName(i, false) << ";\n"; in initShaders()
396 for (size_t uniform in drawLoop()
[all...]
/third_party/skia/tests/
H A DSkRuntimeEffectTest.cpp44 // Runtime SkSL supports a limited set of uniform types. No bool, for example: in DEF_TEST()
45 test_invalid_effect(r, "uniform bool b;" EMPTY_MAIN, "uniform"); in DEF_TEST()
144 test_valid("uniform shader child;" in DEF_TEST()
148 test_valid("uniform colorFilter child;" in DEF_TEST()
152 test_valid("uniform blender child;" in DEF_TEST()
200 test_valid("uniform shader child;" in DEF_TEST()
204 test_valid("uniform colorFilter child;" in DEF_TEST()
208 test_valid("uniform blender child;" in DEF_TEST()
262 test_valid("uniform shade in DEF_TEST()
325 SkRuntimeShaderBuilder::BuilderUniform uniform(const char* name) { uniform() function in TestEffect
375 SkRuntimeBlendBuilder::BuilderUniform uniform(const char* name) { uniform() function in TestBlend
[all...]
/third_party/skia/src/gpu/d3d/
H A DGrD3DPipelineStateDataManager.cpp20 Uniform& uniform = fUniforms[i]; in GrD3DPipelineStateDataManager() local
24 uniform.fArrayCount = uniformInfo.fVariable.getArrayCount(); in GrD3DPipelineStateDataManager()
25 uniform.fType = uniformInfo.fVariable.getType(); in GrD3DPipelineStateDataManager()
28 uniform.fOffset = uniformInfo.fUBOOffset; in GrD3DPipelineStateDataManager()
/third_party/skia/demos.skia.org/demos/textedit/
H A Dspiralshader.js11 uniform float rad_scale;
12 uniform float2 in_center;
13 uniform float4 in_colors0;
14 uniform float4 in_colors1;
/third_party/vk-gl-cts/external/openglcts/modules/common/
H A DglcUniformBlockCase.cpp565 const Uniform& uniform = *uniformIter; in computeStd140Layout() local
566 computeStd140Layout(layout, curOffset, activeBlockNdx, blockPrefix + uniform.getName(), uniform.getType(), in computeStd140Layout()
567 mergeLayoutFlags(block.getFlags(), uniform.getFlags())); in computeStd140Layout()
584 // Compute active uniform set for block. in computeStd140Layout()
723 void generateDeclaration(std::ostringstream& src, const Uniform& uniform, int indentLevel);
821 void generateDeclaration(std::ostringstream& src, const Uniform& uniform, int indentLevel) in generateDeclaration() argument
823 if ((uniform.getFlags() & LAYOUT_MASK) != 0) in generateDeclaration()
824 src << "layout(" << LayoutFlagsFmt(uniform.getFlags() & LAYOUT_MASK) << ") "; in generateDeclaration()
826 generateDeclaration(src, uniform in generateDeclaration()
1011 const Uniform& uniform = *uniformIter; generateCompareSrc() local
1752 const UniformLayoutEntry& uniform = layout.uniforms[uniformNdx]; checkLayoutIndices() local
1790 const UniformLayoutEntry& uniform = layout.uniforms[uniformNdx]; checkLayoutBounds() local
[all...]
/third_party/skia/third_party/externals/angle2/src/compiler/translator/tree_ops/vulkan/
H A DFlagSamplersWithTexelFetch.cpp7 // a sampler uniform, and flag that uniform as having been used with texelFetch
57 for (ShaderVariable &uniform : *mUniforms)
59 if (samplerVariable.name() == uniform.name)
61 ASSERT(gl::IsSamplerType(uniform.type));
62 uniform.texelFetchStaticUse = true;
/third_party/vk-gl-cts/external/openglcts/modules/gles31/
H A Des31cExplicitUniformLocationTest.cpp643 //uniform value in UniformValue()
967 ret << "uniform ";
979 //add a "zero" uniform;
980 ret << "uniform float zero;" << std::endl;
1002 //layout(location = X) subroutine uniform stX uX[...];
1004 ret << "subroutine uniform " << subroutineUniforms[i].functions.getTypeName() << " "
1012 static void streamUniformValidator(std::ostringstream& ret, const Uniform& uniform, GLenum shader,
1015 if (uniform.declOccurence.occurs(shader) && uniform.usageOccurence.occurs(shader))
1017 if (uniform
[all...]
/third_party/vk-gl-cts/modules/gles31/functional/
H A Des31fProgramUniformTests.cpp23 * \todo [2013-02-26 nuutti] Much duplication between ES2&3 uniform api
323 void addUniform (const Uniform& uniform) { m_uniforms.push_back(uniform); } in addUniform() argument
811 // UNIFORMFUNC_VALUE: use pass-by-value versions of uniform assignment funcs, e.g. glProgramUniform1f(), where possible. If not given, use pass-by-pointer versions.
841 // A basic uniform is a uniform (possibly struct or array member) whose type is a basic type (e.g. float, ivec4, sampler2d).
847 VarValue finalValue; //!< The value we ultimately want to set for this uniform.
897 // Get uniform values with glGetUniform*() and put to valuesDst. Uniforms that get -1 from glGetUniformLocation() get glu::TYPE_INVALID.
901 // Compare the uniform values given in values (obtained with glGetUniform*()) with the basicUniform.finalValue values.
903 // Render and check that all pixels are green (i.e. all uniform comparison
1270 const BasicUniform& uniform = basicUniforms[unifNdx]; getUniforms() local
1351 const BasicUniform& uniform = basicUniforms[unifNdx]; assignUniforms() local
1550 const BasicUniform& uniform = basicUniforms[unifNdx]; compareUniformValues() local
[all...]
/third_party/vk-gl-cts/external/vulkancts/modules/vulkan/texture/
H A DvktTextureTexelBufferTests.cpp40 de::MovePtr<tcu::TestCaseGroup> uniform (new tcu::TestCaseGroup(testCtx, "uniform")); in createUniformTexelBufferTests()
45 static const char dataDir[] = "texture/texel_buffer/uniform/srgb"; in createUniformTexelBufferTests()
60 uniform->addChild(srgb); in createUniformTexelBufferTests()
106 // Test uniform texel buffer with packed formats in createUniformTexelBufferTests()
108 static const char dataDir[] = "texture/texel_buffer/uniform/packed"; in createUniformTexelBufferTests()
121 uniform->addChild(packed); in createUniformTexelBufferTests()
136 tcu::TestCaseGroup* const snorm = new tcu::TestCaseGroup(testCtx, "snorm", "Test uniform texel buffer with SNORM formats"); in createUniformTexelBufferTests()
137 static const char dataDir[] = "texture/texel_buffer/uniform/snorm"; in createUniformTexelBufferTests()
157 uniform in createUniformTexelBufferTests()
[all...]
/third_party/vk-gl-cts/external/vulkancts/modules_no_buildgn/vulkan/texture/
H A DvktTextureTexelBufferTests.cpp40 de::MovePtr<tcu::TestCaseGroup> uniform (new tcu::TestCaseGroup(testCtx, "uniform", "Test uniform texel buffer")); in createUniformTexelBufferTests()
44 tcu::TestCaseGroup* const srgb = new tcu::TestCaseGroup(testCtx, "srgb", "Test uniform texel buffer with srgb formats"); in createUniformTexelBufferTests()
45 static const char dataDir[] = "texture/texel_buffer/uniform/srgb"; in createUniformTexelBufferTests()
60 uniform->addChild(srgb); in createUniformTexelBufferTests()
106 tcu::TestCaseGroup* const packed = new tcu::TestCaseGroup(testCtx, "packed", "Test uniform texel buffer with packed formats"); in createUniformTexelBufferTests()
107 static const char dataDir[] = "texture/texel_buffer/uniform/packed"; in createUniformTexelBufferTests()
120 uniform->addChild(packed); in createUniformTexelBufferTests()
135 tcu::TestCaseGroup* const snorm = new tcu::TestCaseGroup(testCtx, "snorm", "Test uniform texe in createUniformTexelBufferTests()
[all...]
/third_party/vk-gl-cts/modules/gles3/functional/
H A Des3fUniformApiTests.cpp343 void addUniform (const Uniform& uniform) { m_uniforms.push_back(uniform); }
526 Uniform uniform(("u_var" + de::toString(i)).c_str(), glu::VarType()); in random()
534 uniform.type = generateRandomType(3, structIdx, structTypes, rnd); in random()
535 } while (res->getNumSamplers() + getNumSamplersInType(uniform.type) > MAX_NUM_SAMPLER_UNIFORMS); in random()
537 res->addUniform(uniform); in random()
917 // UNIFORMFUNC_VALUE: use pass-by-value versions of uniform assignment funcs, e.g. glUniform1f(), where possible. If not given, use pass-by-pointer versions.
934 // UNIFORMVALUE_ZERO: use zero-valued uniforms. If not given, use random uniform values.
951 // A basic uniform is a uniform (possibl
1711 const BasicUniform& uniform = basicUniforms[unifNdx]; getUniforms() local
1790 const BasicUniform& uniform = basicUniforms[unifNdx]; checkUniformDefaultValues() local
1848 const BasicUniform& uniform = basicUniforms[unifNdx]; assignUniforms() local
2047 const BasicUniform& uniform = basicUniforms[unifNdx]; compareUniformValues() local
[all...]
/third_party/skia/gm/
H A Druntimeshader.cpp65 uniform half4 gColor;
77 builder.uniform("gColor") = SkColor4f{1, 0, 0, 1};
127 uniform shader before_map;
128 uniform shader after_map;
129 uniform shader threshold_map;
131 uniform float cutoff;
132 uniform float slope;
162 builder.uniform("cutoff") = sin(fSecs) * 0.55f + 0.5f;
163 builder.uniform("slope") = 10.0f;
190 uniform floa in SpiralRT()
[all...]
/third_party/vk-gl-cts/modules/gles2/functional/
H A Des2fUniformApiTests.cpp277 void addUniform (const Uniform& uniform) { m_uniforms.push_back(uniform); }
460 Uniform uniform(("u_var" + de::toString(i)).c_str(), glu::VarType()); in random()
468 uniform.type = generateRandomType(3, structIdx, structTypes, rnd); in random()
469 } while (res->getNumSamplers() + getNumSamplersInType(uniform.type) > MAX_NUM_SAMPLER_UNIFORMS); in random()
471 res->addUniform(uniform); in random()
756 // UNIFORMFUNC_VALUE: use pass-by-value versions of uniform assignment funcs, e.g. glUniform1f(), where possible. If not given, use pass-by-pointer versions.
769 // UNIFORMVALUE_ZERO: use zero-valued uniforms. If not given, use random uniform values.
786 // A basic uniform is a uniform (possibl
1354 const BasicUniform& uniform = basicUniforms[unifNdx]; getUniforms() local
1424 const BasicUniform& uniform = basicUniforms[unifNdx]; checkUniformDefaultValues() local
1477 const BasicUniform& uniform = basicUniforms[unifNdx]; assignUniforms() local
1635 const BasicUniform& uniform = basicUniforms[unifNdx]; compareUniformValues() local
[all...]

Completed in 23 milliseconds

12345678