pic format

pic format

pic files contain images in an uncompressed format. both the original animator
and animator pro from autodesk produce pic files. the file formats are
different; animator pro produces a hierarchial block oriented file, while the
original animator file is a simpler fixed format. see pic(pro) for further
information on the animator pro pic format.

the original animator uses this format to store a single-frame picture image.
this format description applies to both pic and original animator cel files. the
file begins with a 32 byte header, as follows:

offset count type description
0000h 1 word id=9119h
0002h 1 word width of image; pic files have always a width
of 320, cel images may have any value.
0004h 1 word height of image, 200 for a pic, any value for
a cel file.
0006h 1 word x offset of image, always 0 for a pic image,
may be nonzero in a cel image.
0008h 1 word y offset of image. zero for a pic file.
000ah 1 byte bits per pixel (8)
000bh 1 byte compresion flag, always zero
000ch 1 dword size of the image data in bytes
0010h 16 byte reserved(0)

immediately following the header is the color map. it contains all 256 palette
entries in rgb order. each of the r, g, and b components is a single byte in the
range of 0-63. following the color palette is the image data, one byte per
pixel, from left to right, top to bottom.

pic(pro) format

this format description applies to both pic and msk files created with the
autodesk animator pro package. the file begins with a 64-byte header defined
as follows:

offset length name description
0000h 1 dword the size of the whole file including the size
of this header.
0004h 1 word id=9500h
0006h 1 word width of the image
0008h 1 word height of the image
000ah 1 word x offset of image
000ch 1 word y offset of image
000eh 1 dword user id, set to zero
0012h 1 byte bits per pixel (8 for pic, 1 for msk)
0013h 45 byte reserved (0)

following the file header are the data blocks for the image. each data block
within a pic or msk file is formatted as follows:

offset count type description
0000h 1 dword the size of the block, including this header.
0004h 1 word data type id :
0 - color palette info
1 - byte-per-pixel image data
2 - bit-per-pixel mask data
0006h ? byte data

the type values in the block headers indicate what type of graphics data the
block contains.

in a pic_cmap block, the first 2-byte word is a version code;
currently this is set to zero. following the version word are all 256 palette
entries in rgb order. each of the r, g, and b components is a single byte in the
range of 0-255. this type of block appears in pic files; there will generally be
no color map block in a msk file.

in a pic_bytepixels block, the image data appears immediately following the
6-byte block header. the data is stored as one byte per pixel, in left-to-right,
topd to-bottom sequence.

in a pic_bitpixels block, the bitmap data appears immediately following the
6-byte block header. the data is stored as bits packed into bytes such that the
leftmost bits appear in the high-order positions of each byte. the bits are
stored in left-to-right, top-to bottom sequence. when the width of the bitmap is
not a multiple of 8, there will be unused bits in the low order positions of the
last byte on each line. the number of bytes per line is ((width+7)/8). this type
of block appears in msk files.

返回




月光软件源码下载编程文档电脑教程网站优化网址导航网络文学游戏天地生活休闲写作范文安妮宝贝站内搜索
电脑技术编程开发网络专区谈天说地情感世界游戏元素分类游戏热门游戏体育运动手机专区业余爱好影视沙龙
音乐天地数码广场教育园地科学大观古今纵横谈股论金人文艺术医学保健动漫图酷二手专区地方风情各行各业

月光软件站·版权所有