diff --git a/graphic/webGL/src/main/js/default/test/WebGL.test14.js b/graphic/webGL/src/main/js/default/test/WebGL.test14.js index 5571eb9002f468648a711f55e429e7c41d9286de..3c9a25d1a5f7049d5ebd4fcace85dcd49cb0ea1a 100644 --- a/graphic/webGL/src/main/js/default/test/WebGL.test14.js +++ b/graphic/webGL/src/main/js/default/test/WebGL.test14.js @@ -912,6 +912,22 @@ describe('webgl1Test_webgl15', function() { expect(texParameterValue).assertEqual(gl.COMPARE_REF_TO_TEXTURE); done(); }); + + /** + * @tc.number GRAPHIC_FUNCTION_JS_WEBGL_TESTWEBGL_1335 + * @tc.name testRangeMin + * @tc.desc Test RangeMin. + */ + it('testRangeMin', 0, async function(done) { + console.info('jsWebGL testRangeMin test start'); + gl.getShaderPrecisionFormat(gl.FRAGMENT_SHADER, gl.LOW_INT).rangeMin; + gl.getShaderPrecisionFormat(gl.VERTEX_SHADER, gl.MEDIUM_FLOAT).rangeMax; + gl.getShaderPrecisionFormat(gl.VERTEX_SHADER, gl.MEDIUM_FLOAT).precision; + const errorCode = gl.getError(); + console.info("WebGLShaderPrecisionFormat getError: " + errorCode); + expect(errorCode).assertEqual(gl.NO_ERROR); + done(); + }); /** * @tc.number GRAPHIC_FUNCTION_JS_WEBGL_TESTWEBGL_1337 @@ -950,6 +966,39 @@ describe('webgl1Test_webgl15', function() { var x9 = gl2.OBJECT_TYPE; expect(x9).assertEqual(37138); + var x10 = gl2.FRAMEBUFFER_DEFAULT; + expect(x10).assertEqual(33304); + + var x11 = gl2.RG8UI; + expect(x11).assertEqual(33336); + + var x12 = gl2.UNIFORM_IS_ROW_MAJOR; + expect(x12).assertEqual(35390); + + var x13 = gl2.ANY_SAMPLES_PASSED_CONSERVATIVE; + expect(x13).assertEqual(36202); + + var y1 = gl.LUMINANCE_ALPHA; + expect(y1).assertEqual(6410); + + var y2 = gl.SHADER_TYPE; + expect(y2).assertEqual(35663); + + var y3 = gl.LINK_STATUS; + expect(y3).assertEqual(35714); + + var y4 = gl.VALIDATE_STATUS; + expect(y4).assertEqual(35715); + + var y5 = gl.VERTEX_ATTRIB_ARRAY_POINTER; + expect(y5).assertEqual(34373); + + var y6 = gl.FRAMEBUFFER_ATTACHMENT_OBJECT_NAME; + expect(y6).assertEqual(36049); + + var y7 = gl.CONTEXT_LOST_WEBGL; + expect(y7).assertEqual(37442); + done(); }); }) diff --git a/graphic/webGL/src/main/js/default/test/WebGL.test15.js b/graphic/webGL/src/main/js/default/test/WebGL.test15.js index 502f1e1774dcb043f56c58deb3c150eeea85d45e..f1e47306ea2c5179384abab80b0b90863dde764e 100644 --- a/graphic/webGL/src/main/js/default/test/WebGL.test15.js +++ b/graphic/webGL/src/main/js/default/test/WebGL.test15.js @@ -514,4 +514,19 @@ describe('webgl1Test_webgl16', function() { expect(stencilValue).assertEqual(false); done(); }) + + /** + * @tc.number GRAPHIC_FUNCTION_JS_WEBGL_TESTWEBGL_1348 + * @tc.name webgl_test_endTransformFeedback + * @tc.desc Test endTransformFeedback. + */ + it('webgl_test_endTransformFeedback', 0, async function(done) { + let transformFeedback = gl2.createTransformFeedback(); + gl2.endTransformFeedback(); + let errorCode = gl.getError(); + console.info("webgltest endTransformFeedback getError: " + errorCode); + expect(errorCode).assertLarger(gl.NO_ERROR); + //deleteContext(); + done(); + }); })