ROHC compression/decompression library
Macros | Enumerations | Functions
rohc_packets.h File Reference

Definition of ROHC packets and extensions. More...

#include <stdbool.h>
Include dependency graph for rohc_packets.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Macros

#define ROHC_EXPORT
 
#define ROHC_PACKET_CO_COMMON   ROHC_PACKET_TCP_CO_COMMON
 

Enumerations

enum  rohc_packet_t {
  ROHC_PACKET_IR = 0, ROHC_PACKET_IR_DYN = 1, ROHC_PACKET_UO_0 = 2, ROHC_PACKET_UO_1 = 3,
  ROHC_PACKET_UO_1_ID = 4, ROHC_PACKET_UO_1_TS = 5, ROHC_PACKET_UO_1_RTP = 6, ROHC_PACKET_UOR_2 = 7,
  ROHC_PACKET_UOR_2_RTP = 8, ROHC_PACKET_UOR_2_ID = 9, ROHC_PACKET_UOR_2_TS = 10, ROHC_PACKET_NORMAL = 13,
  ROHC_PACKET_UNKNOWN = 14, ROHC_PACKET_TCP_CO_COMMON = 15, ROHC_PACKET_TCP_RND_1 = 16, ROHC_PACKET_TCP_RND_2 = 17,
  ROHC_PACKET_TCP_RND_3 = 18, ROHC_PACKET_TCP_RND_4 = 19, ROHC_PACKET_TCP_RND_5 = 20, ROHC_PACKET_TCP_RND_6 = 21,
  ROHC_PACKET_TCP_RND_7 = 22, ROHC_PACKET_TCP_RND_8 = 23, ROHC_PACKET_TCP_SEQ_1 = 24, ROHC_PACKET_TCP_SEQ_2 = 25,
  ROHC_PACKET_TCP_SEQ_3 = 26, ROHC_PACKET_TCP_SEQ_4 = 27, ROHC_PACKET_TCP_SEQ_5 = 28, ROHC_PACKET_TCP_SEQ_6 = 29,
  ROHC_PACKET_TCP_SEQ_7 = 30, ROHC_PACKET_TCP_SEQ_8 = 31, ROHC_PACKET_IR_CR = 32, ROHC_PACKET_CO_REPAIR = 33,
  ROHC_PACKET_PT_0_CRC3 = 34, ROHC_PACKET_NORTP_PT_0_CRC7 = 35, ROHC_PACKET_NORTP_PT_1_SEQ_ID = 36, ROHC_PACKET_NORTP_PT_2_SEQ_ID = 37,
  ROHC_PACKET_RTP_PT_0_CRC7 = 38, ROHC_PACKET_RTP_PT_1_RND = 39, ROHC_PACKET_RTP_PT_1_SEQ_ID = 40, ROHC_PACKET_RTP_PT_1_SEQ_TS = 41,
  ROHC_PACKET_RTP_PT_2_RND = 42, ROHC_PACKET_RTP_PT_2_SEQ_ID = 43, ROHC_PACKET_RTP_PT_2_SEQ_TS = 44, ROHC_PACKET_RTP_PT_2_SEQ_BOTH = 45,
  ROHC_PACKET_UO_1_ID_EXT0 = 46, ROHC_PACKET_UO_1_ID_EXT1 = 47, ROHC_PACKET_UO_1_ID_EXT2 = 48, ROHC_PACKET_UO_1_ID_EXT3 = 49,
  ROHC_PACKET_UOR_2_EXT0 = 50, ROHC_PACKET_UOR_2_EXT1 = 51, ROHC_PACKET_UOR_2_EXT2 = 52, ROHC_PACKET_UOR_2_EXT3 = 53,
  ROHC_PACKET_UOR_2_RTP_EXT0 = 54, ROHC_PACKET_UOR_2_RTP_EXT1 = 55, ROHC_PACKET_UOR_2_RTP_EXT2 = 56, ROHC_PACKET_UOR_2_RTP_EXT3 = 57,
  ROHC_PACKET_UOR_2_ID_EXT0 = 58, ROHC_PACKET_UOR_2_ID_EXT1 = 59, ROHC_PACKET_UOR_2_ID_EXT2 = 60, ROHC_PACKET_UOR_2_ID_EXT3 = 61,
  ROHC_PACKET_UOR_2_TS_EXT0 = 62, ROHC_PACKET_UOR_2_TS_EXT1 = 63, ROHC_PACKET_UOR_2_TS_EXT2 = 64, ROHC_PACKET_UOR_2_TS_EXT3 = 65,
  ROHC_PACKET_MAX
}
 The different types of ROHC packets. More...
 
enum  rohc_ext_t {
  ROHC_EXT_0 = 0, ROHC_EXT_1 = 1, ROHC_EXT_2 = 2, ROHC_EXT_3 = 3,
  ROHC_EXT_NONE = 4, ROHC_EXT_UNKNOWN = 5
}
 The different types of extensions for UO-1-ID and UOR-2* packets. More...
 

Functions

const char *ROHC_EXPORT rohc_get_packet_descr (const rohc_packet_t packet_type)
 Give a description for the given type of ROHC packet. More...
 
const char *ROHC_EXPORT rohc_get_ext_descr (const rohc_ext_t ext_type)
 Give a description for the given type of ROHC extension. More...
 
rohc_packet_t ROHC_EXPORT rohc_get_packet_type (const char *const packet_id)
 Get the packet type from a packet identifier. More...
 
bool ROHC_EXPORT rohc_packet_is_ir (const rohc_packet_t packet_type)
 Is the packet one IR, IR-DYN or IR-CR packet? More...
 
bool ROHC_EXPORT rohc_packet_carry_static_info (const rohc_packet_t packet_type)
 Does packet type carry static information? More...
 
bool ROHC_EXPORT rohc_packet_carry_crc_7_or_8 (const rohc_packet_t packet_type)
 Does packet type carry 7- or 8-bit CRC? More...
 

Detailed Description

Definition of ROHC packets and extensions.

Author
Didier Barvaux didie.nosp@m.r.ba.nosp@m.rvaux.nosp@m.@tou.nosp@m.louse.nosp@m..viv.nosp@m.eris..nosp@m.com

Macro Definition Documentation

◆ ROHC_EXPORT

#define ROHC_EXPORT

Macro that handles DLL export declarations gracefully

◆ ROHC_PACKET_CO_COMMON

#define ROHC_PACKET_CO_COMMON   ROHC_PACKET_TCP_CO_COMMON

ROHCv2 co_common packet

Enumeration Type Documentation

◆ rohc_ext_t

enum rohc_ext_t

The different types of extensions for UO-1-ID and UOR-2* packets.

If you add a new extension type, please also add the corresponding textual description in rohc_get_ext_descr.

Enumerator
ROHC_EXT_0 

The EXT-0 extension for UO-1-ID/UOR-2* packets

ROHC_EXT_1 

The EXT-1 extension for UO-1-ID/UOR-2* packets

ROHC_EXT_2 

The EXT-2 extension for UO-1-ID/UOR-2* packets

ROHC_EXT_3 

The EXT-3 extension for UO-1-ID/UOR-2* packets

ROHC_EXT_NONE 

No extension for UO-1-ID/UOR-2* packets

ROHC_EXT_UNKNOWN 

Unknown packet extension type

◆ rohc_packet_t

The different types of ROHC packets.

If you add a new packet type, please also add the corresponding textual description in rohc_get_packet_descr.

Enumerator
ROHC_PACKET_IR 

ROHC IR packet

ROHC_PACKET_IR_DYN 

ROHC IR-DYN packet

ROHC_PACKET_UO_0 

ROHC UO-0 packet

ROHC_PACKET_UO_1 

ROHC UO-1 packet (for all non-RTP profiles)

ROHC_PACKET_UO_1_ID 

ROHC UO-1-ID packet (RTP profile only)

ROHC_PACKET_UO_1_TS 

ROHC UO-1-TS packet (RTP profile only)

ROHC_PACKET_UO_1_RTP 

ROHC UO-1-RTP packet (RTP profile only)

ROHC_PACKET_UOR_2 

ROHC UOR-2 packet (for all non-RTP profiles)

ROHC_PACKET_UOR_2_RTP 

ROHC UO-2 packet (RTP profile only)

ROHC_PACKET_UOR_2_ID 

ROHC UO-2-ID packet (RTP profile only)

ROHC_PACKET_UOR_2_TS 

ROHC UO-2-TS packet (RTP profile only)

ROHC_PACKET_NORMAL 

ROHC Normal packet (Uncompressed profile only)

ROHC_PACKET_UNKNOWN 

Unknown packet type

ROHC_PACKET_TCP_CO_COMMON 

TCP co_common packet

ROHC_PACKET_TCP_RND_1 

TCP rnd_1 packet

ROHC_PACKET_TCP_RND_2 

TCP rnd_2 packet

ROHC_PACKET_TCP_RND_3 

TCP rnd_3 packet

ROHC_PACKET_TCP_RND_4 

TCP rnd_4 packet

ROHC_PACKET_TCP_RND_5 

TCP rnd_5 packet

ROHC_PACKET_TCP_RND_6 

TCP rnd_6 packet

ROHC_PACKET_TCP_RND_7 

TCP rnd_7 packet

ROHC_PACKET_TCP_RND_8 

TCP rnd_8 packet

ROHC_PACKET_TCP_SEQ_1 

TCP seq_1 packet

ROHC_PACKET_TCP_SEQ_2 

TCP seq_2 packet

ROHC_PACKET_TCP_SEQ_3 

TCP seq_3 packet

ROHC_PACKET_TCP_SEQ_4 

TCP seq_4 packet

ROHC_PACKET_TCP_SEQ_5 

TCP seq_5 packet

ROHC_PACKET_TCP_SEQ_6 

TCP seq_6 packet

ROHC_PACKET_TCP_SEQ_7 

TCP seq_7 packet

ROHC_PACKET_TCP_SEQ_8 

TCP seq_8 packet

ROHC_PACKET_IR_CR 

ROHC IR-CR packet

ROHC_PACKET_CO_REPAIR 

ROHCv2 CO-REPAIR packet

ROHC_PACKET_PT_0_CRC3 

ROHCv2 PT-0-CRC3 packet

ROHC_PACKET_NORTP_PT_0_CRC7 

ROHCv2 PT-0-CRC7 packet (non-RTP)

ROHC_PACKET_NORTP_PT_1_SEQ_ID 

ROHCv2 PT-1-SEQ-ID packet (non-RTP)

ROHC_PACKET_NORTP_PT_2_SEQ_ID 

ROHCv2 PT-2-SEQ-ID packet (non-RTP)

ROHC_PACKET_RTP_PT_0_CRC7 

ROHCv2 PT-0-CRC7 packet (RTP)

ROHC_PACKET_RTP_PT_1_RND 

ROHCv2 PT-1-RND packet (RTP)

ROHC_PACKET_RTP_PT_1_SEQ_ID 

ROHCv2 PT-1-SEQ-ID packet (RTP)

ROHC_PACKET_RTP_PT_1_SEQ_TS 

ROHCv2 PT-1-SEQ-TS packet (RTP)

ROHC_PACKET_RTP_PT_2_RND 

ROHCv2 PT-2-RND packet (RTP)

ROHC_PACKET_RTP_PT_2_SEQ_ID 

ROHCv2 PT-2-SEQ-ID packet (RTP)

ROHC_PACKET_RTP_PT_2_SEQ_TS 

ROHCv2 PT-2-SEQ-TS packet (RTP)

ROHC_PACKET_RTP_PT_2_SEQ_BOTH 

ROHCv2 PT-2-SEQ-BOTH packet (RTP)

ROHC_PACKET_UO_1_ID_EXT0 

ROHC UO-1-ID packet with EXT-0 (RTP profile only)

ROHC_PACKET_UO_1_ID_EXT1 

ROHC UO-1-ID packet with EXT-1 (RTP profile only)

ROHC_PACKET_UO_1_ID_EXT2 

ROHC UO-1-ID packet with EXT-2 (RTP profile only)

ROHC_PACKET_UO_1_ID_EXT3 

ROHC UO-1-ID packet with EXT-3 (RTP profile only)

ROHC_PACKET_UOR_2_EXT0 

ROHC UOR-2 packet with EXT-0 (non-RTP profiles)

ROHC_PACKET_UOR_2_EXT1 

ROHC UOR-2 packet with EXT-1 (non-RTP profiles)

ROHC_PACKET_UOR_2_EXT2 

ROHC UOR-2 packet with EXT-2 (non-RTP profiles)

ROHC_PACKET_UOR_2_EXT3 

ROHC UOR-2 packet with EXT-3 (non-RTP profiles)

ROHC_PACKET_UOR_2_RTP_EXT0 

ROHC UOR-2 packet with EXT-0 (RTP profile only)

ROHC_PACKET_UOR_2_RTP_EXT1 

ROHC UOR-2 packet with EXT-1 (RTP profile only)

ROHC_PACKET_UOR_2_RTP_EXT2 

ROHC UOR-2 packet with EXT-2 (RTP profile only)

ROHC_PACKET_UOR_2_RTP_EXT3 

ROHC UOR-2 packet with EXT-3 (RTP profile only)

ROHC_PACKET_UOR_2_ID_EXT0 

ROHC UOR-2-ID packet with EXT-0 (RTP profile only)

ROHC_PACKET_UOR_2_ID_EXT1 

ROHC UOR-2-ID packet with EXT-1 (RTP profile only)

ROHC_PACKET_UOR_2_ID_EXT2 

ROHC UOR-2-ID packet with EXT-2 (RTP profile only)

ROHC_PACKET_UOR_2_ID_EXT3 

ROHC UOR-2-ID packet with EXT-3 (RTP profile only)

ROHC_PACKET_UOR_2_TS_EXT0 

ROHC UOR-2-TS packet with EXT-0 (RTP profile only)

ROHC_PACKET_UOR_2_TS_EXT1 

ROHC UOR-2-TS packet with EXT-1 (RTP profile only)

ROHC_PACKET_UOR_2_TS_EXT2 

ROHC UOR-2-TS packet with EXT-2 (RTP profile only)

ROHC_PACKET_UOR_2_TS_EXT3 

ROHC UOR-2-TS packet with EXT-3 (RTP profile only)

ROHC_PACKET_MAX 

The number of packet types

Function Documentation

◆ rohc_packet_carry_crc_7_or_8()

bool ROHC_EXPORT rohc_packet_carry_crc_7_or_8 ( const rohc_packet_t  packet_type)

Does packet type carry 7- or 8-bit CRC?

Parameters
packet_typeThe type of packet
Returns
true if packet carries 7- or 8-bit CRC, false if it does not

◆ rohc_packet_carry_static_info()

bool ROHC_EXPORT rohc_packet_carry_static_info ( const rohc_packet_t  packet_type)

Does packet type carry static information?

Parameters
packet_typeThe type of packet
Returns
true if packet carries static information, false if it does not

◆ rohc_packet_is_ir()

bool ROHC_EXPORT rohc_packet_is_ir ( const rohc_packet_t  packet_type)

Is the packet one IR, IR-DYN or IR-CR packet?

Parameters
packet_typeThe type of packet
Returns
true if packet is IR, IR-DYN or IR-CR, false if it does not