PlusLib  2.9.0
Software library for tracked ultrasound image acquisition, calibration, and processing.
Macros | Typedefs | Functions
v2u_compression.h File Reference
#include "v2u_defs.h"
Include dependency graph for v2u_compression.h:

Go to the source code of this file.

Macros

#define ENOSR   106
 
#define EOK   0
 
#define EPROTO   105
 
#define V2U_COMPRESSION_LIB_VERSION   0x00000100
 
#define V2UDEC_API
 

Typedefs

typedef struct v2udec_ctx * V2U_DECOMPRESSION_LIB_CONTEXT
 

Functions

V2UDEC_API int v2udec_decompress_frame (V2U_DECOMPRESSION_LIB_CONTEXT uctx, const unsigned char *framebuf, int framebuflen, unsigned char *bufout, int bufoutlen)
 
V2UDEC_API int v2udec_decompress_frame2 (V2U_DECOMPRESSION_LIB_CONTEXT uctx, const unsigned char *framebuf, int framebuflen, unsigned char *bufout, int bufoutlen, const unsigned char *prev_frame, int prev_frame_len, int just_key_data)
 
V2UDEC_API void v2udec_deinit_context (V2U_DECOMPRESSION_LIB_CONTEXT uctx)
 
V2UDEC_API V2U_UINT32 v2udec_get_cpalette (V2U_DECOMPRESSION_LIB_CONTEXT uctx, const unsigned char *framebuf, int framebuflen)
 
V2UDEC_API int v2udec_get_decompressed_framelen (V2U_DECOMPRESSION_LIB_CONTEXT uctx, const unsigned char *framebuf, int framebuflen)
 
V2UDEC_API V2U_UINT32 v2udec_get_framelen (V2U_DECOMPRESSION_LIB_CONTEXT uctx, const unsigned char *framebuf, int framebuflen)
 
V2UDEC_API void v2udec_get_frameres (V2U_DECOMPRESSION_LIB_CONTEXT uctx, const unsigned char *framebuf, int framebuflen, V2URect *rect)
 
V2UDEC_API V2U_UINT32 v2udec_get_headerlen (V2U_DECOMPRESSION_LIB_CONTEXT uctx, const unsigned char *framebuf, int framebuflen)
 
V2UDEC_API V2U_UINT32 v2udec_get_minheaderlen (V2U_DECOMPRESSION_LIB_CONTEXT uctx)
 
V2UDEC_API V2U_UINT32 v2udec_get_palette (V2U_DECOMPRESSION_LIB_CONTEXT uctx, const unsigned char *framebuf, int framebuflen)
 
V2UDEC_API V2U_TIME v2udec_get_timestamp (V2U_DECOMPRESSION_LIB_CONTEXT uctx, const unsigned char *framebuf, int framebuflen)
 
V2UDEC_API void v2udec_get_videomode (V2U_DECOMPRESSION_LIB_CONTEXT uctx, const unsigned char *framebuf, int framebuflen, V2U_VideoMode *vmode)
 
V2UDEC_API V2U_DECOMPRESSION_LIB_CONTEXT v2udec_init_context (void)
 
V2UDEC_API int v2udec_is_keyframe (V2U_DECOMPRESSION_LIB_CONTEXT uctx, const unsigned char *framebuf, int framebuflen)
 
V2UDEC_API int v2udec_is_ordered (V2U_DECOMPRESSION_LIB_CONTEXT uctx, const unsigned char *framebuf, int framebuflen)
 
V2UDEC_API V2U_BOOL v2udec_set_palette (V2U_DECOMPRESSION_LIB_CONTEXT uctx, const unsigned char *framebuf, int framebuflen, V2U_UINT32 palette)
 

Macro Definition Documentation

◆ ENOSR

#define ENOSR   106

Definition at line 40 of file v2u_compression.h.

◆ EOK

#define EOK   0

Definition at line 44 of file v2u_compression.h.

◆ EPROTO

#define EPROTO   105

Error codes used as a part of compression SDK

Definition at line 36 of file v2u_compression.h.

◆ V2U_COMPRESSION_LIB_VERSION

#define V2U_COMPRESSION_LIB_VERSION   0x00000100

Version of the library and files generatated by the compression algorithm

Definition at line 58 of file v2u_compression.h.

◆ V2UDEC_API

#define V2UDEC_API

Definition at line 28 of file v2u_compression.h.

Typedef Documentation

◆ V2U_DECOMPRESSION_LIB_CONTEXT

typedef struct v2udec_ctx* V2U_DECOMPRESSION_LIB_CONTEXT

Context of the files sequence Compression algorithm internaly keeps key frame. Therefore to decode sequence of frames common context must be created and used during decoding of consiquently captured frames

Definition at line 68 of file v2u_compression.h.

Function Documentation

◆ v2udec_decompress_frame()

V2UDEC_API int v2udec_decompress_frame ( V2U_DECOMPRESSION_LIB_CONTEXT  uctx,
const unsigned char *  framebuf,
int  framebuflen,
unsigned char *  bufout,
int  bufoutlen 
)

Decompression functions

◆ v2udec_decompress_frame2()

V2UDEC_API int v2udec_decompress_frame2 ( V2U_DECOMPRESSION_LIB_CONTEXT  uctx,
const unsigned char *  framebuf,
int  framebuflen,
unsigned char *  bufout,
int  bufoutlen,
const unsigned char *  prev_frame,
int  prev_frame_len,
int  just_key_data 
)

◆ v2udec_deinit_context()

V2UDEC_API void v2udec_deinit_context ( V2U_DECOMPRESSION_LIB_CONTEXT  uctx)

◆ v2udec_get_cpalette()

V2UDEC_API V2U_UINT32 v2udec_get_cpalette ( V2U_DECOMPRESSION_LIB_CONTEXT  uctx,
const unsigned char *  framebuf,
int  framebuflen 
)

◆ v2udec_get_decompressed_framelen()

V2UDEC_API int v2udec_get_decompressed_framelen ( V2U_DECOMPRESSION_LIB_CONTEXT  uctx,
const unsigned char *  framebuf,
int  framebuflen 
)

◆ v2udec_get_framelen()

V2UDEC_API V2U_UINT32 v2udec_get_framelen ( V2U_DECOMPRESSION_LIB_CONTEXT  uctx,
const unsigned char *  framebuf,
int  framebuflen 
)

◆ v2udec_get_frameres()

V2UDEC_API void v2udec_get_frameres ( V2U_DECOMPRESSION_LIB_CONTEXT  uctx,
const unsigned char *  framebuf,
int  framebuflen,
V2URect rect 
)

◆ v2udec_get_headerlen()

V2UDEC_API V2U_UINT32 v2udec_get_headerlen ( V2U_DECOMPRESSION_LIB_CONTEXT  uctx,
const unsigned char *  framebuf,
int  framebuflen 
)

Actual header size. Add this to v2udec_get_framelen() to obtain required buffer size to hold one compressed frame.

Returns
0 on error.

◆ v2udec_get_minheaderlen()

V2UDEC_API V2U_UINT32 v2udec_get_minheaderlen ( V2U_DECOMPRESSION_LIB_CONTEXT  uctx)

Functions to obtain information about the compressed frameMinimum header size. Useful when reading in bytestream. After receiving this number of bytes additional information about the frame can be obtained from v2udec_get_framelen() et al. This value can be different for different versions of V2U libraries.

◆ v2udec_get_palette()

V2UDEC_API V2U_UINT32 v2udec_get_palette ( V2U_DECOMPRESSION_LIB_CONTEXT  uctx,
const unsigned char *  framebuf,
int  framebuflen 
)

◆ v2udec_get_timestamp()

V2UDEC_API V2U_TIME v2udec_get_timestamp ( V2U_DECOMPRESSION_LIB_CONTEXT  uctx,
const unsigned char *  framebuf,
int  framebuflen 
)

Timestamp (in milliseconds) of the frame in the framebuf

◆ v2udec_get_videomode()

V2UDEC_API void v2udec_get_videomode ( V2U_DECOMPRESSION_LIB_CONTEXT  uctx,
const unsigned char *  framebuf,
int  framebuflen,
V2U_VideoMode vmode 
)

◆ v2udec_init_context()

V2UDEC_API V2U_DECOMPRESSION_LIB_CONTEXT v2udec_init_context ( void  )

◆ v2udec_is_keyframe()

V2UDEC_API int v2udec_is_keyframe ( V2U_DECOMPRESSION_LIB_CONTEXT  uctx,
const unsigned char *  framebuf,
int  framebuflen 
)

◆ v2udec_is_ordered()

V2UDEC_API int v2udec_is_ordered ( V2U_DECOMPRESSION_LIB_CONTEXT  uctx,
const unsigned char *  framebuf,
int  framebuflen 
)

◆ v2udec_set_palette()

V2UDEC_API V2U_BOOL v2udec_set_palette ( V2U_DECOMPRESSION_LIB_CONTEXT  uctx,
const unsigned char *  framebuf,
int  framebuflen,
V2U_UINT32  palette 
)