makamys / Neodymium

Reimplements chunk rendering using modern OpenGL features to improve performance (1.7.10)
Other
116 stars 10 forks source link

Shader line normalization is broken #28

Closed quentin452 closed 10 months ago

quentin452 commented 10 months ago

When i build the mod on my end i got this issue,it seem thats a bug caused by versions?

Mod file named has neodymium-1.7.10-UNKNOWN.jar

screenshot of my issue :

image

instruction :

1 : clone repository 2 : build the mod 3 : launch the game 4 : see invisible chunks

errors i can see in logs :


[12:06:49] [Client thread/INFO] [STDOUT]: [makamys.neodymium.renderer.NeoRenderer:reloadShader:445]: Error compiling vertex shader: 0(1) : error C0205: invalid profile "corenlayout"
0(1) : error C0206: invalid token "<invalid atom 1533466528>" in version line
[12:06:49] [Client thread/INFO] [STDOUT]: [makamys.neodymium.renderer.NeoRenderer:reloadShader:456]: Error compiling fragment shader: 0(1) : error C0205: invalid profile "corenout"
0(1) : error C0206: invalid token "vec4" in version line
[12:06:49] [Client thread/INFO] [STDOUT]: [makamys.neodymium.renderer.NeoRenderer:reloadShader:466]: Error linking shader: 0(1) : error C0205: invalid profile "corenout"
0(1) : error C0206: invalid token "vec4" in version line
[12:06:49] [Client thread/INFO] [STDOUT]: [makamys.neodymium.renderer.NeoRenderer:reloadShader:445]: Error compiling vertex shader: 0(1) : error C0205: invalid profile "corenlayout"
0(1) : error C0206: invalid token "<invalid atom 1563979504>" in version line
[12:06:49] [Client thread/INFO] [STDOUT]: [makamys.neodymium.renderer.NeoRenderer:reloadShader:456]: Error compiling fragment shader: 0(1) : error C0205: invalid profile "corenout"
0(1) : error C0206: invalid token "vec4" in version line
[12:06:49] [Client thread/INFO] [STDOUT]: [makamys.neodymium.renderer.NeoRenderer:reloadShader:466]: Error linking shader: 0(1) : error C0205: invalid profile "corenout"
0(1) : error C0206: invalid token "vec4" in version line
[12:06:49] [Client thread/INFO] [STDOUT]: [makamys.neodymium.renderer.NeoRenderer:reloadShader:445]: Error compiling vertex shader: 0(1) : error C0205: invalid profile "corenlayout"
0(1) : error C0206: invalid token "<invalid atom 1563973264>" in version line
[12:06:49] [Client thread/INFO] [STDOUT]: [makamys.neodymium.renderer.NeoRenderer:reloadShader:456]: Error compiling fragment shader: 0(1) : error C0205: invalid profile "corenout"
0(1) : error C0206: invalid token "vec4" in version line
[12:06:49] [Client thread/INFO] [STDOUT]: [makamys.neodymium.renderer.NeoRenderer:reloadShader:466]: Error linking shader: 0(1) : error C0205: invalid profile "corenout"
0(1) : error C0206: invalid token "vec4" in version line
[12:06:49] [Client thread/INFO] [STDOUT]: [makamys.neodymium.renderer.NeoRenderer:reloadShader:445]: Error compiling vertex shader: 0(1) : error C0205: invalid profile "corenlayout"
0(1) : error C0206: invalid token "<invalid atom 1544701984>" in version line
[12:06:49] [Client thread/INFO] [STDOUT]: [makamys.neodymium.renderer.NeoRenderer:reloadShader:456]: Error compiling fragment shader: 0(1) : error C0205: invalid profile "corenout"
0(1) : error C0206: invalid token "vec4" in version line
[12:06:49] [Client thread/INFO] [STDOUT]: [makamys.neodymium.renderer.NeoRenderer:reloadShader:466]: Error linking shader: 0(1) : error C0205: invalid profile "corenout"
0(1) : error C0206: invalid token "vec4" in version line
[12:07:38] [Client thread/INFO]: Stopping!
quentin452 commented 10 months ago

Fixed by copying the shaders folder(from an already builded version) and overwriting it in the source

you should accept my PR to fix it because i think the good shaders folder is good only on your client not on the hosted files(github) (corrupted)

pr : https://github.com/makamys/Neodymium/pull/30

makamys commented 10 months ago

This is caused by checking out the repo incorrectly. The shader file is supposed to have lines ending in \n ("LF"), but Git for Windows checks it out as \r\n ("CRLF") by default. I recommend changing your core.autocrlf setting to avoid issues like this in the future. These are the settings I use (not sure if the second one is necessary):

With that said though, Neodymium is supposed to be able to handle CRLF, it just wasn't working because of a typo.