leon-o / iris-flw-compat

Enable Flywheel's optimizations when using shaderpacks.
MIT License
46 stars 23 forks source link

Hard crash due to too many parameters going from vertex shader to fragment shader. #148

Open hyblocker opened 1 month ago

hyblocker commented 1 month ago

This mod causes a hard crash by patching shaders to pass too many parameters from the vertex shader to the fragment shader.

[20:14:17] [Render thread/WARN]: Error encountered when linking program containing VS shadow_flw_flywheel_model_15 and FS shadow_flw_flywheel_model_15. Log output:
[20:14:17] [Render thread/WARN]: Vertex info
-----------
0(559) : error C5041: cannot locate suitable resource to bind variable "at_midBlock". Possibly large array.

[20:14:17] [Thread-87/INFO]: OpenGL debug message: id=1282, source=API, type=ERROR, severity=HIGH, message='GL_INVALID_OPERATION error generated. <program> object is not successfully linked, or is not a program object.'
[20:14:17] [Thread-87/INFO]: OpenGL debug message: id=1282, source=API, type=ERROR, severity=HIGH, message='GL_INVALID_OPERATION error generated. <program> object is not successfully linked, or is not a program object.'
[20:14:17] [Thread-87/INFO]: OpenGL debug message: id=1282, source=API, type=ERROR, severity=HIGH, message='GL_INVALID_OPERATION error generated. <program> object is not successfully linked, or is not a program object.'
[20:14:17] [Thread-87/INFO]: OpenGL debug message: id=1282, source=API, type=ERROR, severity=HIGH, message='GL_INVALID_OPERATION error generated. <program> object is not successfully linked, or is not a program object.'
[20:14:17] [Thread-87/INFO]: OpenGL debug message: id=1282, source=API, type=ERROR, severity=HIGH, message='GL_INVALID_OPERATION error generated. <program> object is not successfully linked, or is not a program object.'
[20:14:17] [Thread-87/INFO]: OpenGL debug message: id=1282, source=API, type=ERROR, severity=HIGH, message='GL_INVALID_OPERATION error generated. <program> object is not successfully linked, or is not a program object.'
[20:14:17] [Thread-87/INFO]: OpenGL debug message: id=1282, source=API, type=ERROR, severity=HIGH, message='GL_INVALID_OPERATION error generated. <program> object is not successfully linked, or is not a program object.'
[20:14:17] [Thread-87/INFO]: OpenGL debug message: id=1282, source=API, type=ERROR, severity=HIGH, message='GL_INVALID_OPERATION error generated. <program> object is not successfully linked, or is not a program object.'
...
[20:18:08] [Thread-87/INFO]: OpenGL debug message: id=1282, source=API, type=ERROR, severity=HIGH, message='GL_INVALID_OPERATION error generated. <program> object is not successfully linked, or is not a program object.'
[20:18:08] [Thread-87/INFO]: OpenGL debug message: id=1282, source=API, type=ERROR, severity=HIGH, message='GL_INVALID_OPERATION error generated. <program> has not been linked, or is not a program object.'
[20:18:08] [Thread-87/INFO]: OpenGL debug message: id=1282, source=API, type=ERROR, severity=HIGH, message='GL_INVALID_OPERATION error generated. <program> object is not successfully linked, or is not a program object.'
[20:18:08] [Thread-87/INFO]: OpenGL debug message: id=1282, source=API, type=ERROR, severity=HIGH, message='GL_INVALID_OPERATION error generated. <program> has not been linked, or is not a program object.'
[20:18:08] [Thread-87/INFO]: OpenGL debug message: id=1282, source=API, type=ERROR, severity=HIGH, message='GL_INVALID_OPERATION error generated. <program> object is not successfully linked, or is not a program object.'
[20:18:08] [Thread-87/INFO]: OpenGL debug message: id=1282, source=API, type=ERROR, severity=HIGH, message='GL_INVALID_OPERATION error generated. <program> has not been linked, or is not a program object.'
[20:18:08] [Thread-87/INFO]: OpenGL debug message: id=1282, source=API, type=ERROR, severity=HIGH, message='GL_INVALID_OPERATION error generated. <program> object is not successfully linked, or is not a program object.'
Stopped watching the game log because the log length surpassed 100000 lines.

From my limited look into this you need to query the graphics driver at runtime to see what the maximum number of vertex components is. In C you would use the following:

glGetIntegerv(GL_MAX_VERTEX_OUTPUT_COMPONENTS, &mvoc);

I am using ComplementaryReimagined_r5.2.2 + EuphoriaPatches_1.3.2 as my shader pack too.

leon-o commented 4 weeks ago

Still crashing with the latest version?