Hi All,
I've got a transparent gif that I want to use as a texture but I can't figure out how to make just the transparent section of the gif invisiable while leaving the rest untouched - any pointers please?
There are two main types of transparency, true transparent images, (with an alpha channel), and another that I don't know the name for. One works of the alpha channel of an image, the other 'guesses' at an alpha value (A=(R+G+B)/3). gifs don't have an alpha channel (as far as i'm aware), it's done with the pallet, you will either need a loader that creates an RGBA texture from the pallet or save your image as another format (png works well). It then depends on what effect the transparency is, is it 0 or 1 (fully transparent or fully opaque) or can it be semi transparent. if it's 0 or 1 then you can use the rendering attributes to do it, if not, check the archives, I posted some code there that works for textures with an alpha channel for fully and semi transparent textures
Also I was wondering how much impact on performance results from turning transparency sorting on? If there are only a small number of transparent objects which remain relativly static is it best to just use ordered groups?
I could never get ordered groups working properly with other transparent object in my scene too. if you only have a small number of objects that remain relatively static then transparency sorting should be fairly non performance impacting, as it's performance is totally dependent on the number of transparent objects.
HTH
Jeremy --
Homepage: http://www.computerbooth.com/ Code page: http://www.newdawnsoftware.com/
=========================================================================== To unsubscribe, send email to [EMAIL PROTECTED] and include in the body of the message "signoff JAVA3D-INTEREST". For general help, send email to [EMAIL PROTECTED] and include in the body of the message "help".