ROHC compression/decompression library
c_ip.h
Go to the documentation of this file.
1 /*
2  * Copyright 2012,2013 Didier Barvaux
3  * Copyright 2007,2008 Thales Alenia Space
4  * Copyright 2007,2009,2010,2014 Viveris Technologies
5  *
6  * This library is free software; you can redistribute it and/or
7  * modify it under the terms of the GNU Lesser General Public
8  * License as published by the Free Software Foundation; either
9  * version 2.1 of the License, or (at your option) any later version.
10  *
11  * This library is distributed in the hope that it will be useful,
12  * but WITHOUT ANY WARRANTY; without even the implied warranty of
13  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14  * Lesser General Public License for more details.
15  *
16  * You should have received a copy of the GNU Lesser General Public
17  * License along with this library; if not, write to the Free Software
18  * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
19  */
20 
21 /**
22  * @file c_ip.h
23  * @brief ROHC compression context for the IP-only profile.
24  * @author Didier Barvaux <didier.barvaux@toulouse.viveris.com>
25  */
26 
27 #ifndef ROHC_COMP_IP_H
28 #define ROHC_COMP_IP_H
29 
30 #include "rohc_comp_rfc3095.h"
31 
32 /*
33  * Public function prototypes.
34  */
35 
36 rohc_packet_t c_ip_decide_FO_packet(const struct rohc_comp_ctxt *const context)
37  __attribute__((warn_unused_result, nonnull(1)));
38 rohc_packet_t c_ip_decide_SO_packet(const struct rohc_comp_ctxt *const context)
39  __attribute__((warn_unused_result, nonnull(1)));
40 
41 uint32_t c_ip_get_next_sn(const struct rohc_comp_ctxt *const context,
42  const struct rohc_pkt_hdrs *const uncomp_pkt_hdrs __attribute__((unused)))
43  __attribute__((warn_unused_result, nonnull(1, 2), pure));
44 
45 int c_ip_code_ir_remainder(const struct rohc_comp_ctxt *const context,
46  uint8_t *const dest,
47  const size_t dest_max_len,
48  const size_t counter)
49  __attribute__((warn_unused_result, nonnull(1, 2)));
50 
51 #endif
52 
Generic framework for RFC3095-based compression profiles such as IP-only, UDP, UDP-Lite, ESP, and RTP profiles.
The ROHC compression context.
Definition: rohc_comp_internals.h:278
bool nonnull(1)))
rohc_packet_t c_ip_decide_FO_packet(const struct rohc_comp_ctxt *const context)
Decide which packet to send when in First Order (FO) state.
Definition: c_ip.c:105
The information collected about the packet headers.
Definition: uncomp_pkt_hdrs.h:102
uint32_t c_ip_get_next_sn(const struct rohc_comp_ctxt *const context, const struct rohc_pkt_hdrs *const uncomp_pkt_hdrs)
Determine the SN value for the next packet.
Definition: c_ip.c:281
int c_ip_code_ir_remainder(const struct rohc_comp_ctxt *const context, uint8_t *const dest, const size_t dest_max_len, const size_t counter)
Code the remainder header for the IR or IR-DYN packets.
Definition: c_ip.c:323
rohc_packet_t c_ip_decide_SO_packet(const struct rohc_comp_ctxt *const context)
Decide which packet to send when in Second Order (SO) state.
Definition: c_ip.c:157
rohc_packet_t
The different types of ROHC packets.
Definition: rohc_packets.h:55