xrif
A fast lossless compression system

Functions to perform the "bytepack" reordering method

Collaboration diagram for Bytepack reordering:

Functions

xrif_error_t xrif_reorder_bytepack (xrif_t handle)
 Dispatch bytepack reodering based on type. More...
 
xrif_error_t xrif_reorder_bytepack_sint16 (xrif_t handle)
 Perform bytepack reodering for signed 16 bit ints. More...
 
xrif_error_t xrif_unreorder_bytepack (xrif_t handle)
 Dispatch bytepack unreodering based on type. More...
 
xrif_error_t xrif_unreorder_bytepack_sint16 (xrif_t handle)
 Perform bytepack unreodering for signed 16 bit ints. More...
 

Function Documentation

◆ xrif_reorder_bytepack()

xrif_error_t xrif_reorder_bytepack ( xrif_t  handle)

Dispatch bytepack reodering based on type.

Calls the type appropriate xrif_reorder_bytepack_X function.

Returns
XRIF_NOERROR on success
XRIF_ERROR_NULLPTR if handle is null.
XRIF_ERROR_INSUFFICIENT_SIZE if either raw_buffer or reorderd_buffer aren't big enough
Parameters
[in,out]handle[in/out] the xrif handle

Definition at line 1305 of file xrif.c.

References xrif_handle::type_code, XRIF_ERROR_NOTIMPL, XRIF_ERROR_NULLPTR, XRIF_ERROR_PRINT, xrif_reorder_bytepack_sint16(), XRIF_TYPECODE_INT16, XRIF_TYPECODE_INT32, XRIF_TYPECODE_INT64, XRIF_TYPECODE_UINT16, XRIF_TYPECODE_UINT32, and XRIF_TYPECODE_UINT64.

◆ xrif_reorder_bytepack_sint16()

xrif_error_t xrif_reorder_bytepack_sint16 ( xrif_t  handle)

Perform bytepack reodering for signed 16 bit ints.

Returns
XRIF_NOERROR on success
XRIF_ERROR_NULLPTR if handle is null.
XRIF_ERROR_INSUFFICIENT_SIZE if either raw_buffer or reorderd_buffer aren't big enough
Todo:
is this actually necessary, and can this can be just the extra pixels?
Parameters
[in,out]handle[in/out] the xrif handle

Definition at line 1336 of file xrif.c.

References xrif_handle::difference_method, XRIF_ERROR_NULLPTR, and XRIF_ERROR_PRINT.

Referenced by xrif_reorder_bytepack().

◆ xrif_unreorder_bytepack()

xrif_error_t xrif_unreorder_bytepack ( xrif_t  handle)

Dispatch bytepack unreodering based on type.

Calls the type appropriate xrif_unreorder_bytepack_X function.

Returns
XRIF_NOERROR on success
XRIF_ERROR_NULLPTR if handle is null.
XRIF_ERROR_INSUFFICIENT_SIZE if either raw_buffer or reorderd_buffer aren't big enough
Parameters
[in,out]handle[in/out] the xrif handle

Definition at line 1651 of file xrif.c.

References xrif_handle::type_code, XRIF_ERROR_NOTIMPL, XRIF_ERROR_NULLPTR, XRIF_ERROR_PRINT, XRIF_TYPECODE_INT16, XRIF_TYPECODE_INT32, XRIF_TYPECODE_INT64, XRIF_TYPECODE_UINT16, XRIF_TYPECODE_UINT32, XRIF_TYPECODE_UINT64, and xrif_unreorder_bytepack_sint16().

◆ xrif_unreorder_bytepack_sint16()

xrif_error_t xrif_unreorder_bytepack_sint16 ( xrif_t  handle)

Perform bytepack unreodering for signed 16 bit ints.

Todo:
this does not actually perform any size checks, but should.
Returns
XRIF_NOERROR on success
XRIF_ERROR_NULLPTR if handle is null.
XRIF_ERROR_INSUFFICIENT_SIZE if either raw_buffer or reorderd_buffer aren't big enough
Parameters
[in,out]handle[in/out] the xrif handle

Definition at line 1682 of file xrif.c.

References xrif_handle::difference_method, XRIF_ERROR_NULLPTR, and XRIF_ERROR_PRINT.

Referenced by xrif_unreorder_bytepack().