Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

glUniformMatrix4fv throws error because of pyrr's Matrix444 objects #5

Closed
ghost opened this issue Nov 4, 2020 · 1 comment
Closed

Comments

@ghost
Copy link

ghost commented Nov 4, 2020

The glUniformMatrix4fv throws error because of pyrr's Matrix444 objects.

tsugite/setup/Show.py", line 95, in init_shader
glUniformMatrix4fv(3, 1, GL_FALSE, rot_x * rot_y)
File "src/latebind.pyx", line 32, in OpenGL_accelerate.latebind.LateBind.call
File "src/wrapper.pyx", line 299, in OpenGL_accelerate.wrapper.Wrapper.call
File "src/wrapper.pyx", line 161, in OpenGL_accelerate.wrapper.PyArgCalculator.c_call
File "src/wrapper.pyx", line 128, in OpenGL_accelerate.wrapper.PyArgCalculatorElement.c_call
File "src/wrapper.pyx", line 114, in OpenGL_accelerate.wrapper.PyArgCalculatorElement.c_call
File "src/wrapper.pyx", line 212, in OpenGL_accelerate.wrapper.CallFuncPyConverter.c_call
File "src/arraydatatype.pyx", line 174, in OpenGL_accelerate.arraydatatype.ArrayDatatype.asArray
File "src/arraydatatype.pyx", line 57, in OpenGL_accelerate.arraydatatype.HandlerRegistry.c_lookup
TypeError: ("No array-type handler for type <class 'pyrr.objects.matrix44.Matrix44'> (value: Matrix44([[ 0.92106099, 0.27935162, 0.27131037, ) registered", None)

@ghost ghost closed this as completed Nov 5, 2020
@ghost
Copy link
Author

ghost commented Nov 5, 2020

It was because the glUniformMatrix4fv needs a numpy array instead of pyrr Matrix444 type, so I had to convert it. Now it works well :)

This issue was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

0 participants