summaryrefslogtreecommitdiff
path: root/libavformat/sdp.c
Commit message (Collapse)AuthorAge
* cosmetics: Fix spelling mistakesVittorio Giovara2016-05-04
| | | | Signed-off-by: Diego Biurrun <diego@biurrun.de>
* sdp: fix opus sprop-stereo fmtp syntaxMark Harris2016-03-01
| | | | Signed-off-by: Martin Storsjö <martin@martin.st>
* lavf: replace AVStream.codec with AVStream.codecparAnton Khirnov2016-02-23
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Currently, AVStream contains an embedded AVCodecContext instance, which is used by demuxers to export stream parameters to the caller and by muxers to receive stream parameters from the caller. It is also used internally as the codec context that is passed to parsers. In addition, it is also widely used by the callers as the decoding (when demuxer) or encoding (when muxing) context, though this has been officially discouraged since Libav 11. There are multiple important problems with this approach: - the fields in AVCodecContext are in general one of * stream parameters * codec options * codec state However, it's not clear which ones are which. It is consequently unclear which fields are a demuxer allowed to set or a muxer allowed to read. This leads to erratic behaviour depending on whether decoding or encoding is being performed or not (and whether it uses the AVStream embedded codec context). - various synchronization issues arising from the fact that the same context is used by several different APIs (muxers/demuxers, parsers, bitstream filters and encoders/decoders) simultaneously, with there being no clear rules for who can modify what and the different processes being typically delayed with respect to each other. - avformat_find_stream_info() making it necessary to support opening and closing a single codec context multiple times, thus complicating the semantics of freeing various allocated objects in the codec context. Those problems are resolved by replacing the AVStream embedded codec context with a newly added AVCodecParameters instance, which stores only the stream parameters exported by the demuxers or read by the muxers.
* rtp: Initial H.261 supportThomas Volkert2014-12-18
| | | | | | | | | | | | | | The packetizer only supports splitting at GOB headers - if such aren't available frequently enough, it splits at any random byte offset (not at a macroblock boundary either, which would be allowed by the spec) and sends a payload header pretend that it starts with a GOB header. As long as a receiver doesn't try to handle such cases cleverly but just drops broken frames, this shouldn't matter too much in practice. Signed-off-by: Martin Storsjö <martin@martin.st>
* sdp: Provide out of bound parameter sets for HEVC if extradata is setMartin Storsjö2014-10-15
| | | | Signed-off-by: Martin Storsjö <martin@martin.st>
* sdp: Simplify parsing/conversion of H264 extradataMartin Storsjö2014-10-06
| | | | | | | | | | | | By using ff_avc_write_annexb_extradata instead of the h264_mp4toannexb BSF, the code for doing the conversion itself is kept much shorter, there's less state to restore at the end, we don't risk leaving the AVCodecContext in an inconsistent state if returning early due to errors, etc. Also add a missing free if the base64 encoding fails. Signed-off-by: Martin Storsjö <martin@martin.st>
* sdp: Make opus declaration conform to the specTimothy B. Terriberry2014-09-29
| | | | Signed-off-by: Martin Storsjö <martin@martin.st>
* rtpenc: HEVC/H.265 supportThomas Volkert2014-09-24
| | | | Signed-off-by: Martin Storsjö <martin@martin.st>
* cosmetics: Write NULL pointer equality checks more compactlyGabriel Dume2014-08-15
| | | | Signed-off-by: Diego Biurrun <diego@biurrun.de>
* sdp: Check that fmt->oformat is non-null before accessing itMartin Storsjö2014-01-05
| | | | | | | | This avoids crashes when avserver tries to create an SDP, since d77f4af. CC: libav-stable@libav.org Signed-off-by: Martin Storsjö <martin@martin.st>
* sdp: Check theora colorspace before producing the configuration stringMartin Storsjö2013-12-14
| | | | | | | This avoids a memory leak (or having to worry about freeing the config string) if the colorspace isn't accepted. Signed-off-by: Martin Storsjö <martin@martin.st>
* sdp: Include SRTP crypto params if using the srtp protocolMartin Storsjö2013-01-15
| | | | | | Also print port numbers for this protocol. Signed-off-by: Martin Storsjö <martin@martin.st>
* rtp: set the payload type as stream idLuca Barbato2012-11-14
| | | | | | | Support multiple video/audio streams with different format in the same session. Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
* rtp: Support packetization/depacketization of opusMartin Storsjö2012-10-09
| | | | Signed-off-by: Martin Storsjö <martin@martin.st>
* Replace PIX_FMT_* -> AV_PIX_FMT_*, PixelFormat -> AVPixelFormatAnton Khirnov2012-10-08
|
* rtpenc: Add support for packetizing speexDmitry Samonenko2012-09-26
| | | | | | | This packetization scheme simply places the full packets into the RTP packet without any extra header bytes. Signed-off-by: Martin Storsjö <martin@martin.st>
* rtp: Packetization of JPEG (RFC 2435)Samuel Pitoiset2012-09-23
|
* sdp: Use static const char arrays instead of pointers to stringsMartin Storsjö2012-08-28
| | | | Signed-off-by: Martin Storsjö <martin@martin.st>
* sdp: Include profile-level-id for H264Martin Storsjö2012-08-28
| | | | | | | This is required for playback with the Stagefright RTSP framework on Android. Signed-off-by: Martin Storsjö <martin@martin.st>
* Replace all CODEC_ID_* with AV_CODEC_ID_*Anton Khirnov2012-08-07
|
* rtpenc: Support packetizing iLBCMartin Storsjö2012-06-18
| | | | Signed-off-by: Martin Storsjö <martin@martin.st>
* rtpenc: Allow requesting H264 RTP packetization mode 0Martin Storsjö2012-06-18
| | | | | | | | | This requires all NAL units to fit within single RTP packets. It doesn't change the actual packetization for packets that fit, but errors out and gives a helpful hint if the NAL units would have to be split, and signals the right packetization mode in the SDP. Signed-off-by: Martin Storsjö <martin@martin.st>
* Replace memset(0) by zero initializations.Diego Biurrun2012-03-28
| | | | Also remove one pointless zero initialization in rangecoder.c.
* rtpenc: Allow packetizing H263 according to the old RFC 2190Martin Storsjö2012-02-23
| | | | | | | | | | | | | | | | | | According to newer RFCs, this packetization scheme should only be used for interfacing with legacy systems. Implementing this packetization mode properly requires parsing the full H263 bitstream to find macroblock boundaries (and knowing their macroblock and gob numbers and motion vector predictors). This implementation tries to look for GOB headers (which can be inserted by using -ps <small number>), but if the GOBs aren't small enough to fit into the MTU, the packetizer blindly splits packets at any offset and claims it to be a GOB boundary (by using Mode A from the RFC). While not correct, this seems to work with some receivers. Signed-off-by: Martin Storsjö <martin@martin.st>
* cosmetics: Remove extra newlines at EOFAlex Converse2012-01-27
|
* lavf: remove disabled FF_API_SDP_CREATE cruftAnton Khirnov2012-01-27
|
* sdp: Restore the original mp4 format h264 extradata if convertedMartin Storsjö2011-12-11
| | | | | | | | | If the sdp is generated before the rtp muxer is initialized (e.g. as when called from the rtsp muxer), this has to be done, otherwise the rtp muxer doesn't know that the input really is in mp4 format. Signed-off-by: Martin Storsjö <martin@martin.st>
* rtpenc: Add support for G726 audioMartin Storsjö2011-12-01
| | | | Signed-off-by: Martin Storsjö <martin@martin.st>
* lavc: use avpriv_ prefix for ff_split_xiph_headers.Anton Khirnov2011-10-20
| | | | It's used in lavf.
* lavc: use avpriv_ prefix for some mpeg4audio symbols used in lavf.Anton Khirnov2011-10-20
| | | | | Specifically, ff_mpeg4audio_sample_rates, ff_mpeg4audio_get_config and ff_copy_pce_data
* rtpenc: Add a payload type private optionRafaël Carré2011-09-26
| | | | | | | | Specifying the payload type is useful when the type number has already been negotiated before creating the stream, for example in SIP protocol. Signed-off-by: Martin Storsjö <martin@martin.st>
* rtp: factorize dynamic payload type fallbackRafaël Carré2011-09-23
| | | | | | | Move the identical code in rtp_write_header() and ff_sdp_write_media() inside ff_rtp_get_payload_type() Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
* sdp: Reindent after the previous commitMartin Storsjö2011-06-10
| | | | Signed-off-by: Martin Storsjö <martin@martin.st>
* rtpenc: MP4A-LATM payload supportJuan Carlos Rodriguez2011-06-10
| | | | | | | This is enabled with an AVOption on the RTP muxer. The SDP generator looks for a latm flag in the rtpflags field. Signed-off-by: Martin Storsjö <martin@martin.st>
* sdp: Allow passing an AVFormatContext to the SDP generationMartin Storsjö2011-06-10
| | | | | | | Options from the AVFormatContext can be read for modifying the generated SDP. Signed-off-by: Martin Storsjö <martin@martin.st>
* Remove all uses of now deprecated metadata functions.Anton Khirnov2011-06-08
|
* lavf: rename a parameter of av_sdp_create from buff->bufAnton Khirnov2011-04-08
| | | | This is more consistent with the rest of the API.
* lavf: rename avf_sdp_create to av_sdp_create.Anton Khirnov2011-04-08
| | | | The new name is more consistent with the rest of the API.
* Replace FFmpeg with Libav in licence headersMans Rullgard2011-03-19
| | | | Signed-off-by: Mans Rullgard <mans@mansr.com>
* Move find_info_tag to lavu and add av_ prefix to itAnton Khirnov2011-02-17
| | | | Signed-off-by: Janne Grunau <janne-ffmpeg@jannau.net>
* sdp: Add a framesize attribute to H.263 SDP descriptionsMartin Storsjö2010-12-20
| | | | | | | | While not mentioned in RFC 4629, this is required for H.263 in 3GPP TS 26.234. It is in practice required for playback with Android stagefright and on Samsung bada phones. Originally committed as revision 26062 to svn://svn.ffmpeg.org/ffmpeg/trunk
* sdp: Conditionally compile code using AF_INET6Martin Storsjö2010-10-19
| | | | | | Should fix compilation in environments unaware of IPv6. Originally committed as revision 25528 to svn://svn.ffmpeg.org/ffmpeg/trunk
* sdp: Only specify the TTL for IPv4 addressesMartin Storsjö2010-10-08
| | | | | | According to RFC 4566, a TTL value must not be present for IPv6 multicast. Originally committed as revision 25412 to svn://svn.ffmpeg.org/ffmpeg/trunk
* ReindentMartin Storsjö2010-10-07
| | | | Originally committed as revision 25390 to svn://svn.ffmpeg.org/ffmpeg/trunk
* sdp: Don't require the explicit ?multicast optionMartin Storsjö2010-10-07
| | | | | | No such option is used anywhere else. Instead, detect the address type. Originally committed as revision 25389 to svn://svn.ffmpeg.org/ffmpeg/trunk
* Handle G.722 in RTP, and all the exceptions mandated in RFC 3551Martin Storsjö2010-09-15
| | | | Originally committed as revision 25125 to svn://svn.ffmpeg.org/ffmpeg/trunk
* Make stub version of ff_sdp_write_media() match its prototypeAndreas Öman2010-08-25
| | | | | | | | Used when compiled without CONFIG_RTP_MUXER Fallout from r24915 Originally committed as revision 24935 to svn://svn.ffmpeg.org/ffmpeg/trunk
* ReindentMartin Storsjö2010-08-25
| | | | Originally committed as revision 24919 to svn://svn.ffmpeg.org/ffmpeg/trunk
* Simplify resolve_destination in sdp.c further, now that we don't enforce ↵Martin Storsjö2010-08-25
| | | | | | IPv4 any longer Originally committed as revision 24918 to svn://svn.ffmpeg.org/ffmpeg/trunk
* 10l, add new function parameters to resolve_destination for !config_network tooMartin Storsjö2010-08-25
| | | | Originally committed as revision 24917 to svn://svn.ffmpeg.org/ffmpeg/trunk