Alex Holkner wrote:
> Gerdus van Zyl wrote:
>   
>> Thanks that helped alot.
>>
>> For future reference here is my solution:
>>
>> negative pitch is countered by flipping the texture coordinates as
>> suggested:
>> #default: texture.tex_coords = ((0, 0, 0), (1, 0, 0), (1, 1, 0), (0,
>> 1, 0))
>> texture.tex_coords = ((0, 1, 0), (1, 1, 0), (1, 0, 0), (0, 0, 0))
>>
>> The image format was solved by converting it beforehand using numpy:
>> #BGRA TO RGB
>>   
>>     
> Something that occurred to me after posting this morning (and talking to 
> Richard).. you can use the GL color matrix (present with the ARB_imaging 
> extension, which is pretty universal) to do the conversion.  I've added 
> it to my todo list to improve ImageData's performance in the future.
>   
This is in r877 now: you should be able to use the original image format 
without converting via numpy, without any performance loss.  My test 
cases are in tests/image/MATRIX_RGB and tests/image/MATRIX_RGBA.
(This doesn't address the image flipping though, you'll still need to 
flip texture coordinates).

Alex.

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"pyglet-users" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/pyglet-users?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to