source: thirdparty/blosc/README_HEADER.rst @ 981e22c

Revision 981e22c, 1.7 KB checked in by Hal Finkel <hfinkel@…>, 8 years ago (diff)

Upgrade to latest blosc library

blosc git: e394f327ccc78319d90a06af0b88bce07034b8dd

  • Property mode set to 100644
RevLine 
[00587dc]1Blosc Header Format
2===================
3
4Blosc (as of Version 1.0.0) has the following 16 byte header that stores
5information about the compressed buffer::
6
7    |-0-|-1-|-2-|-3-|-4-|-5-|-6-|-7-|-8-|-9-|-A-|-B-|-C-|-D-|-E-|-F-|
8      ^   ^   ^   ^ |     nbytes    |   blocksize   |    ctbytes    |
9      |   |   |   |
10      |   |   |   +--typesize
11      |   |   +------flags
12      |   +----------versionlz
13      +--------------version
14
15Datatypes of the Header Entries
16-------------------------------
17
18All entries are little endian.
19
20:version:
21    (``uint8``) Blosc format version.
22:versionlz:
[981e22c]23    (``uint8``) Version of the internal compressor used.
24:flags and compressor enumeration:
25    (``bitfield``) The flags of the buffer
[00587dc]26
27    :bit 0 (``0x01``):
[981e22c]28        Whether the byte-shuffle filter has been applied or not.
[00587dc]29    :bit 1 (``0x02``):
30        Whether the internal buffer is a pure memcpy or not.
[981e22c]31    :bit 2 (``0x04``):
32        Whether the bit-shuffle filter has been applied or not.
33    :bit 3 (``0x08``):
34        Reserved
35    :bit 4 (``0x16``):
36        Reserved
37    :bit 5 (``0x32``):
38        Part of the enumeration for compressors.
39    :bit 6 (``0x64``):
40        Part of the enumeration for compressors.
41    :bit 7 (``0x64``):
42        Part of the enumeration for compressors.
43
44    The last three bits form an enumeration that allows to use alternative
45    compressors.
46
47    :``0``:
48        ``blosclz``
49    :``1``:
50        ``lz4`` or ``lz4hc``
51    :``2``:
52        ``snappy``
53    :``3``:
54        ``zlib``
55    :``4``:
56        ``zstd``
[00587dc]57
58:typesize:
59    (``uint8``) Number of bytes for the atomic type.
60:nbytes:
61    (``uint32``) Uncompressed size of the buffer.
62:blocksize:
63    (``uint32``) Size of internal blocks.
64:ctbytes:
65    (``uint32``) Compressed size of the buffer.
Note: See TracBrowser for help on using the repository browser.