Lines Matching refs:write
24 void GLSLCodeGenerator::write(const char* s) { in write() function in SkSL::GLSLCodeGenerator
38 this->write(s); in writeLine()
43 void GLSLCodeGenerator::write(const String& s) { in write() function in SkSL::GLSLCodeGenerator
44 this->write(s.c_str()); in write()
47 void GLSLCodeGenerator::write(StringFragment s) { in write() function in SkSL::GLSLCodeGenerator
56 fOut->write(s.fChars, s.fLength); in write()
74 fExtensions.write(name.c_str(), name.length()); in writeExtension()
170 this->write(type.fName); in writeType()
175 this->write("struct "); in writeType()
176 this->write(type.fName); in writeType()
184 this->write(" "); in writeType()
185 this->write(f.fName); in writeType()
189 this->write("}"); in writeType()
191 this->write(this->getTypeName(type)); in writeType()
261 this->write("((" + tmpVar1 + " = "); in writeMinAbsHack()
263 this->write(") < (" + tmpVar2 + " = "); in writeMinAbsHack()
265 this->write(") ? " + tmpVar1 + " : " + tmpVar2 + ")"); in writeMinAbsHack()
269 this->write("(1.0 / sqrt("); in writeInverseSqrtHack()
271 this->write("))"); in writeInverseSqrtHack()
334 this->write(name + "("); in writeDeterminantHack()
336 this->write(")"); in writeDeterminantHack()
421 this->write(name + "("); in writeInverseHack()
423 this->write(")"); in writeInverseHack()
448 this->write(name + "("); in writeTransposeHack()
450 this->write(")"); in writeTransposeHack()
497 this->write(name); in writeFunctionCall()
515 this->write("atan("); in writeFunctionCall()
517 this->write(", -1.0 * "); in writeFunctionCall()
519 this->write(")"); in writeFunctionCall()
542 this->write("(("); in writeFunctionCall()
544 this->write(") * ("); in writeFunctionCall()
546 this->write(") + ("); in writeFunctionCall()
548 this->write("))"); in writeFunctionCall()
555 this->write("(0.5 - sign("); in writeFunctionCall()
557 this->write(") * (0.5 - fract(abs("); in writeFunctionCall()
559 this->write("))))"); in writeFunctionCall()
601 this->write("exp2("); in writeFunctionCall()
603 this->write(" * log2("); in writeFunctionCall()
605 this->write("))"); in writeFunctionCall()
609 this->write("clamp("); in writeFunctionCall()
611 this->write(", 0.0, 1.0)"); in writeFunctionCall()
669 this->write("texture"); in writeFunctionCall()
671 this->write(dim); in writeFunctionCall()
674 this->write("Proj"); in writeFunctionCall()
689 this->write(c.fFunction.fName); in writeFunctionCall()
691 this->write("("); in writeFunctionCall()
694 this->write(separator); in writeFunctionCall()
699 this->write(", -0.5"); in writeFunctionCall()
701 this->write(")"); in writeFunctionCall()
714 this->write("("); in writeFunctionCall()
717 this->write(separator); in writeFunctionCall()
721 this->write(")"); in writeFunctionCall()
738 this->write("sk_FragCoord_Resolved"); in writeFunctionCall()
746 this->write("gl_FragCoord"); in writeFunctionCall()
756 this->write("gl_FragCoord"); in writeFunctionCall()
764 this->write("sk_FragCoord"); in writeFunctionCall()
772 this->write("sk_FragColor"); in writeFunctionCall()
774 this->write("gl_FragColor"); in writeFunctionCall()
781 this->write("u_skRTWidth"); in writeFunctionCall()
784 this->write("u_skRTHeight"); in writeFunctionCall()
787 this->write(fProgram.fSettings.fFlipY ? "(!gl_FrontFacing)" : "gl_FrontFacing"); in writeFunctionCall()
790 this->write("gl_VertexID"); in writeFunctionCall()
793 this->write("gl_InstanceID"); in writeFunctionCall()
796 this->write("gl_ClipDistance"); in writeFunctionCall()
799 this->write("gl_in"); in writeFunctionCall()
802 this->write("gl_InvocationID"); in writeFunctionCall()
805 this->write(fProgram.fSettings.fCaps->fbFetchColorName()); in writeFunctionCall()
808 this->write(ref.fVariable.fName); in writeFunctionCall()
814 this->write("["); in writeFunctionCall()
816 this->write("]"); in writeFunctionCall()
826 this->write("."); in writeFunctionCall()
830 this->write("gl_ClipDistance"); in writeFunctionCall()
835 this->write("gl_Position"); in writeFunctionCall()
837 this->write("gl_PointSize"); in writeFunctionCall()
839 this->write(f.fBase->fType.fields()[f.fFieldIndex].fName); in writeFunctionCall()
846 this->write("."); in writeFunctionCall()
848 this->write(&("x\0y\0z\0w\0"[c * 2])); in writeFunctionCall()
902 this->write("("); in writeFunctionCall()
911 this->write("sk_FragCoord_Workaround = ("); in writeFunctionCall()
914 this->write(" "); in writeFunctionCall()
915 this->write(Compiler::OperatorName(b.fOperator)); in writeFunctionCall()
916 this->write(" "); in writeFunctionCall()
919 this->write(")"); in writeFunctionCall()
922 this->write(")"); in writeFunctionCall()
929 this->write("("); in writeFunctionCall()
936 this->write(" ? "); in writeFunctionCall()
943 this->write(" : "); in writeFunctionCall()
951 this->write(")"); in writeFunctionCall()
958 this->write("("); in writeFunctionCall()
961 this->write(" ? "); in writeFunctionCall()
963 this->write(" : "); in writeFunctionCall()
966 this->write(")"); in writeFunctionCall()
973 this->write("("); in writeFunctionCall()
975 this->write(Compiler::OperatorName(p.fOperator)); in writeFunctionCall()
978 this->write(")"); in writeFunctionCall()
985 this->write("("); in writeFunctionCall()
988 this->write(Compiler::OperatorName(p.fOperator)); in writeFunctionCall()
990 this->write(")"); in writeFunctionCall()
995 this->write(b.fValue ? "true" : "false"); in writeFunctionCall()
1000 this->write(to_string(i.fValue & 0xffffffff) + "u"); in writeFunctionCall()
1002 this->write(to_string(i.fValue & 0xffff) + "u"); in writeFunctionCall()
1004 this->write(to_string(i.fValue & 0xff) + "u"); in writeFunctionCall()
1006 this->write(to_string((int32_t) i.fValue)); in writeFunctionCall()
1011 this->write(to_string(f.fValue)); in writeFunctionCall()
1022 this->write(" " + f.fDeclaration.fName + "("); in writeFunctionCall()
1025 this->write(separator); in writeFunctionCall()
1036 this->write(" " + param->fName); in writeFunctionCall()
1039 this->write("[]"); in writeFunctionCall()
1041 this->write("[" + to_string(s) + "]"); in writeFunctionCall()
1059 this->write(fFunctionHeader); in writeFunctionCall()
1060 this->write(buffer.str()); in writeFunctionCall()
1066 this->write("flat "); in writeFunctionCall()
1069 this->write("noperspective "); in writeFunctionCall()
1073 this->write(layout + " "); in writeFunctionCall()
1076 this->write("readonly "); in writeFunctionCall()
1079 this->write("writeonly "); in writeFunctionCall()
1082 this->write("coherent "); in writeFunctionCall()
1085 this->write("volatile "); in writeFunctionCall()
1088 this->write("restrict "); in writeFunctionCall()
1092 this->write("inout "); in writeFunctionCall()
1096 this->write(fProgramKind == Program::kVertex_Kind ? "attribute " in writeFunctionCall()
1099 this->write("in "); in writeFunctionCall()
1104 this->write("varying "); in writeFunctionCall()
1106 this->write("out "); in writeFunctionCall()
1110 this->write("uniform "); in writeFunctionCall()
1113 this->write("const "); in writeFunctionCall()
1116 this->write("__pixel_localEXT "); in writeFunctionCall()
1119 this->write("__pixel_local_inEXT "); in writeFunctionCall()
1122 this->write("__pixel_local_outEXT "); in writeFunctionCall()
1126 this->write("lowp "); in writeFunctionCall()
1129 this->write("mediump "); in writeFunctionCall()
1132 this->write("highp "); in writeFunctionCall()
1155 this->write("}"); in writeFunctionCall()
1157 this->write(" "); in writeFunctionCall()
1158 this->write(intf.fInstanceName); in writeFunctionCall()
1160 this->write("["); in writeFunctionCall()
1164 this->write("]"); in writeFunctionCall()
1205 this->write(this->getTypePrecision(type)); in writeFunctionCall()
1216 this->write(", "); in writeFunctionCall()
1221 this->write(" "); in writeFunctionCall()
1224 this->write(var.fVar->fName); in writeFunctionCall()
1226 this->write("["); in writeFunctionCall()
1230 this->write("]"); in writeFunctionCall()
1233 this->write(" = "); in writeFunctionCall()
1254 this->write(";"); in writeFunctionCall()
1265 this->write(";"); in writeFunctionCall()
1289 this->write("break;"); in writeFunctionCall()
1292 this->write("continue;"); in writeFunctionCall()
1295 this->write("discard;"); in writeFunctionCall()
1298 this->write(";"); in writeFunctionCall()
1319 this->write("}"); in writeFunctionCall()
1323 this->write("if ("); in writeFunctionCall()
1325 this->write(") "); in writeFunctionCall()
1328 this->write(" else "); in writeFunctionCall()
1334 this->write("for ("); in writeFunctionCall()
1338 this->write("; "); in writeFunctionCall()
1352 this->write("; "); in writeFunctionCall()
1356 this->write(") "); in writeFunctionCall()
1361 this->write("while ("); in writeFunctionCall()
1363 this->write(") "); in writeFunctionCall()
1369 this->write("do "); in writeFunctionCall()
1371 this->write(" while ("); in writeFunctionCall()
1373 this->write(");"); in writeFunctionCall()
1394 this->write("bool "); in writeFunctionCall()
1395 this->write(tmpVar); in writeFunctionCall()
1399 this->write("if ("); in writeFunctionCall()
1400 this->write(tmpVar); in writeFunctionCall()
1403 this->write("if (!"); in writeFunctionCall()
1412 this->write(tmpVar); in writeFunctionCall()
1417 this->write("}"); in writeFunctionCall()
1421 this->write("switch ("); in writeFunctionCall()
1427 this->write("case "); in writeFunctionCall()
1441 this->write("}"); in writeFunctionCall()
1445 this->write("return"); in writeFunctionCall()
1447 this->write(" "); in writeFunctionCall()
1450 this->write(";"); in writeFunctionCall()
1454 this->write(fProgram.fSettings.fCaps->versionDeclString()); in writeFunctionCall()
1475 this->write("inout "); in writeFunctionCall()
1477 this->write("out "); in writeFunctionCall()
1480 this->write("mediump "); in writeFunctionCall()
1554 this->write("vec4 sk_FragCoord_Workaround;\n"); in writeFunctionCall()
1560 this->write("vec4 sk_FragCoord_Workaround;\n"); in writeFunctionCall()