mirror of
https://github.com/zenorogue/hyperrogue.git
synced 2024-12-19 15:20:27 +00:00
ray:: fixed missing mediump
This commit is contained in:
parent
dee64d29d4
commit
10bb713422
@ -341,13 +341,13 @@ void enable_raycaster() {
|
|||||||
"uniform mediump sampler2D tWall;\n"
|
"uniform mediump sampler2D tWall;\n"
|
||||||
"uniform mediump float uInvLengthWall;\n"
|
"uniform mediump float uInvLengthWall;\n"
|
||||||
"mediump vec4 getWall(mediump int x, mediump int coord) {\n"
|
"mediump vec4 getWall(mediump int x, mediump int coord) {\n"
|
||||||
" vec4 result;\n"
|
" mediump vec4 result;\n"
|
||||||
" vec4 v = texture2D(tWall, vec2((float(x)+.5) * uInvLengthWall, (float(coord)+.5) / 4.));\n"
|
" mediump vec4 v = texture2D(tWall, vec2((float(x)+.5) * uInvLengthWall, (float(coord)+.5) / 4.));\n"
|
||||||
" for(int j=0; j<4; j++) result[j] = (v[j] - .5) * 8.;\n"
|
" for(int j=0; j<4; j++) result[j] = (v[j] - .5) * 8.;\n"
|
||||||
" return result;\n"
|
" return result;\n"
|
||||||
" }\n"
|
" }\n"
|
||||||
"mediump int getWallstart(mediump int x) {\n"
|
"mediump int getWallstart(mediump int x) {\n"
|
||||||
" vec4 v = texture2D(tWall, vec2((float(x)+.5) * uInvLengthWall, 0.625));\n"
|
" mediump vec4 v = texture2D(tWall, vec2((float(x)+.5) * uInvLengthWall, 0.625));\n"
|
||||||
" return int(v[0] / uInvLengthWall);\n"
|
" return int(v[0] / uInvLengthWall);\n"
|
||||||
" }\n";
|
" }\n";
|
||||||
}
|
}
|
||||||
@ -361,9 +361,9 @@ void enable_raycaster() {
|
|||||||
"uniform mediump sampler2D tM;\n"
|
"uniform mediump sampler2D tM;\n"
|
||||||
"uniform mediump float uInvLengthM;\n"
|
"uniform mediump float uInvLengthM;\n"
|
||||||
"mediump mat4 getM(mediump int x) {\n"
|
"mediump mat4 getM(mediump int x) {\n"
|
||||||
" mat4 result;\n"
|
" mediump mat4 result;\n"
|
||||||
" for(int i=0; i<4; i++) {\n"
|
" for(int i=0; i<4; i++) {\n"
|
||||||
" vec4 v = texture2D(tM, vec2((float(x)+.5) * uInvLengthM, (float(i)+.5) / 4.));\n"
|
" mediump vec4 v = texture2D(tM, vec2((float(x)+.5) * uInvLengthM, (float(i)+.5) / 4.));\n"
|
||||||
" for(int j=0; j<4; j++) result[j][i] = (v[j] - .5) * 8.;\n"
|
" for(int j=0; j<4; j++) result[j][i] = (v[j] - .5) * 8.;\n"
|
||||||
" }\n"
|
" }\n"
|
||||||
" return result;\n"
|
" return result;\n"
|
||||||
|
Loading…
Reference in New Issue
Block a user