Wang Rui
2008-05-16 16:46:39 UTC
Hi all,
I have just done some changes on the classic osgdb_gif plugin. I wish our
developers may use the newly written GIF reading plugin to attach animate
GIF files as textures now! In my opinion, a GIF is much smaller than AVI and
MOVs, and much more efficient sometimes.
Changes includes:
1. A new GifImageStream class (inherit from osg::ImageStream) have
already been added to implement different operations of a GIF movie, such
like playing, pausing, rewinding, setting time and so on.
2. Some small changes to decode_row() and gif_read_stream(), which make the
transparency of GIF images correctly.
3. Just a few changes to the ReaderWriterGIF::readGIFStream() function,
which ensure that animate GIFs are loaded by GifImageStream (and the
function returns GifImageStream objects) and static GIFs unchanged (still
use the old method and returns osg::Image objects!).
All changes are commented with "2008.5.17". The plugin has been tested on
Windows. Thank you for criticizing and advices.
God bless people in Sichuan, China, who are suffering the earthquake...
Wang Rui
I have just done some changes on the classic osgdb_gif plugin. I wish our
developers may use the newly written GIF reading plugin to attach animate
GIF files as textures now! In my opinion, a GIF is much smaller than AVI and
MOVs, and much more efficient sometimes.
Changes includes:
1. A new GifImageStream class (inherit from osg::ImageStream) have
already been added to implement different operations of a GIF movie, such
like playing, pausing, rewinding, setting time and so on.
2. Some small changes to decode_row() and gif_read_stream(), which make the
transparency of GIF images correctly.
3. Just a few changes to the ReaderWriterGIF::readGIFStream() function,
which ensure that animate GIFs are loaded by GifImageStream (and the
function returns GifImageStream objects) and static GIFs unchanged (still
use the old method and returns osg::Image objects!).
All changes are commented with "2008.5.17". The plugin has been tested on
Windows. Thank you for criticizing and advices.
God bless people in Sichuan, China, who are suffering the earthquake...
Wang Rui