0033661: Data Exchange, Step Import - Tessellated GDTs are not imported
[occt.git] / src / Shaders / Shaders_PBREnvBaking_vs.pxx
1 // This file has been automatically generated from resource file src/Shaders/PBREnvBaking.vs
2
3 static const char Shaders_PBREnvBaking_vs[] =
4   "THE_SHADER_OUT vec3 ViewDirection; //!< direction of fetching from environment cubemap\n"
5   "\n"
6   "uniform int uCurrentSide; //!< current side of cubemap\n"
7   "uniform int uYCoeff;      //!< coefficient of Y controlling horizontal flip of cubemap\n"
8   "uniform int uZCoeff;      //!< coefficient of Z controlling vertical flip of cubemap\n"
9   "\n"
10   "void main()\n"
11   "{\n"
12   "  vec3 aDir;\n"
13   "  vec2 aCoord;\n"
14   "  if (uCurrentSide == 0)\n"
15   "  {\n"
16   "    aCoord = mat2( 0,-1,-1, 0) * occVertex.xy;\n"
17   "    aDir.x = 1.0;\n"
18   "    aDir.y = aCoord.x;\n"
19   "    aDir.z = aCoord.y;\n"
20   "  }\n"
21   "  else if (uCurrentSide == 1)\n"
22   "  {\n"
23   "    aCoord = mat2( 0, 1,-1, 0) * occVertex.xy;\n"
24   "    aDir.x = -1.0;\n"
25   "    aDir.y = aCoord.x;\n"
26   "    aDir.z = aCoord.y;\n"
27   "  }\n"
28   "  else if (uCurrentSide == 2)\n"
29   "  {\n"
30   "    aCoord = mat2( 0, 1, 1, 0) * occVertex.xy;\n"
31   "    aDir.x = aCoord.y;\n"
32   "    aDir.y = 1.0;\n"
33   "    aDir.z = aCoord.x;\n"
34   "  }\n"
35   "  else if (uCurrentSide == 3)\n"
36   "  {\n"
37   "    aCoord = mat2( 0, 1,-1, 0) * occVertex.xy;\n"
38   "    aDir.x = aCoord.y;\n"
39   "    aDir.y = -1.0;\n"
40   "    aDir.z = aCoord.x;\n"
41   "  }\n"
42   "  else if (uCurrentSide == 4)\n"
43   "  {\n"
44   "    aCoord = mat2( 1, 0, 0,-1) * occVertex.xy;\n"
45   "    aDir.x = aCoord.x;\n"
46   "    aDir.y = aCoord.y;\n"
47   "    aDir.z = 1.0;\n"
48   "  }\n"
49   "  else //if (uCurrentSide == 5)\n"
50   "  {\n"
51   "    aCoord = mat2(-1, 0, 0,-1) * occVertex.xy;\n"
52   "    aDir.x = aCoord.x;\n"
53   "    aDir.y = aCoord.y;\n"
54   "    aDir.z = -1.0;\n"
55   "  }\n"
56   "  ViewDirection = cubemapVectorTransform (aDir, uYCoeff, uZCoeff);\n"
57   "  gl_Position = vec4 (occVertex.xy, 0.0, 1.0);\n"
58   "}\n";