摘要 |
Image data having a bit depth of m bits, where m is not a power of two, may be divided into two parts for storage. The first part is the n most significant bits, where n is a power of two. The second part is the k least significant bits, where k=m-n and k<n. For example, 10-bit data may be separated into 8-bit and 2-bit parts. The 8-bit data for a given image is placed in the bitstream as a contiguous block with the end of the data aligned with a memory boundary, such as a page boundary. The 2-bit data is collected into bytes that are placed in the bitstream as a contiguous block. The block of 2-bit data is placed in the bitstream preceding and contiguous with the block of 8-bit data. Padding may be provided to align the beginning of the image data with a memory boundary. The image data for multiple images may be placed in the bitstream contiguously for storage. 10-bit data for an alpha channel, if any, also may be split into 8-bit and 2-bit parts. The 8-bit alpha data for a given image is placed in the bitstream as a contiguous block with the beginning of the data aligned with a memory boundary, such as a page boundary. The 2-bit alpha data is collected into bytes that are placed in the bitstream as a contiguous block. The block of 2-bit alpha data is placed in the bistream subsequent to and contiguous with the block of 8-bit alpha data. Padding may be provided to align the end of the alpha data with a page boundary. The alpha data for multiple images may be placed in the bitstream contiguously for storage.
|