ROHC compression/decompression library
rohc_packets.h
Go to the documentation of this file.
00001 /*
00002  * This program is free software; you can redistribute it and/or modify
00003  * it under the terms of the GNU General Public License as published by
00004  * the Free Software Foundation; either version 2 of the License, or
00005  * (at your option) any later version.
00006  *
00007  * This program is distributed in the hope that it will be useful,
00008  * but WITHOUT ANY WARRANTY; without even the implied warranty of
00009  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
00010  * GNU General Public License for more details.
00011  *
00012  * You should have received a copy of the GNU General Public License
00013  * along with this program; if not, write to the Free Software
00014  * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
00015  */
00016 
00017 /**
00018  * @file    rohc_packets.h
00019  * @brief   Definition of ROHC packets and extensions
00020  * @author  Didier Barvaux <didier.barvaux@toulouse.viveris.com>
00021  */
00022 
00023 #ifndef ROHC_PACKETS_H
00024 #define ROHC_PACKETS_H
00025 
00026 
00027 /**
00028  * @brief The different types of ROHC packets
00029  *
00030  * If you add a new packet type, please also add the corresponding textual
00031  * description in \ref rohc_get_packet_descr.
00032  */
00033 typedef enum
00034 {
00035         /* IR and IR-DYN packets */
00036         PACKET_IR        =  0, /**< ROHC IR packet */
00037         PACKET_IR_DYN    =  1, /**< ROHC IR-DYN packet */
00038 
00039         /* UO-0 packets */
00040         PACKET_UO_0      =  2, /**< ROHC UO-0 packet */
00041 
00042         /* UO-1 packets */
00043         PACKET_UO_1      =  3, /**< ROHC UO-1 packet (for all non-RTP profiles) */
00044         PACKET_UO_1_ID   =  4, /**< ROHC UO-1-ID packet (RTP profile only) */
00045         PACKET_UO_1_TS   =  5, /**< ROHC UO-1-TS packet (RTP profile only) */
00046         PACKET_UO_1_RTP  =  6, /**< ROHC UO-1-RTP packet (RTP profile only) */
00047 
00048         /* UOR-2 packets */
00049         PACKET_UOR_2     =  7, /**< ROHC UOR-2 packet (for all non-RTP profiles) */
00050         PACKET_UOR_2_RTP =  8, /**< ROHC UO-2 packet (RTP profile only) */
00051         PACKET_UOR_2_ID  =  9, /**< ROHC UO-2-ID packet (RTP profile only) */
00052         PACKET_UOR_2_TS  = 10, /**< ROHC UO-2-TS packet (RTP profile only) */
00053 
00054         /* CCE packets (UDP-Lite profile only) */
00055         PACKET_CCE       = 11, /**< ROHC CCE packet (UDP-Lite profile only) */
00056         PACKET_CCE_OFF   = 12, /**< ROHC CCE(OFF) packet (UDP-Lite profile only) */
00057 
00058         /* Normal packet (Uncompressed profile only) */
00059         PACKET_NORMAL    = 13, /**< ROHC Normal packet (Uncompressed profile only) */
00060 
00061         PACKET_UNKNOWN   = 14, /**< Unknown packet type */
00062 
00063 } rohc_packet_t;
00064 
00065 
00066 /**
00067  * @brief The different types of extensions for UO-1-ID and UOR-2* packets
00068  *
00069  * If you add a new extension type, please also add the corresponding textual
00070  * description in \ref rohc_get_ext_descr.
00071  */
00072 typedef enum
00073 {
00074         PACKET_EXT_0 = 0,  /**< The EXT-0 extension for UO-1-ID/UOR-2* packets */
00075         PACKET_EXT_1 = 1,  /**< The EXT-1 extension for UO-1-ID/UOR-2* packets */
00076         PACKET_EXT_2 = 2,  /**< The EXT-2 extension for UO-1-ID/UOR-2* packets */
00077         PACKET_EXT_3 = 3,  /**< The EXT-3 extension for UO-1-ID/UOR-2* packets */
00078         PACKET_NOEXT = 4,  /**< No extension for UO-1-ID/UOR-2* packets */
00079         PACKET_EXT_UNKNOWN = 5, /**< Unknown packet extension type */
00080 } rohc_ext_t;
00081 
00082 
00083 /*
00084  * Prototypes of public functions
00085  */
00086 
00087 const char * rohc_get_packet_descr(const rohc_packet_t packet_type);
00088 
00089 const char * rohc_get_ext_descr(const rohc_ext_t ext_type);
00090 
00091 
00092 #endif
00093