Revert "Bug 1977019 - re-enable hw video decoding testing. r=media-playback-reviewers,jolin" for causing win mda failures on test_hw_video_decoding.html
This reverts commit 158474bdc0cf585b701bc47921f0a7d84f7bb84d.
<!--Copyright (c) 2019 The Khronos Group Inc.Use of this source code is governed by an MIT-style license that can befound in the LICENSE.txt file.--><!DOCTYPE html><html><head><metacharset="utf-8"><title>GLSL dynamic vector and matrix indexing test</title><linkrel="stylesheet"href="../../resources/js-test-style.css"/><scriptsrc="../../js/js-test-pre.js"></script><scriptsrc="../../js/webgl-test-utils.js"></script><scriptsrc="../../js/glsl-conformance-test.js"></script></head><body><divid="description"></div><divid="console"></div><scriptid="fshaderIndexMatrixTwice"type="x-shader/x-fragment">#version300esprecisionmediumpfloat;outvec4my_FragColor;uniformintu_zero;voidmain(){mat2m=mat2(0.0,0.0,0.0,1.0);floatf=m[u_zero+1][u_zero+1];my_FragColor=vec4(1.0-f,f,0.0,1.0);}</script><scriptid="fshaderIndexWithValueFromIndexingExpression"type="x-shader/x-fragment">#version300esprecisionmediumpfloat;outvec4my_FragColor;uniformintu_zero;voidmain(){ivec2i=ivec2(0,2);vec4v=vec4(0.0,0.2,1.0,0.4);floatf=v[i[u_zero+1]];my_FragColor=vec4(1.0-f,f,0.0,1.0);}</script><scriptid="fshaderIndexLValue"type="x-shader/x-fragment">#version300esprecisionmediumpfloat;outvec4my_FragColor;uniformintu_zero;voidmain(){vec4v=vec4(1.0,2.0,3.0,4.0);v[u_zero+1]=5.0;vec4expected=vec4(1.0,5.0,3.0,4.0);floatf=1.0-distance(v,expected);my_FragColor=vec4(1.0-f,f,0.0,1.0);}</script><scriptid="fshaderIndexLValueWithValueFromIndexingExpression"type="x-shader/x-fragment">#version300esprecisionmediumpfloat;outvec4my_FragColor;uniformintu_zero;voidmain(){ivec2i=ivec2(0,2);vec4v=vec4(1.0,2.0,3.0,4.0);v[i[u_zero+1]]=5.0;vec4expected=vec4(1.0,2.0,5.0,4.0);floatf=1.0-distance(v,expected);my_FragColor=vec4(1.0-f,f,0.0,1.0);}</script><scriptid="fshaderIndexBuiltInFunctionCallOutParameter"type="x-shader/x-fragment">#version300esprecisionmediumpfloat;outvec4my_FragColor;uniformintu_zero;voidmain(){vec4v=vec4(1.0,2.0,3.0,4.0);modf(5.5,v[u_zero+3]);vec4expected=vec4(1.0,2.0,3.0,5.0);floatf=1.0-distance(v,expected);my_FragColor=vec4(1.0-f,f,0.0,1.0);}</script><scriptid="fshaderIndexUserDefinedFunctionCallOutParameter"type="x-shader/x-fragment">#version300esprecisionmediumpfloat;outvec4my_FragColor;uniformintu_zero;voidfoo(outfloatf){modf(5.5,f);}voidmain(){vec4v=vec4(1.0,2.0,3.0,4.0);foo(v[u_zero+3]);vec4expected=vec4(1.0,2.0,3.0,5.0);floatf=1.0-distance(v,expected);my_FragColor=vec4(1.0-f,f,0.0,1.0);}</script><scriptid="fshaderIndexUserDefinedFunctionCallInOutParameter"type="x-shader/x-fragment">#version300esprecisionmediumpfloat;outvec4my_FragColor;uniformintu_zero;voidfoo(inoutfloatf){floatg=f+2.5;modf(g,f);}voidmain(){vec4v=vec4(1.0,2.0,3.0,4.0);foo(v[u_zero+2]);vec4expected=vec4(1.0,2.0,5.0,4.0);floatf=1.0-distance(v,expected);my_FragColor=vec4(1.0-f,f,0.0,1.0);}</script><scriptid="fshaderIndexWithSideEffects"type="x-shader/x-fragment">#version300esprecisionmediumpfloat;outvec4my_FragColor;uniformintu_zero;intsideEffectCounter=0;intfuncWithSideEffects(){sideEffectCounter++;return2;}voidmain(){vec4v=vec4(1.0,2.0,3.0,4.0);v[funcWithSideEffects()]=5.0;vec4expected=vec4(1.0,2.0,5.0,4.0);floatf=1.0-distance(v,expected);if(sideEffectCounter!=1){f=0.0;}my_FragColor=vec4(1.0-f,f,0.0,1.0);}</script><scriptid="fshaderIndexInOutWithSideEffects"type="x-shader/x-fragment">#version300esprecisionmediumpfloat;outvec4my_FragColor;uniformintu_zero;intsideEffectCounter=0;intfuncWithSideEffects(){sideEffectCounter++;return2;}voidmain(){vec4v=vec4(1.0,2.0,3.0,4.0);v[funcWithSideEffects()]++;vec4expected=vec4(1.0,2.0,4.0,4.0);floatf=1.0-distance(v,expected);if(sideEffectCounter!=1){f=0.0;}my_FragColor=vec4(1.0-f,f,0.0,1.0);}</script><scriptid="fshaderIndexUserDefinedFunctionCallInOutParameterWithIndexWithSideEffects"type="x-shader/x-fragment">#version300esprecisionmediumpfloat;outvec4my_FragColor;uniformintu_zero;intsideEffectCounter=0;voidfoo(inoutfloatf){floatg=f+2.5;modf(g,f);}intfuncWithSideEffects(){sideEffectCounter++;return2;}voidmain(){vec4v=vec4(1.0,2.0,3.0,4.0);foo(v[funcWithSideEffects()]);vec4expected=vec4(1.0,2.0,5.0,4.0);floatf=1.0-distance(v,expected);if(sideEffectCounter!=1){f=0.0;}my_FragColor=vec4(1.0-f,f,0.0,1.0);}</script><scriptid="fshaderIndexLValueWithUint"type="x-shader/x-fragment">#version300esprecisionmediumpfloat;outvec4my_FragColor;uniformuintu_zero;voidmain(){vec4v=vec4(1.0,2.0,3.0,4.0);v[u_zero]=5.0;vec4expected=vec4(5.0,2.0,3.0,4.0);floatf=1.0-distance(v,expected);my_FragColor=vec4(1.0-f,f,0.0,1.0);}</script><scriptid="fshaderIndexUniform"type="x-shader/x-fragment">#version300esprecisionmediumpfloat;outvec4my_FragColor;uniformvec4u_zeroVec;uniformuintu_zero;voidmain(){// This test is just to catch a crash bug that occurred in ANGLE's workaround.// Rendering result is not meaningful.floatf=u_zeroVec[u_zero];my_FragColor=vec4(f,1.0,0.0,1.0);}</script><scriptid="fshaderSequenceDynamicIndexingVectorLvalue"type="x-shader/x-fragment">#version300esprecisionmediumpfloat;outvec4my_FragColor;uniformintu_zero;intsideEffectCounter=0;floatfunc(){++sideEffectCounter;return-1.0;}voidmain(){vec4v=vec4(0.0,2.0,4.0,6.0);floatf=(func(),(++v[u_zero+sideEffectCounter]));my_FragColor=(abs(f-3.0)<0.01&&abs(v[1]-3.0)<0.01&&sideEffectCounter==1)?vec4(0,1,0,1):vec4(1,0,0,1);}</script><scriptid="fshaderIndexMatrixTwiceInLValue"type="x-shader/x-fragment">#version300esprecisionmediumpfloat;outvec4my_FragColor;uniformintu_zero;voidmain(){mat2m=mat2(0.0,0.0,0.0,0.0);m[u_zero+1][u_zero+1]=float(u_zero+1);floatf=m[1][1];my_FragColor=vec4(1.0-f,f,0.0,1.0);}</script><scripttype="application/javascript">"use strict";description("Dynamic indexing of vectors and matrices should work.");debug("Dynamic indexing of vectors and matrices requires complex workarounds on HLSL backends. Try to test possible bugs those workarounds might have.");GLSLConformanceTester.runRenderTests([{fShaderId:'fshaderIndexMatrixTwice',fShaderSuccess:true,linkSuccess:true,passMsg:'Index matrix and then index the resulting vector in the same expression'},{fShaderId:'fshaderIndexWithValueFromIndexingExpression',fShaderSuccess:true,linkSuccess:true,passMsg:'Index a vector with an index that is the result of indexing'},{fShaderId:'fshaderIndexLValue',fShaderSuccess:true,linkSuccess:true,passMsg:'Index on the left-hand side of assignment'},{fShaderId:'fshaderIndexLValueWithValueFromIndexingExpression',fShaderSuccess:true,linkSuccess:true,passMsg:'Index on the left-hand side of assignment with an index that is the result of indexing'},{fShaderId:'fshaderIndexBuiltInFunctionCallOutParameter',fShaderSuccess:true,linkSuccess:true,passMsg:'Index the out parameter passed to built-in modf'},{fShaderId:'fshaderIndexUserDefinedFunctionCallOutParameter',fShaderSuccess:true,linkSuccess:true,passMsg:'Index an out parameter passed to an user-defined function'},{fShaderId:'fshaderIndexUserDefinedFunctionCallInOutParameter',fShaderSuccess:true,linkSuccess:true,passMsg:'Index an inout parameter passed to an user-defined function'},{fShaderId:'fshaderIndexWithSideEffects',fShaderSuccess:true,linkSuccess:true,passMsg:'Use expression with side effects as an index of an l-value'},{fShaderId:'fshaderIndexInOutWithSideEffects',fShaderSuccess:true,linkSuccess:true,passMsg:'Use expression with side effects as an index of an l-value that is both read and written'},{fShaderId:'fshaderIndexUserDefinedFunctionCallInOutParameterWithIndexWithSideEffects',fShaderSuccess:true,linkSuccess:true,passMsg:'Index an inout parameter passed to an user-defined function with an index with side effects'},{fShaderId:'fshaderIndexLValueWithUint',fShaderSuccess:true,linkSuccess:true,passMsg:'Index on the left-hand side of assignment with an uint'},{fShaderId:'fshaderIndexUniform',fShaderSuccess:true,linkSuccess:true,passMsg:'Index a uniform with a uniform'},{fShaderId:'fshaderSequenceDynamicIndexingVectorLvalue',fShaderSuccess:true,linkSuccess:true,passMsg:'Sequence operator with dynamic indexing of a vector as an l-value inside'},{fShaderId:'fshaderIndexMatrixTwiceInLValue',fShaderSuccess:true,linkSuccess:true,passMsg:'Index matrix and then index the resulting vector in the same expression inside an l-value'}],2);</script></body></html>