OpenGL2: Use CPU vertex animation if too few vertex attributes
OpenGL ES has a minimum of 8 vertex attributes while desktop OpenGL has a minimum of 16. Vertex animation uses attributes 10 to 12.
This commit is contained in:
1 parent
b25a3c6e4d
commit
98b9008c0d
5 files changed
+53
-11
No files matched your search
@@ -279,6 +279,9 @@ static void InitOpenGL( void )
|
||||
qglGetIntegerv( GL_MAX_TEXTURE_IMAGE_UNITS, &temp );
|
||||
glConfig.numTextureUnits = temp;
|
||||
|
||||
qglGetIntegerv( GL_MAX_VERTEX_ATTRIBS, &temp );
|
||||
glRefConfig.maxVertexAttribs = temp;
|
||||
|
||||
// reserve 160 components for other uniforms
|
||||
qglGetIntegerv( GL_MAX_VERTEX_UNIFORM_COMPONENTS, &temp );
|
||||
glRefConfig.glslMaxAnimatedBones = Com_Clamp( 0, IQM_MAX_JOINTS, ( temp - 160 ) / 16 );
|
||||
|
||||
Reference in new issue
Block a user