libdvbpsi  2.0.0-git
MPEG Transport Stream PSI table parser
Data Structures | Typedefs | Functions | Variables
atsc_mgt.h File Reference

Decode PSIP Master Guide Table (ATSC MGT). More...

Go to the source code of this file.

Data Structures

struct  dvbpsi_atsc_mgt_table_s
 MGT table structure. More...
 
struct  dvbpsi_atsc_mgt_s
 MGT structure. More...
 

Typedefs

typedef struct dvbpsi_atsc_mgt_table_s dvbpsi_atsc_mgt_table_t
 dvbpsi_atsc_mgt_table_t type definition.
 
typedef struct dvbpsi_atsc_mgt_s dvbpsi_atsc_mgt_t
 dvbpsi_atsc_mgt_t type definition.
 
typedef void(* dvbpsi_atsc_mgt_callback) (void *p_priv, dvbpsi_atsc_mgt_t *p_new_mgt)
 Callback type definition.
 

Functions

bool dvbpsi_atsc_mgt_attach (dvbpsi_t *p_dvbpsi, uint8_t i_table_id, uint16_t i_extension, dvbpsi_atsc_mgt_callback pf_callback, void *p_priv)
 
 __attribute__ ((deprecated, unused)) inline bool dvbpsi_atsc_AttachMGT(dvbpsi_t *p_dvbpsi
 dvbpsi_atsc_AttachMGT is deprecated use More...
 
void dvbpsi_atsc_mgt_detach (dvbpsi_t *p_dvbpsi, uint8_t i_table_id, uint16_t i_extension)
 Destroy a MGT decoder. More...
 
void dvbpsi_atsc_mgt_init (dvbpsi_atsc_mgt_t *p_mgt, uint8_t i_table_id, uint16_t i_extension, uint8_t i_version, uint8_t i_protocol, bool b_current_next)
 Initialize a user-allocated dvbpsi_atsc_mgt_t structure. More...
 
dvbpsi_atsc_mgt_tdvbpsi_atsc_mgt_new (uint8_t i_table_id, uint16_t i_extension, uint8_t i_version, uint8_t i_protocol, bool b_current_next)
 Allocate and initialize a new dvbpsi_mgt_t structure. More...
 
void dvbpsi_atsc_mgt_empty (dvbpsi_atsc_mgt_t *p_mgt)
 Clean a dvbpsi_mgt_t structure. More...
 
void dvbpsi_atsc_mgt_delete (dvbpsi_atsc_mgt_t *p_mgt)
 Clean and free a dvbpsi_mgt_t structure. More...
 

Variables

uint8_t i_table_id
 
uint8_t uint16_t i_extension
 
uint8_t uint16_t dvbpsi_atsc_mgt_callback pf_callback
 
uint8_t uint16_t dvbpsi_atsc_mgt_callback void * p_priv
 
uint8_t uint16_t uint8_t i_version
 
uint8_t uint16_t uint8_t uint8_t i_protocol
 
uint8_t uint16_t uint8_t uint8_t bool b_current_next
 

Detailed Description

Decode PSIP Master Guide Table (ATSC MGT).

Author
Adam Charrett and Michael Krufky

Function Documentation

◆ __attribute__()

__attribute__ ( (deprecated, unused)  )

dvbpsi_atsc_AttachMGT is deprecated use

dvbpsi_atsc_DetachEIT is deprecated use

dvbpsi_atsc_DeleteMGT is deprecated use

dvbpsi_atsc_EmptyMGT is deprecated use

dvbpsi_atsc_NewMGT is deprecated use

dvbpsi_atsc_InitMGT is deprecated use

dvbpsi_atsc_DetachMGT is deprecated use

See also
dvbpsi_atsc_mgt_attach() instead.
Parameters
p_dvbpsidvbpsi handle to Subtable demultiplexor to which the decoder is attached
i_table_idTable ID, 0xC7.
i_extensionTable ID extension, here 0x0000.
pf_callbackfunction to call back on new MGT.
p_privprivate data given in argument to the callback.
Returns
true if everything went ok, false otherwise
See also
dvbpsi_atsc_mgt_detach() instead.

Destroy a MGT decoder.

Parameters
p_dvbpsidvbpsi handle to Subtable demultiplexor to which the decoder is attached
i_table_idTable ID, 0xC7.
i_extensionTable ID extension, here 0x0000.
Returns
nothing.
See also
dvbpsi_atsc_mgt_init() instead.
Parameters
p_mgtpointer to the MGT structure
i_table_idTable ID, 0xC7.
i_extensionTable ID extension, here 0x0000.
i_versionMGT version
i_protocolPSIP Protocol version.
b_current_nextcurrent next indicator
Returns
nothing.
See also
dvbpsi_atsc_mgt_new() instead.
Parameters
i_table_idTable ID, 0xC7.
i_extensionTable ID extension, here 0x0000.
i_versionMGT version
i_protocolPSIP Protocol version.
b_current_nextcurrent next indicator
Returns
p_mgt pointer to the MGT structure, or NULL on failure
See also
dvbpsi_atsc_mgt_empty() instead.
Parameters
p_mgtpointer to the MGT structure
Returns
nothing.
See also
dvbpsi_atsc_mgt_delete() instead.

Clean and free a dvbpsi_mgt_t structure.

Parameters
p_mgtpointer to the MGT structure
Returns
nothing.

References dvbpsi_atsc_mgt_empty().

◆ dvbpsi_atsc_mgt_delete()

void dvbpsi_atsc_mgt_delete ( dvbpsi_atsc_mgt_t p_mgt)

Clean and free a dvbpsi_mgt_t structure.

Parameters
p_mgtpointer to the MGT structure
Returns
nothing.

◆ dvbpsi_atsc_mgt_detach()

void dvbpsi_atsc_mgt_detach ( dvbpsi_t p_dvbpsi,
uint8_t  i_table_id,
uint16_t  i_extension 
)

Destroy a MGT decoder.

Parameters
p_dvbpsidvbpsi handle to Subtable demultiplexor to which the decoder is attached
i_table_idTable ID, 0xC7.
i_extensionTable ID extension, here 0x0000.
Returns
nothing.

◆ dvbpsi_atsc_mgt_empty()

void dvbpsi_atsc_mgt_empty ( dvbpsi_atsc_mgt_t p_mgt)

Clean a dvbpsi_mgt_t structure.

Parameters
p_mgtpointer to the MGT structure
Returns
nothing.

Referenced by __attribute__().

◆ dvbpsi_atsc_mgt_init()

void dvbpsi_atsc_mgt_init ( dvbpsi_atsc_mgt_t p_mgt,
uint8_t  i_table_id,
uint16_t  i_extension,
uint8_t  i_version,
uint8_t  i_protocol,
bool  b_current_next 
)

Initialize a user-allocated dvbpsi_atsc_mgt_t structure.

Parameters
p_mgtpointer to the MGT structure
i_table_idTable ID, 0xC7.
i_extensionTable ID extension, here 0x0000.
i_versionMGT version
i_protocolPSIP Protocol version.
b_current_nextcurrent next indicator
Returns
nothing.

◆ dvbpsi_atsc_mgt_new()

dvbpsi_atsc_mgt_t * dvbpsi_atsc_mgt_new ( uint8_t  i_table_id,
uint16_t  i_extension,
uint8_t  i_version,
uint8_t  i_protocol,
bool  b_current_next 
)

Allocate and initialize a new dvbpsi_mgt_t structure.

Parameters
i_table_idTable ID, 0xC7.
i_extensionTable ID extension, here 0x0000.
i_versionMGT version
i_protocolPSIP Protocol version.
b_current_nextcurrent next indicator
Returns
p_mgt pointer to the MGT structure, or NULL on failure

Variable Documentation

◆ b_current_next

uint16_t uint8_t uint8_t bool b_current_next
Initial value:
{
dvbpsi_atsc_mgt_init(p_mgt, i_table_id, i_extension,
i_version, i_protocol,b_current_next)
void dvbpsi_atsc_mgt_init(dvbpsi_atsc_mgt_t *p_mgt, uint8_t i_table_id, uint16_t i_extension, uint8_t i_version, uint8_t i_protocol, bool b_current_next)
Initialize a user-allocated dvbpsi_atsc_mgt_t structure.

◆ i_extension

uint16_t i_extension
Initial value:
{
dvbpsi_atsc_mgt_detach(p_dvbpsi, i_table_id, i_extension)
void dvbpsi_atsc_mgt_detach(dvbpsi_t *p_dvbpsi, uint8_t i_table_id, uint16_t i_extension)
Destroy a MGT decoder.

◆ p_priv

uint8_t uint16_t dvbpsi_atsc_mgt_callback void* p_priv
Initial value:
{
return dvbpsi_atsc_mgt_attach(p_dvbpsi, i_table_id, i_extension,
pf_callback, p_priv)