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

glLightfv fails #28

bookface opened this issue Feb 14, 2018 · 1 comment


None yet
2 participants
Copy link

commented Feb 14, 2018

glLightfv(GL_LIGHT0, GL_DIFFUSE, [1.0, 1.0, 1.0, 1.0])
fails with "can't convert Array into Integer (TypeError)"


This comment has been minimized.

Copy link

commented Feb 14, 2018

You must use

glLightfv(GL_LIGHT0, GL_DIFFUSE, [1.0, 1.0, 1.0, 1.0].pack("f*"))

This gem doesn't provide Ruby style automatisms for parameter handling. Value arrays must be passed as strings therefore.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.