iz it possible and what parameters should I pass to gluBuild2dMipmaps? Thanks.
gluBuild2dMipmaps doesnt accept the 16 bit pixel format tokens. read the spec on it:
you could use one of the compressed formats (some of which are 16 bit)
in conjunction with auto-mipmap generation
otherwise, just convert your image data to one of the accepted pixel formats (pretty darn easy, but a slight pain in the butt):
10x for answering me. Could you give an example of using compressed textures. I searched the net for tutorials or demos but I couldn’t find. If you have any links or sample sources I would beg you for posting them.
Thanks Nico I checked the link and it really works but is it linux portable? GCC gives DDSURFACEDESC2 undeclared. I know that the problem comes from the fact that I don’t have direct X under linux. Any suggestions or .DDS format is windows specific?
Read this documentation
They use a utility from the directx sdk to compress cube maps with mipmaps into a single dds file. You can most likely write your own function in linux for that.
unfortunately, this isnt a trivial task, nor is it a joyous one.
heres another demo that loads a dds (skip down a bit in the list):
i havnt tried it, but it looks ok. the only caveat is the need to include ddraw.h for the DDSURFACEDESC2 definition. you can try to create this structure yourself from the docs (MSDN):
or, just download the monster sdk (~230 megs):
this took me 14 hours with my “tin cans connected by a string” connection.
rats, heres the link to the structures (sigh):
well, on the other hand, there’s the link to the structures:
(head is extra boney today)
Unfortunately questioning continues… All went very well till the moment I found that DRI drivers for Ati Radeon Mobility 7500 from dri.sf.net does not support the S3TC extension, nor any other TC extension. In fact how many TC extensions are there? I know only for the S3 and FX extensions.
Why RLE compressed TGAs aren’t supported for real time decoding? I might be wrong but from what I have read and what I have seen, makes me think that it is true. I have never read somebody saying it is not possible but all TGA loaders I’ve found in the net first decompress and then pass image data to the GL functions.As a final approach I am thinking about adding the S3TC extension to the ICD but for doing it right I need some open source video driver which supports it(I know that’s not an easy task but go prove I’m not wrong to the project manager…). Thanks once again.