src/untp/pvr.py
def _pvr_head(_data):
    """
        struct CCZHeader {
            unsigned char   sig[4];             // signature. Should be 'CCZ!' 4 bytes
            unsigned short  compression_type;   // should 0
            unsigned short  version;            // should be 2 (although version type==1 is also supported)
            unsigned int    reserved;           // Reserved for users.
            unsigned int    len;                // size of the uncompressed file
        };
    """
    return {
        "sig": _data[:4],
        "compression_type": struct.unpack("H", _data[4:6])[0],
        "version": struct.unpack("H", _data[6:8])[0],
        "reserved": struct.unpack("I", _data[8:12])[0],
        "len": struct.unpack("I", _data[12:16])[0],
    }
def _pvr_head(_data):
    """
        struct CCZHeader {
            unsigned char   sig[4];             // signature. Should be 'CCZ!' 4 bytes
            unsigned short  compression_type;   // should 0
            unsigned short  version;            // should be 2 (although version type==1 is also supported)
            unsigned int    reserved;           // Reserved for users.
            unsigned int    len;                // size of the uncompressed file
        };
    """
    return {
        "sig": _data[:4],
        "compression_type": struct.unpack("H", _data[4:6])[0],
        "version": struct.unpack("H", _data[6:8])[0],
        "reserved": struct.unpack("I", _data[8:12])[0],
        "len": struct.unpack("I", _data[12:16])[0],
    }
struct CCZHeader {
            unsigned char   sig[4];             // signature. Should be 'CCZ!' 4 bytes
            unsigned short  compression_type;   // should 0
            unsigned short  version;            // should be 2 (although version type==1 is also supported)
            unsigned int    reserved;           // Reserved for users.
            unsigned int    len;                // size of the uncompressed file
        };