Re: Re: Textures in Haskell OpenGL
Sven Panne <[email protected]>
| Newsgroups | gmane.comp.lang.haskell.hopengl |
|---|---|
| Message-ID | <[email protected]> |
Hugh Rayner wrote:
> [...] Are there any examples available that include loading
> textures from files? That's really what I'm after.
Not exactly, there is only one helper module (GLUT/examples/RedBook/ReadImage.hs)
for reading the simple raw image format used in the Red Book for the examples
related to the imaging subset. A "real" texture loader should probably use libpng
(http://www.libpng.org/pub/png/libpng.html), interfacing to this native library
is probably easier than doing all the decoding stuff by hand. Alas, AFAIK there
is no Haskell binding for this library yet.
Cheers,
S.