Wasabi ExpressPlay SDK for Embedded Systems  1.23.0
Data Structures | Macros | Typedefs | Functions
Ts2BitUtils.h File Reference
#include "Atomix.h"

Go to the source code of this file.

Data Structures

struct  TS2_BitStream
 
struct  TS2_BitWriter
 

Macros

#define TS2_WORD_BITS   32
 
#define TS2_WORD_BYTES   4
 
#define TS2_BitWriter_IsByteAligned(writer)   ((writer)->bit_count%8 == 0)
 
#define TS2_BitWriter_ByteCount(writer)   ((ATX_UInt32)((writer)->bit_count / 8))
 

Typedefs

typedef ATX_UInt32 TS2_BitsWord
 

Functions

ATX_Result TS2_BitStream_SetData (TS2_BitStream *bits, const ATX_Byte *data, ATX_Size data_size)
 
ATX_Result TS2_BitStream_Reset (TS2_BitStream *bits)
 
ATX_Size TS2_BitStream_GetBitsLeft (TS2_BitStream *bits)
 
ATX_Result TS2_BitStream_Rewind (TS2_BitStream *bits, ATX_UInt32 n)
 
ATX_UInt32 TS2_BitStream_ReadBits (TS2_BitStream *bits, ATX_UInt32 n)
 
ATX_UInt32 TS2_BitStream_ReadBit (TS2_BitStream *bits)
 
ATX_UInt64 TS2_BitStream_Read64 (TS2_BitStream *bits, ATX_UInt32 n)
 
ATX_Result TS2_BitStream_ReadTimecode (TS2_BitStream *bits, ATX_UInt64 *timecode)
 
ATX_UInt32 TS2_BitStream_PeekBits (const TS2_BitStream *bits, ATX_UInt32 n)
 
ATX_UInt32 TS2_BitStream_PeekBit (const TS2_BitStream *bits)
 
void TS2_BitStream_SkipBits (TS2_BitStream *bits, ATX_UInt32 n)
 
void TS2_BitStream_SkipBit (TS2_BitStream *bits)
 
ATX_Result TS2_BitWriter_SetData (TS2_BitWriter *writer, ATX_Byte *data, ATX_Size data_size)
 doesn't take ownership of data, just write into the buffer More...
 
ATX_Result TS2_BitWriter_Write (TS2_BitWriter *writer, ATX_UInt32 bits, ATX_UInt32 bit_count)
 
ATX_Result TS2_BitWriter_WriteAlignedBytes (TS2_BitWriter *writer, ATX_Byte *data, ATX_Size data_size)
 

Macro Definition Documentation

◆ TS2_BitWriter_ByteCount

#define TS2_BitWriter_ByteCount (   writer)    ((ATX_UInt32)((writer)->bit_count / 8))

◆ TS2_BitWriter_IsByteAligned

#define TS2_BitWriter_IsByteAligned (   writer)    ((writer)->bit_count%8 == 0)

◆ TS2_WORD_BITS

#define TS2_WORD_BITS   32

◆ TS2_WORD_BYTES

#define TS2_WORD_BYTES   4

Typedef Documentation

◆ TS2_BitsWord

typedef ATX_UInt32 TS2_BitsWord

Function Documentation

◆ TS2_BitStream_GetBitsLeft()

ATX_Size TS2_BitStream_GetBitsLeft ( TS2_BitStream bits)

◆ TS2_BitStream_PeekBit()

ATX_UInt32 TS2_BitStream_PeekBit ( const TS2_BitStream bits)

◆ TS2_BitStream_PeekBits()

ATX_UInt32 TS2_BitStream_PeekBits ( const TS2_BitStream bits,
ATX_UInt32  n 
)

◆ TS2_BitStream_Read64()

ATX_UInt64 TS2_BitStream_Read64 ( TS2_BitStream bits,
ATX_UInt32  n 
)

◆ TS2_BitStream_ReadBit()

ATX_UInt32 TS2_BitStream_ReadBit ( TS2_BitStream bits)

◆ TS2_BitStream_ReadBits()

ATX_UInt32 TS2_BitStream_ReadBits ( TS2_BitStream bits,
ATX_UInt32  n 
)

◆ TS2_BitStream_ReadTimecode()

ATX_Result TS2_BitStream_ReadTimecode ( TS2_BitStream bits,
ATX_UInt64 *  timecode 
)

◆ TS2_BitStream_Reset()

ATX_Result TS2_BitStream_Reset ( TS2_BitStream bits)

◆ TS2_BitStream_Rewind()

ATX_Result TS2_BitStream_Rewind ( TS2_BitStream bits,
ATX_UInt32  n 
)

◆ TS2_BitStream_SetData()

ATX_Result TS2_BitStream_SetData ( TS2_BitStream bits,
const ATX_Byte *  data,
ATX_Size  data_size 
)

◆ TS2_BitStream_SkipBit()

void TS2_BitStream_SkipBit ( TS2_BitStream bits)

◆ TS2_BitStream_SkipBits()

void TS2_BitStream_SkipBits ( TS2_BitStream bits,
ATX_UInt32  n 
)

◆ TS2_BitWriter_SetData()

ATX_Result TS2_BitWriter_SetData ( TS2_BitWriter writer,
ATX_Byte *  data,
ATX_Size  data_size 
)

doesn't take ownership of data, just write into the buffer

◆ TS2_BitWriter_Write()

ATX_Result TS2_BitWriter_Write ( TS2_BitWriter writer,
ATX_UInt32  bits,
ATX_UInt32  bit_count 
)

◆ TS2_BitWriter_WriteAlignedBytes()

ATX_Result TS2_BitWriter_WriteAlignedBytes ( TS2_BitWriter writer,
ATX_Byte *  data,
ATX_Size  data_size 
)