Home | History | Annotate | Download | only in libGLESv2

Lines Matching full:uniform

44 	Uniform::BlockInfo::BlockInfo(const glsl::Uniform& uniform, int blockIndex)
49 offset = uniform.blockInfo.offset;
50 arrayStride = uniform.blockInfo.arrayStride;
51 matrixStride = uniform.blockInfo.matrixStride;
52 isRowMajorMatrix = uniform.blockInfo.isRowMajorMatrix;
64 Uniform::Uniform(const glsl::Uniform &uniform, const BlockInfo &blockInfo)
65 : type(uniform.type), precision(uniform.precision), name(uniform.name),
66 arraySize(uniform.arraySize), blockInfo(blockInfo), fields(uniform.fields)
68 if((blockInfo.index == -1) && uniform.fields.empty())
84 Uniform::~Uniform()
89 bool Uniform::isArray() const
94 int Uniform::size() const
99 int Uniform::registerCount() const
533 Uniform *targetUniform = uniforms[uniformIndex[location].index];
540 return false; // Attempting to write an array to a non-array uniform is an INVALID_OPERATION
623 Uniform *targetUniform = uniforms[uniformIndex[location].index];
635 return false; // Attempting to write an array to a non-array uniform is an INVALID_OPERATION
720 Uniform *targetUniform = uniforms[uniformIndex[location].index];
727 return false; // Attempting to write an array to a non-array uniform is an INVALID_OPERATION
776 Uniform *targetUniform = uniforms[uniformIndex[location].index];
783 return false; // Attempting to write an array to a non-array uniform is an INVALID_OPERATION
838 Uniform *targetUniform = uniforms[uniformIndex[location].index];
845 return false; // Attempting to write an array to a non-array uniform is an INVALID_OPERATION
894 Uniform *targetUniform = uniforms[uniformIndex[location].index];
901 return false; // Attempting to write an array to a non-array uniform is an INVALID_OPERATION
956 Uniform *targetUniform = uniforms[uniformIndex[location].index];
1014 Uniform *targetUniform = uniforms[uniformIndex[location].index];
1063 Uniform *targetUniform = uniforms[uniformIndex[location].index];
1125 Uniform *targetUniform = uniforms[uniformIndex[location].index];
1581 // Link uniform blocks before uniforms to make it easy to assign block indices to fields
1710 for(const auto &uniform : shader->activeUniforms)
1713 if(uniform.blockId >= 0)
1716 ASSERT(static_cast<size_t>(uniform.blockId) < activeUniformBlocks.size());
1717 blockIndex = getUniformBlockIndex(activeUniformBlocks[uniform.blockId].name);
1720 uniform, Uniform::BlockInfo(uniform, blockIndex)))
1737 bool Program::defineUniform(GLenum shader, const glsl::Uniform &glslUniform, const Uniform::BlockInfo& blockInfo)
1824 Uniform *uniform = 0;
1829 uniform = uniforms[uniformIndex[location].index];
1831 if(uniform->type != glslUniform.type)
1833 appendToInfoLog("Types for uniform %s do not match between the vertex and fragment shader", uniform->name.c_str());
1837 if(uniform->precision != glslUniform.precision)
1839 appendToInfoLog("Precisions for uniform %s do not match between the vertex and fragment shader", uniform->name.c_str());
1843 if(!areMatchingFields(uniform->fields, glslUniform.fields, uniform->name))
1850 uniform = new Uniform(glslUniform, blockInfo);
1853 if(!uniform)
1860 uniform->vsRegisterIndex = glslUniform.registerIndex;
1864 uniform->psRegisterIndex = glslUniform.registerIndex;
1870 uniforms.push_back(uniform);
1873 for(int i = 0; i < uniform->size(); i++)
1881 if(glslUniform.registerIndex + uniform->registerCount() > MAX_VERTEX_UNIFORM_VECTORS)
1889 if(glslUniform.registerIndex + uniform->registerCount() > MAX_FRAGMENT_UNIFORM_VECTORS)
1900 bool Program::validateUniformStruct(GLenum shader, const glsl::Uniform &newUniformStruct)
1910 uniformStructs.push_back(Uniform(newUniformStruct, Uniform::BlockInfo(newUniformStruct, -1)));
1936 const glsl::Uniform& member1 = shader1->activeUniforms[block1.fields[blockMemberIndex]];
1937 const glsl::Uniform& member2 = shader2->activeUniforms[block2.fields[blockMemberIndex]];
2092 Uniform *targetUniform = uniforms[uniformIndex[location].index];
2375 Uniform *targetUniform = uniforms[uniformIndex[location].index];
2477 Uniform *targetUniform = uniforms[uniformIndex[location].index];
2853 const Uniform& uniform = *uniforms[index];
2856 case GL_UNIFORM_TYPE: return static_cast<GLint>(uniform.type);
2857 case GL_UNIFORM_SIZE: return static_cast<GLint>(uniform.size());
2858 case GL_UNIFORM_NAME_LENGTH: return static_cast<GLint>(uniform.name.size() + 1 + (uniform.isArray() ? 3 : 0));
2859 case GL_UNIFORM_BLOCK_INDEX: return uniform.blockInfo.index;
2860 case GL_UNIFORM_OFFSET: return uniform.blockInfo.offset;
2861 case GL_UNIFORM_ARRAY_STRIDE: return uniform.blockInfo.arrayStride;
2862 case GL_UNIFORM_MATRIX_STRIDE: return uniform.blockInfo.matrixStride;
2863 case GL_UNIFORM_IS_ROW_MAJOR: return static_cast<GLint>(uniform.blockInfo.isRowMajorMatrix);
3061 appendToInfoLog("Sampler uniform (%d) exceeds MAX_COMBINED_TEXTURE_IMAGE_UNITS (%d)", unit, MAX_COMBINED_TEXTURE_IMAGE_UNITS);
3096 appendToInfoLog("Sampler uniform (%d) exceeds MAX_COMBINED_TEXTURE_IMAGE_UNITS (%d)", unit, MAX_COMBINED_TEXTURE_IMAGE_UNITS);