Retro video games delivered to your door every month!
Click above to get retro games delivered to your door ever month!
X-Hacker.org- MOD File Format - <b>image descriptor</b> http://www.X-Hacker.org [<<Previous Entry] [^^Up^^] [Next Entry>>] [Menu] [About The Guide]
 Image Descriptor

 The Image Descriptor defines the actual placement  and  extents  of the
 following  image within the space defined in the Screen Descriptor. Also
 defined are flags to indicate the presence of a local colour  lookup map,
 and to define the pixel display sequence.  Each Image Descriptor is
 introduced by an image separator  character.   The  role  of  the  Image
 Separator  is simply to provide a synchronization character to introduce
 an Image Descriptor.  This is desirable if a GIF file happens to contain
 more  than  one  image.   This  character  is defined as 0x2C hex or ','
 (comma).  When this character is encountered between images,  the  Image
 Descriptor will follow immediately.

 Any characters encountered between the end of a previous image  and the
 image separator character are to be ignored.  This allows future GIF
 enhancements to be present in newer image formats and yet ignored safely
 by older software decoders.


              bits
         7 6 5 4 3 2 1 0  Byte #
        +---------------+
        |0 0 1 0 1 1 0 0|  1    ',' - Image separator character
        |---------------|
        |               |  2    Start of image in pixels from the
        |   Image Left  |       left side of the screen (LSB first)
        |               |  3
        |---------------|
        |               |  4
        |   Image Top   |       Start of image in pixels from the
        |               |  5    top of the screen (LSB first)
        |---------------|
        |               |  6
        |  Image Width  |       Width of the image in pixels (LSB first)
        |               |  7
        |---------------|
        |               |  8
        |  Image Height |       Height of the image in pixels (LSB first)
        |               |  9
        |---------------|       M=0 - Use global colour map, ignore 'pixel'
        |M|I|0|0|0|pixel| 10    M=1 - Local colour map follows, use 'pixel'
        +---------------+       I=0 - Image formatted in Sequential order
                                I=1 - Image formatted in Interlaced order
                                pixel+1 - # bits per pixel for this image

 The specifications for the image position and size must be confined to
 the  dimensions defined by the Screen Descriptor.  On the other hand it is
 not necessary that the image fill the entire screen defined.

See Also: Multiple Image Processing

Online resources provided by: http://www.X-Hacker.org --- NG 2 HTML conversion by Dave Pearson