Lines Matching refs:frag
271 std::ostringstream frag; in createVaryingArrayCase() local
272 frag << "#version 300 es\n"; in createVaryingArrayCase()
273 frag << "precision mediump int;\n"; in createVaryingArrayCase()
274 frag << "layout(location = 0) out mediump vec4 o_color;\n"; in createVaryingArrayCase()
276 frag << "uniform mediump int ui_zero, ui_one, ui_two, ui_three;\n"; in createVaryingArrayCase()
278 frag << "uniform int ui_four;\n"; in createVaryingArrayCase()
279 frag << "in ${PRECISION} ${VAR_TYPE} var[${ARRAY_LEN}];\n"; in createVaryingArrayCase()
280 frag << "\n"; in createVaryingArrayCase()
281 frag << "void main()\n"; in createVaryingArrayCase()
282 frag << "{\n"; in createVaryingArrayCase()
283 frag << " ${PRECISION} ${VAR_TYPE} res = ${VAR_TYPE}(0.0);\n"; in createVaryingArrayCase()
286 frag << " res += var[0];\n"; in createVaryingArrayCase()
287 frag << " res += var[1];\n"; in createVaryingArrayCase()
288 frag << " res += var[2];\n"; in createVaryingArrayCase()
289 frag << " res += var[3];\n"; in createVaryingArrayCase()
293 frag << " res += var[ui_zero];\n"; in createVaryingArrayCase()
294 frag << " res += var[ui_one];\n"; in createVaryingArrayCase()
295 frag << " res += var[ui_two];\n"; in createVaryingArrayCase()
296 frag << " res += var[ui_three];\n"; in createVaryingArrayCase()
300 frag << " for (int i = 0; i < 4; i++)\n"; in createVaryingArrayCase()
301 frag << " res += var[i];\n"; in createVaryingArrayCase()
306 frag << " for (int i = 0; i < ui_four; i++)\n"; in createVaryingArrayCase()
307 frag << " res += var[i];\n"; in createVaryingArrayCase()
309 frag << " o_color = vec4(res${PADDING});\n"; in createVaryingArrayCase()
310 frag << "}\n"; in createVaryingArrayCase()
328 StringTemplate fragTemplate(frag.str().c_str()); in createVaryingArrayCase()
339 std::ostringstream frag; in createUniformArrayCase() local
340 std::ostringstream& op = isVertexCase ? vtx : frag; in createUniformArrayCase()
343 frag << "#version 300 es\n"; in createUniformArrayCase()
347 frag << "layout(location = 0) out mediump vec4 o_color;\n"; in createUniformArrayCase()
352 frag << "in mediump vec4 v_color;\n"; in createUniformArrayCase()
357 frag << "in mediump vec4 v_coords;\n"; in createUniformArrayCase()
372 frag << "\n"; in createUniformArrayCase()
373 frag << "void main()\n"; in createUniformArrayCase()
374 frag << "{\n"; in createUniformArrayCase()
407 frag << " o_color = v_color;\n"; in createUniformArrayCase()
412 frag << " o_color = vec4(res${PADDING});\n"; in createUniformArrayCase()
416 frag << "}\n"; in createUniformArrayCase()
434 StringTemplate fragTemplate(frag.str().c_str()); in createUniformArrayCase()
445 std::ostringstream frag; in createTmpArrayCase() local
446 std::ostringstream& op = isVertexCase ? vtx : frag; in createTmpArrayCase()
449 frag << "#version 300 es\n"; in createTmpArrayCase()
453 frag << "layout(location = 0) out mediump vec4 o_color;\n"; in createTmpArrayCase()
458 frag << "in mediump vec4 v_color;\n"; in createTmpArrayCase()
463 frag << "in mediump vec4 v_coords;\n"; in createTmpArrayCase()
477 frag << "\n"; in createTmpArrayCase()
478 frag << "void main()\n"; in createTmpArrayCase()
479 frag << "{\n"; in createTmpArrayCase()
551 frag << " o_color = v_color;\n"; in createTmpArrayCase()
556 frag << " o_color = vec4(res${PADDING});\n"; in createTmpArrayCase()
560 frag << "}\n"; in createTmpArrayCase()
578 StringTemplate fragTemplate(frag.str().c_str()); in createTmpArrayCase()
605 std::ostringstream frag; in createVectorSubscriptCase() local
606 std::ostringstream& op = isVertexCase ? vtx : frag; in createVectorSubscriptCase()
612 frag << "#version 300 es\n"; in createVectorSubscriptCase()
616 frag << "layout(location = 0) out mediump vec4 o_color;\n"; in createVectorSubscriptCase()
621 frag << "in mediump vec3 v_color;\n"; in createVectorSubscriptCase()
626 frag << "in mediump vec4 v_coords;\n"; in createVectorSubscriptCase()
646 frag << "\n"; in createVectorSubscriptCase()
647 frag << "void main()\n"; in createVectorSubscriptCase()
648 frag << "{\n"; in createVectorSubscriptCase()
738 frag << " o_color = vec4(v_color.rgb, 1.0);\n"; in createVectorSubscriptCase()
743 frag << " o_color = vec4(vec3(res), 1.0);\n"; in createVectorSubscriptCase()
747 frag << "}\n"; in createVectorSubscriptCase()
760 StringTemplate fragTemplate(frag.str().c_str()); in createVectorSubscriptCase()
805 std::ostringstream frag; in createMatrixSubscriptCase() local
806 std::ostringstream& op = isVertexCase ? vtx : frag; in createMatrixSubscriptCase()
814 frag << "#version 300 es\n"; in createMatrixSubscriptCase()
818 frag << "layout(location = 0) out mediump vec4 o_color;\n"; in createMatrixSubscriptCase()
823 frag << "in mediump vec4 v_color;\n"; in createMatrixSubscriptCase()
828 frag << "in mediump vec4 v_coords;\n"; in createMatrixSubscriptCase()
848 frag << "\n"; in createMatrixSubscriptCase()
849 frag << "void main()\n"; in createMatrixSubscriptCase()
850 frag << "{\n"; in createMatrixSubscriptCase()
922 frag << " o_color = v_color;\n"; in createMatrixSubscriptCase()
927 frag << " o_color = vec4(res${PADDING});\n"; in createMatrixSubscriptCase()
931 frag << "}\n"; in createMatrixSubscriptCase()
947 StringTemplate fragTemplate(frag.str().c_str()); in createMatrixSubscriptCase()