1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
5 #include "gpu/command_buffer/service/gles2_cmd_decoder.h"
7 #include "gpu/command_buffer/common/gles2_cmd_format.h"
8 #include "gpu/command_buffer/common/gles2_cmd_utils.h"
9 #include "gpu/command_buffer/service/gles2_cmd_decoder_unittest_base.h"
10 #include "gpu/command_buffer/service/cmd_buffer_engine.h"
11 #include "gpu/command_buffer/service/context_group.h"
12 #include "gpu/command_buffer/service/program_manager.h"
13 #include "gpu/command_buffer/service/test_helper.h"
14 #include "testing/gtest/include/gtest/gtest.h"
15 #include "ui/gl/gl_mock.h"
17 using ::gfx::MockGLInterface
;
19 using ::testing::AnyNumber
;
20 using ::testing::DoAll
;
21 using ::testing::InSequence
;
22 using ::testing::MatcherCast
;
23 using ::testing::Pointee
;
24 using ::testing::Return
;
25 using ::testing::SetArrayArgument
;
26 using ::testing::SetArgumentPointee
;
27 using ::testing::StrEq
;
32 class GLES2DecoderTest2
: public GLES2DecoderTestBase
{
34 GLES2DecoderTest2() { }
36 void TestAcceptedUniform(GLenum uniform_type
, uint32 accepts_apis
) {
37 SetupShaderForUniform(uniform_type
);
38 bool valid_uniform
= false;
40 EXPECT_CALL(*gl_
, Uniform1i(1, _
)).Times(AnyNumber());
41 EXPECT_CALL(*gl_
, Uniform1iv(1, _
, _
)).Times(AnyNumber());
42 EXPECT_CALL(*gl_
, Uniform2iv(1, _
, _
)).Times(AnyNumber());
43 EXPECT_CALL(*gl_
, Uniform3iv(1, _
, _
)).Times(AnyNumber());
44 EXPECT_CALL(*gl_
, Uniform4iv(1, _
, _
)).Times(AnyNumber());
45 EXPECT_CALL(*gl_
, Uniform1f(1, _
)).Times(AnyNumber());
46 EXPECT_CALL(*gl_
, Uniform1fv(1, _
, _
)).Times(AnyNumber());
47 EXPECT_CALL(*gl_
, Uniform2fv(1, _
, _
)).Times(AnyNumber());
48 EXPECT_CALL(*gl_
, Uniform3fv(1, _
, _
)).Times(AnyNumber());
49 EXPECT_CALL(*gl_
, Uniform4fv(1, _
, _
)).Times(AnyNumber());
50 EXPECT_CALL(*gl_
, UniformMatrix2fv(1, _
, _
, _
)).Times(AnyNumber());
51 EXPECT_CALL(*gl_
, UniformMatrix3fv(1, _
, _
, _
)).Times(AnyNumber());
52 EXPECT_CALL(*gl_
, UniformMatrix4fv(1, _
, _
, _
)).Times(AnyNumber());
55 valid_uniform
= accepts_apis
& Program::kUniform1i
;
58 EXPECT_EQ(error::kNoError
, ExecuteCmd(cmd
));
59 EXPECT_EQ(valid_uniform
? GL_NO_ERROR
: GL_INVALID_OPERATION
,
64 valid_uniform
= accepts_apis
& Program::kUniform1i
;
65 cmds::Uniform1ivImmediate
& cmd
=
66 *GetImmediateAs
<cmds::Uniform1ivImmediate
>();
67 GLint data
[2][1] = {{0}};
68 cmd
.Init(1, 2, &data
[0][0]);
69 EXPECT_EQ(error::kNoError
, ExecuteImmediateCmd(cmd
, sizeof(data
)));
70 EXPECT_EQ(valid_uniform
? GL_NO_ERROR
: GL_INVALID_OPERATION
,
75 valid_uniform
= accepts_apis
& Program::kUniform2i
;
78 EXPECT_EQ(error::kNoError
, ExecuteCmd(cmd
));
79 EXPECT_EQ(valid_uniform
? GL_NO_ERROR
: GL_INVALID_OPERATION
,
84 valid_uniform
= accepts_apis
& Program::kUniform2i
;
85 cmds::Uniform2ivImmediate
& cmd
=
86 *GetImmediateAs
<cmds::Uniform2ivImmediate
>();
87 GLint data
[2][2] = {{0}};
88 cmd
.Init(1, 2, &data
[0][0]);
89 EXPECT_EQ(error::kNoError
, ExecuteImmediateCmd(cmd
, sizeof(data
)));
90 EXPECT_EQ(valid_uniform
? GL_NO_ERROR
: GL_INVALID_OPERATION
,
95 valid_uniform
= accepts_apis
& Program::kUniform3i
;
98 EXPECT_EQ(error::kNoError
, ExecuteCmd(cmd
));
99 EXPECT_EQ(valid_uniform
? GL_NO_ERROR
: GL_INVALID_OPERATION
,
104 valid_uniform
= accepts_apis
& Program::kUniform3i
;
105 cmds::Uniform3ivImmediate
& cmd
=
106 *GetImmediateAs
<cmds::Uniform3ivImmediate
>();
107 GLint data
[2][3] = {{0}};
108 cmd
.Init(1, 2, &data
[0][0]);
109 EXPECT_EQ(error::kNoError
, ExecuteImmediateCmd(cmd
, sizeof(data
)));
110 EXPECT_EQ(valid_uniform
? GL_NO_ERROR
: GL_INVALID_OPERATION
,
115 valid_uniform
= accepts_apis
& Program::kUniform4i
;
117 cmd
.Init(1, 2, 3, 4, 5);
118 EXPECT_EQ(error::kNoError
, ExecuteCmd(cmd
));
119 EXPECT_EQ(valid_uniform
? GL_NO_ERROR
: GL_INVALID_OPERATION
,
124 valid_uniform
= accepts_apis
& Program::kUniform4i
;
125 cmds::Uniform4ivImmediate
& cmd
=
126 *GetImmediateAs
<cmds::Uniform4ivImmediate
>();
127 GLint data
[2][4] = {{0}};
128 cmd
.Init(1, 2, &data
[0][0]);
129 EXPECT_EQ(error::kNoError
, ExecuteImmediateCmd(cmd
, sizeof(data
)));
130 EXPECT_EQ(valid_uniform
? GL_NO_ERROR
: GL_INVALID_OPERATION
,
137 valid_uniform
= accepts_apis
& Program::kUniform1f
;
140 EXPECT_EQ(error::kNoError
, ExecuteCmd(cmd
));
141 EXPECT_EQ(valid_uniform
? GL_NO_ERROR
: GL_INVALID_OPERATION
,
146 valid_uniform
= accepts_apis
& Program::kUniform1f
;
147 cmds::Uniform1fvImmediate
& cmd
=
148 *GetImmediateAs
<cmds::Uniform1fvImmediate
>();
149 GLfloat data
[2][1] = {{0.0f
}};
150 cmd
.Init(1, 2, &data
[0][0]);
151 EXPECT_EQ(error::kNoError
, ExecuteImmediateCmd(cmd
, sizeof(data
)));
152 EXPECT_EQ(valid_uniform
? GL_NO_ERROR
: GL_INVALID_OPERATION
,
157 valid_uniform
= accepts_apis
& Program::kUniform2f
;
160 EXPECT_EQ(error::kNoError
, ExecuteCmd(cmd
));
161 EXPECT_EQ(valid_uniform
? GL_NO_ERROR
: GL_INVALID_OPERATION
,
166 valid_uniform
= accepts_apis
& Program::kUniform2f
;
167 cmds::Uniform2fvImmediate
& cmd
=
168 *GetImmediateAs
<cmds::Uniform2fvImmediate
>();
169 GLfloat data
[2][2] = {{0.0f
}};
170 cmd
.Init(1, 2, &data
[0][0]);
171 EXPECT_EQ(error::kNoError
, ExecuteImmediateCmd(cmd
, sizeof(data
)));
172 EXPECT_EQ(valid_uniform
? GL_NO_ERROR
: GL_INVALID_OPERATION
,
177 valid_uniform
= accepts_apis
& Program::kUniform3f
;
179 cmd
.Init(1, 2, 3, 4);
180 EXPECT_EQ(error::kNoError
, ExecuteCmd(cmd
));
181 EXPECT_EQ(valid_uniform
? GL_NO_ERROR
: GL_INVALID_OPERATION
,
186 valid_uniform
= accepts_apis
& Program::kUniform3f
;
187 cmds::Uniform3fvImmediate
& cmd
=
188 *GetImmediateAs
<cmds::Uniform3fvImmediate
>();
189 GLfloat data
[2][3] = {{0.0f
}};
190 cmd
.Init(1, 2, &data
[0][0]);
191 EXPECT_EQ(error::kNoError
, ExecuteImmediateCmd(cmd
, sizeof(data
)));
192 EXPECT_EQ(valid_uniform
? GL_NO_ERROR
: GL_INVALID_OPERATION
,
197 valid_uniform
= accepts_apis
& Program::kUniform4f
;
199 cmd
.Init(1, 2, 3, 4, 5);
200 EXPECT_EQ(error::kNoError
, ExecuteCmd(cmd
));
201 EXPECT_EQ(valid_uniform
? GL_NO_ERROR
: GL_INVALID_OPERATION
,
206 valid_uniform
= accepts_apis
& Program::kUniform4f
;
207 cmds::Uniform4fvImmediate
& cmd
=
208 *GetImmediateAs
<cmds::Uniform4fvImmediate
>();
209 GLfloat data
[2][4] = {{0.0f
}};
210 cmd
.Init(1, 2, &data
[0][0]);
211 EXPECT_EQ(error::kNoError
, ExecuteImmediateCmd(cmd
, sizeof(data
)));
212 EXPECT_EQ(valid_uniform
? GL_NO_ERROR
: GL_INVALID_OPERATION
,
217 valid_uniform
= accepts_apis
& Program::kUniformMatrix2f
;
218 cmds::UniformMatrix2fvImmediate
& cmd
=
219 *GetImmediateAs
<cmds::UniformMatrix2fvImmediate
>();
220 GLfloat data
[2][2 * 2] = {{0.0f
}};
222 cmd
.Init(1, 2, &data
[0][0]);
223 EXPECT_EQ(error::kNoError
, ExecuteImmediateCmd(cmd
, sizeof(data
)));
224 EXPECT_EQ(valid_uniform
? GL_NO_ERROR
: GL_INVALID_OPERATION
,
229 valid_uniform
= accepts_apis
& Program::kUniformMatrix3f
;
230 cmds::UniformMatrix3fvImmediate
& cmd
=
231 *GetImmediateAs
<cmds::UniformMatrix3fvImmediate
>();
232 GLfloat data
[2][3 * 3] = {{0.0f
}};
233 cmd
.Init(1, 2, &data
[0][0]);
234 EXPECT_EQ(error::kNoError
, ExecuteImmediateCmd(cmd
, sizeof(data
)));
235 EXPECT_EQ(valid_uniform
? GL_NO_ERROR
: GL_INVALID_OPERATION
,
240 valid_uniform
= accepts_apis
& Program::kUniformMatrix4f
;
241 cmds::UniformMatrix4fvImmediate
& cmd
=
242 *GetImmediateAs
<cmds::UniformMatrix4fvImmediate
>();
243 GLfloat data
[2][4 * 4] = {{0.0f
}};
244 cmd
.Init(1, 2, &data
[0][0]);
245 EXPECT_EQ(error::kNoError
, ExecuteImmediateCmd(cmd
, sizeof(data
)));
246 EXPECT_EQ(valid_uniform
? GL_NO_ERROR
: GL_INVALID_OPERATION
,
252 INSTANTIATE_TEST_CASE_P(Service
, GLES2DecoderTest2
, ::testing::Bool());
255 void GLES2DecoderTestBase::SpecializedSetup
<
256 cmds::GetRenderbufferParameteriv
, 0>(
258 DoBindRenderbuffer(GL_RENDERBUFFER
, client_renderbuffer_id_
,
259 kServiceRenderbufferId
);
263 void GLES2DecoderTestBase::SpecializedSetup
<cmds::RenderbufferStorage
, 0>(
265 DoBindRenderbuffer(GL_RENDERBUFFER
, client_renderbuffer_id_
,
266 kServiceRenderbufferId
);
268 EnsureRenderbufferBound(false);
269 EXPECT_CALL(*gl_
, GetError())
270 .WillOnce(Return(GL_NO_ERROR
))
271 .RetiresOnSaturation();
273 RenderbufferStorageEXT(GL_RENDERBUFFER
, _
, 3, 4))
275 .RetiresOnSaturation();
276 EXPECT_CALL(*gl_
, GetError())
277 .WillOnce(Return(GL_NO_ERROR
))
278 .RetiresOnSaturation();
283 void GLES2DecoderTestBase::SpecializedSetup
<cmds::GenQueriesEXTImmediate
, 0>(
286 // Make the client_query_id_ so that trying to make it again
288 cmds::GenQueriesEXTImmediate
& cmd
=
289 *GetImmediateAs
<cmds::GenQueriesEXTImmediate
>();
290 cmd
.Init(1, &client_query_id_
);
291 EXPECT_EQ(error::kNoError
,
292 ExecuteImmediateCmd(cmd
, sizeof(client_query_id_
)));
297 void GLES2DecoderTestBase::SpecializedSetup
<cmds::DeleteQueriesEXTImmediate
, 0>(
300 // Make the client_query_id_ so that trying to delete it will succeed.
301 cmds::GenQueriesEXTImmediate
& cmd
=
302 *GetImmediateAs
<cmds::GenQueriesEXTImmediate
>();
303 cmd
.Init(1, &client_query_id_
);
304 EXPECT_EQ(error::kNoError
,
305 ExecuteImmediateCmd(cmd
, sizeof(client_query_id_
)));
310 void GLES2DecoderTestBase::SpecializedSetup
<cmds::LinkProgram
, 0>(
312 const GLuint kClientVertexShaderId
= 5001;
313 const GLuint kServiceVertexShaderId
= 6001;
314 const GLuint kClientFragmentShaderId
= 5002;
315 const GLuint kServiceFragmentShaderId
= 6002;
317 GL_VERTEX_SHADER
, kClientVertexShaderId
, kServiceVertexShaderId
);
319 GL_FRAGMENT_SHADER
, kClientFragmentShaderId
, kServiceFragmentShaderId
);
321 TestHelper::SetShaderStates(
322 gl_
.get(), GetShader(kClientVertexShaderId
), true);
323 TestHelper::SetShaderStates(
324 gl_
.get(), GetShader(kClientFragmentShaderId
), true);
328 AttachShader(kServiceProgramId
, kServiceVertexShaderId
))
330 .RetiresOnSaturation();
332 AttachShader(kServiceProgramId
, kServiceFragmentShaderId
))
334 .RetiresOnSaturation();
335 EXPECT_CALL(*gl_
, GetProgramiv(kServiceProgramId
, GL_LINK_STATUS
, _
))
336 .WillOnce(SetArgumentPointee
<2>(1));
338 GetProgramiv(kServiceProgramId
, GL_INFO_LOG_LENGTH
, _
))
339 .WillOnce(SetArgumentPointee
<2>(0))
340 .RetiresOnSaturation();
341 EXPECT_CALL(*gl_
, GetProgramiv(kServiceProgramId
, GL_ACTIVE_ATTRIBUTES
, _
))
342 .WillOnce(SetArgumentPointee
<2>(0));
345 GetProgramiv(kServiceProgramId
, GL_ACTIVE_ATTRIBUTE_MAX_LENGTH
, _
))
346 .WillOnce(SetArgumentPointee
<2>(0));
347 EXPECT_CALL(*gl_
, GetProgramiv(kServiceProgramId
, GL_ACTIVE_UNIFORMS
, _
))
348 .WillOnce(SetArgumentPointee
<2>(0));
351 GetProgramiv(kServiceProgramId
, GL_ACTIVE_UNIFORM_MAX_LENGTH
, _
))
352 .WillOnce(SetArgumentPointee
<2>(0));
354 cmds::AttachShader attach_cmd
;
355 attach_cmd
.Init(client_program_id_
, kClientVertexShaderId
);
356 EXPECT_EQ(error::kNoError
, ExecuteCmd(attach_cmd
));
358 attach_cmd
.Init(client_program_id_
, kClientFragmentShaderId
);
359 EXPECT_EQ(error::kNoError
, ExecuteCmd(attach_cmd
));
363 void GLES2DecoderTestBase::SpecializedSetup
<cmds::Uniform1f
, 0>(
365 SetupShaderForUniform(GL_FLOAT
);
369 void GLES2DecoderTestBase::SpecializedSetup
<cmds::Uniform1fvImmediate
, 0>(
371 SetupShaderForUniform(GL_FLOAT
);
375 void GLES2DecoderTestBase::SpecializedSetup
<cmds::Uniform1ivImmediate
, 0>(
377 SetupShaderForUniform(GL_INT
);
381 void GLES2DecoderTestBase::SpecializedSetup
<cmds::Uniform2f
, 0>(
383 SetupShaderForUniform(GL_FLOAT_VEC2
);
387 void GLES2DecoderTestBase::SpecializedSetup
<cmds::Uniform2i
, 0>(
389 SetupShaderForUniform(GL_INT_VEC2
);
393 void GLES2DecoderTestBase::SpecializedSetup
<cmds::Uniform2fvImmediate
, 0>(
395 SetupShaderForUniform(GL_FLOAT_VEC2
);
399 void GLES2DecoderTestBase::SpecializedSetup
<cmds::Uniform2ivImmediate
, 0>(
401 SetupShaderForUniform(GL_INT_VEC2
);
405 void GLES2DecoderTestBase::SpecializedSetup
<cmds::Uniform3f
, 0>(
407 SetupShaderForUniform(GL_FLOAT_VEC3
);
411 void GLES2DecoderTestBase::SpecializedSetup
<cmds::Uniform3i
, 0>(
413 SetupShaderForUniform(GL_INT_VEC3
);
417 void GLES2DecoderTestBase::SpecializedSetup
<cmds::Uniform3fvImmediate
, 0>(
419 SetupShaderForUniform(GL_FLOAT_VEC3
);
423 void GLES2DecoderTestBase::SpecializedSetup
<cmds::Uniform3ivImmediate
, 0>(
425 SetupShaderForUniform(GL_INT_VEC3
);
429 void GLES2DecoderTestBase::SpecializedSetup
<cmds::Uniform4f
, 0>(
431 SetupShaderForUniform(GL_FLOAT_VEC4
);
435 void GLES2DecoderTestBase::SpecializedSetup
<cmds::Uniform4i
, 0>(
437 SetupShaderForUniform(GL_INT_VEC4
);
441 void GLES2DecoderTestBase::SpecializedSetup
<cmds::Uniform4fvImmediate
, 0>(
443 SetupShaderForUniform(GL_FLOAT_VEC4
);
447 void GLES2DecoderTestBase::SpecializedSetup
<cmds::Uniform4ivImmediate
, 0>(
449 SetupShaderForUniform(GL_INT_VEC4
);
453 void GLES2DecoderTestBase::SpecializedSetup
<cmds::UniformMatrix2fvImmediate
, 0>(
455 SetupShaderForUniform(GL_FLOAT_MAT2
);
459 void GLES2DecoderTestBase::SpecializedSetup
<cmds::TexParameterf
, 0>(
461 DoBindTexture(GL_TEXTURE_2D
, client_texture_id_
, kServiceTextureId
);
465 void GLES2DecoderTestBase::SpecializedSetup
<cmds::TexParameteri
, 0>(
467 DoBindTexture(GL_TEXTURE_2D
, client_texture_id_
, kServiceTextureId
);
471 void GLES2DecoderTestBase::SpecializedSetup
<cmds::TexParameterfvImmediate
, 0>(
473 DoBindTexture(GL_TEXTURE_2D
, client_texture_id_
, kServiceTextureId
);
477 void GLES2DecoderTestBase::SpecializedSetup
<cmds::TexParameterivImmediate
, 0>(
479 DoBindTexture(GL_TEXTURE_2D
, client_texture_id_
, kServiceTextureId
);
483 void GLES2DecoderTestBase::SpecializedSetup
<cmds::GetVertexAttribiv
, 0>(
485 DoBindBuffer(GL_ARRAY_BUFFER
, client_buffer_id_
, kServiceBufferId
);
486 DoVertexAttribPointer(1, 1, GL_FLOAT
, 0, 0);
488 EXPECT_CALL(*gl_
, GetError())
489 .WillOnce(Return(GL_NO_ERROR
))
490 .WillOnce(Return(GL_NO_ERROR
))
491 .RetiresOnSaturation();
496 void GLES2DecoderTestBase::SpecializedSetup
<cmds::GetVertexAttribfv
, 0>(
498 DoBindBuffer(GL_ARRAY_BUFFER
, client_buffer_id_
, kServiceBufferId
);
499 DoVertexAttribPointer(1, 1, GL_FLOAT
, 0, 0);
501 EXPECT_CALL(*gl_
, GetError())
502 .WillOnce(Return(GL_NO_ERROR
))
503 .WillOnce(Return(GL_NO_ERROR
))
504 .RetiresOnSaturation();
509 void GLES2DecoderTestBase::SpecializedSetup
<cmds::GetVertexAttribIiv
, 0>(
511 DoBindBuffer(GL_ARRAY_BUFFER
, client_buffer_id_
, kServiceBufferId
);
512 DoVertexAttribPointer(1, 1, GL_FLOAT
, 0, 0);
514 EXPECT_CALL(*gl_
, GetError())
515 .WillOnce(Return(GL_NO_ERROR
))
516 .WillOnce(Return(GL_NO_ERROR
))
517 .RetiresOnSaturation();
522 void GLES2DecoderTestBase::SpecializedSetup
<cmds::GetVertexAttribIuiv
, 0>(
524 DoBindBuffer(GL_ARRAY_BUFFER
, client_buffer_id_
, kServiceBufferId
);
525 DoVertexAttribPointer(1, 1, GL_FLOAT
, 0, 0);
527 EXPECT_CALL(*gl_
, GetError())
528 .WillOnce(Return(GL_NO_ERROR
))
529 .WillOnce(Return(GL_NO_ERROR
))
530 .RetiresOnSaturation();
535 #include "gpu/command_buffer/service/gles2_cmd_decoder_unittest_2_autogen.h"
537 TEST_P(GLES2DecoderTest2
, AcceptsUniform_GL_INT
) {
538 TestAcceptedUniform(GL_INT
, Program::kUniform1i
);
541 TEST_P(GLES2DecoderTest2
, AcceptsUniform_GL_INT_VEC2
) {
542 TestAcceptedUniform(GL_INT_VEC2
, Program::kUniform2i
);
545 TEST_P(GLES2DecoderTest2
, AcceptsUniform_GL_INT_VEC3
) {
546 TestAcceptedUniform(GL_INT_VEC3
, Program::kUniform3i
);
549 TEST_P(GLES2DecoderTest2
, AcceptsUniform_GL_INT_VEC4
) {
550 TestAcceptedUniform(GL_INT_VEC4
, Program::kUniform4i
);
553 TEST_P(GLES2DecoderTest2
, AcceptsUniform_GL_BOOL
) {
554 TestAcceptedUniform(GL_BOOL
, Program::kUniform1i
| Program::kUniform1f
);
557 TEST_P(GLES2DecoderTest2
, AcceptsUniform_GL_BOOL_VEC2
) {
558 TestAcceptedUniform(GL_BOOL_VEC2
, Program::kUniform2i
| Program::kUniform2f
);
561 TEST_P(GLES2DecoderTest2
, AcceptsUniform_GL_BOOL_VEC3
) {
562 TestAcceptedUniform(GL_BOOL_VEC3
, Program::kUniform3i
| Program::kUniform3f
);
565 TEST_P(GLES2DecoderTest2
, AcceptsUniform_GL_BOOL_VEC4
) {
566 TestAcceptedUniform(GL_BOOL_VEC4
, Program::kUniform4i
| Program::kUniform4f
);
569 TEST_P(GLES2DecoderTest2
, AcceptsUniformTypeFLOAT
) {
570 TestAcceptedUniform(GL_FLOAT
, Program::kUniform1f
);
573 TEST_P(GLES2DecoderTest2
, AcceptsUniform_GL_FLOAT_VEC2
) {
574 TestAcceptedUniform(GL_FLOAT_VEC2
, Program::kUniform2f
);
577 TEST_P(GLES2DecoderTest2
, AcceptsUniform_GL_FLOAT_VEC3
) {
578 TestAcceptedUniform(GL_FLOAT_VEC3
, Program::kUniform3f
);
581 TEST_P(GLES2DecoderTest2
, AcceptsUniform_GL_FLOAT_VEC4
) {
582 TestAcceptedUniform(GL_FLOAT_VEC4
, Program::kUniform4f
);
585 TEST_P(GLES2DecoderTest2
, AcceptsUniform_GL_FLOAT_MAT2
) {
586 TestAcceptedUniform(GL_FLOAT_MAT2
, Program::kUniformMatrix2f
);
589 TEST_P(GLES2DecoderTest2
, AcceptsUniform_GL_FLOAT_MAT3
) {
590 TestAcceptedUniform(GL_FLOAT_MAT3
, Program::kUniformMatrix3f
);
593 TEST_P(GLES2DecoderTest2
, AcceptsUniform_GL_FLOAT_MAT4
) {
594 TestAcceptedUniform(GL_FLOAT_MAT4
, Program::kUniformMatrix4f
);