#include "rtp.h"
int
-rtp_packetize_h264_nal( sout_stream_t *p_stream, sout_stream_id_t *id,
+rtp_packetize_h264_nal( sout_stream_id_t *id,
const uint8_t *p_data, int i_data, int64_t i_pts,
int64_t i_dts, bool b_last, int64_t i_length );
-int rtp_packetize_mpa( sout_stream_t *p_stream, sout_stream_id_t *id,
+int rtp_packetize_mpa( sout_stream_id_t *id,
block_t *in )
{
int i_max = rtp_mtu (id) - 4; /* payload max in one packet */
}
/* rfc2250 */
-int rtp_packetize_mpv( sout_stream_t *p_stream, sout_stream_id_t *id,
- block_t *in )
+int rtp_packetize_mpv( sout_stream_id_t *id, block_t *in )
{
int i_max = rtp_mtu (id) - 4; /* payload max in one packet */
int i_count = ( in->i_buffer + i_max - 1 ) / i_max;
return VLC_SUCCESS;
}
-int rtp_packetize_ac3( sout_stream_t *p_stream, sout_stream_id_t *id,
- block_t *in )
+int rtp_packetize_ac3( sout_stream_id_t *id, block_t *in )
{
int i_max = rtp_mtu (id) - 2; /* payload max in one packet */
int i_count = ( in->i_buffer + i_max - 1 ) / i_max;
return VLC_SUCCESS;
}
-int rtp_packetize_split( sout_stream_t *p_stream, sout_stream_id_t *id,
- block_t *in )
+int rtp_packetize_split( sout_stream_id_t *id, block_t *in )
{
int i_max = rtp_mtu (id); /* payload max in one packet */
int i_count = ( in->i_buffer + i_max - 1 ) / i_max;
}
/* rfc3016 */
-int rtp_packetize_mp4a_latm( sout_stream_t *p_stream, sout_stream_id_t *id,
- block_t *in )
+int rtp_packetize_mp4a_latm( sout_stream_id_t *id, block_t *in )
{
int i_max = rtp_mtu (id) - 2; /* payload max in one packet */
int latmhdrsize = in->i_buffer / 0xff + 1;
return VLC_SUCCESS;
}
-int rtp_packetize_mp4a( sout_stream_t *p_stream, sout_stream_id_t *id,
- block_t *in )
+int rtp_packetize_mp4a( sout_stream_id_t *id, block_t *in )
{
int i_max = rtp_mtu (id) - 4; /* payload max in one packet */
int i_count = ( in->i_buffer + i_max - 1 ) / i_max;
/* rfc2429 */
#define RTP_H263_HEADER_SIZE (2) // plen = 0
#define RTP_H263_PAYLOAD_START (14) // plen = 0
-int rtp_packetize_h263( sout_stream_t *p_stream, sout_stream_id_t *id,
- block_t *in )
+int rtp_packetize_h263( sout_stream_id_t *id, block_t *in )
{
uint8_t *p_data = in->p_buffer;
int i_data = in->i_buffer;
/* rfc3984 */
int
-rtp_packetize_h264_nal( sout_stream_t *p_stream, sout_stream_id_t *id,
+rtp_packetize_h264_nal( sout_stream_id_t *id,
const uint8_t *p_data, int i_data, int64_t i_pts,
int64_t i_dts, bool b_last, int64_t i_length )
{
return VLC_SUCCESS;
}
-int rtp_packetize_h264( sout_stream_t *p_stream, sout_stream_id_t *id,
- block_t *in )
+int rtp_packetize_h264( sout_stream_id_t *id, block_t *in )
{
const uint8_t *p_buffer = in->p_buffer;
int i_buffer = in->i_buffer;
}
}
/* TODO add STAP-A to remove a lot of overhead with small slice/sei/... */
- rtp_packetize_h264_nal( p_stream, id, p_buffer, i_size,
+ rtp_packetize_h264_nal( id, p_buffer, i_size,
(in->i_pts > 0 ? in->i_pts : in->i_dts), in->i_dts,
(i_size >= i_buffer), in->i_length * i_size / in->i_buffer );
return VLC_SUCCESS;
}
-int rtp_packetize_amr( sout_stream_t *p_stream, sout_stream_id_t *id,
- block_t *in )
+int rtp_packetize_amr( sout_stream_id_t *id, block_t *in )
{
int i_max = rtp_mtu (id) - 2; /* payload max in one packet */
int i_count = ( in->i_buffer + i_max - 1 ) / i_max;
return VLC_SUCCESS;
}
-int rtp_packetize_t140( sout_stream_t *p_stream, sout_stream_id_t *id,
- block_t *in )
+int rtp_packetize_t140( sout_stream_id_t *id, block_t *in )
{
const size_t i_max = rtp_mtu (id);
const uint8_t *p_data = in->p_buffer;
}
-int rtp_packetize_spx( sout_stream_t *p_stream, sout_stream_id_t *id,
- block_t *in )
+int rtp_packetize_spx( sout_stream_id_t *id, block_t *in )
{
uint8_t *p_buffer = in->p_buffer;
int i_data_size, i_payload_size, i_payload_padding;
block_t *p_out;
if ( in->i_buffer > rtp_mtu (id) )
- {
- msg_Warn( p_stream, "Cannot send packet larger than output MTU" );
return VLC_SUCCESS;
- }
/*
RFC for Speex in RTP says that each packet must end on an octet