PDA

View Full Version : Hybrid Implementation ... What's wrong?



bentlegen
10-04-2004, 04:43 PM
I'm assuming I've done something silly, but regardless, I'll state my problem.

I've successfully compiled and run the sample program given with Hybrid's Gerbera implementation. Just for fun, I added the following lines, but unfortunately they had no effect.




Unfortunately the cube doesn't change color, even if I set glColor4x(0x1000, 0x1000, 0x1000, 0) and glDisable(GL_LIGHTING)

Have I gone crazy, or is this a problem with the Hybrid implementation?

sampo
10-04-2004, 09:30 PM
Hi bentlegen,

According to the spec the number of components per color has to be 4. Also there is no function called glColorArrays() in OpenGL ES. The function you are looking for is glColorPointer(). Thus with the following lines you'll get the results you want:




Cheers,
Sampo

Edit: The code inside the code section seems to behave strangely. I tried to edit it to be more readable...

[ October 05, 2004: Message edited by: Sampo Lappalainen / Hybrid Graphics ]

bentlegen
10-05-2004, 02:20 AM
Thanks for the hand. Now don't I look silly ...

- Ben