summaryrefslogtreecommitdiff
path: root/libavformat
Commit message (Collapse)AuthorAge
...
* lavf: Add a protocol for SRTP encryption/decryptionMartin Storsjö2013-01-15
| | | | | | | | This is mostly useful for encryption together with the RTP muxer, but could also be set up as IO towards the peer with the SDP demuxer with custom IO. Signed-off-by: Martin Storsjö <martin@martin.st>
* rtsp: Support decryption of SRTP signalled via RFC 4568 (SDES)Martin Storsjö2013-01-15
| | | | | | | | | | | | | | This only takes care of decrypting incoming packets; the outgoing RTCP packets are not encrypted. This is enough for some use cases, and signalling crypto keys for use with outgoing RTCP packets doesn't fit as simply into the API. If the SDP demuxer is hooked up with custom IO, the return packets can be encrypted e.g. via the SRTP protocol. If the SRTP keys aren't available within the SDP, the decryption can be handled externally as well (when using custom IO). Signed-off-by: Martin Storsjö <martin@martin.st>
* lavf: Add functions for SRTP decryption/encryptionMartin Storsjö2013-01-15
| | | | | | | | | | This supports the AES_CM_128_HMAC_SHA1_80 and AES_CM_128_HMAC_SHA1_32 cipher suites (from RFC 4568) at the moment. The main missing features are replay protection (which can be added later without changing the internal API), and the F8 and null ciphers. Signed-off-by: Martin Storsjö <martin@martin.st>
* nutdec: Always return a value from nut_read_timestamp()Diego Biurrun2013-01-15
| | | | | | | | | The function is a callback that is called by ff_gen_search with a constant stream index. Avoid a false positive on older gcc version. Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
* oggparsetheora: fix comment header parsingGiorgio Vazzana2013-01-14
| | | | | | Pass the correct header size to ff_vorbis_comment() Signed-off-by: Martin Storsjö <martin@martin.st>
* nut: support vp9 tagLuca Barbato2013-01-14
|
* mkv: support vp9 tagTom Finegan2013-01-14
|
* rtpdec: Make variables that should wrap unsignedMartin Storsjö2013-01-14
| | | | | | | This makes the behaviour defined when they wrap around. The value assigned to expected_prior was a uint32_t already. Signed-off-by: Martin Storsjö <martin@martin.st>
* rtpdec: Handle more received packets than expected when sending RRMartin Storsjö2013-01-14
| | | | | | | | | | Without this, we'd signal a huge loss rate (due to unsigned wraparound) if we had received one packet more than expected (that is, one seq number sent twice). The code has a check for lost_interval <= 0, but that doesn't do what was intended as long as the variable is unsigned. Signed-off-by: Martin Storsjö <martin@martin.st>
* rtpdec: Simplify insertion into the linked list queueMartin Storsjö2013-01-14
| | | | | | | By using a pointer-to-pointer, we avoid having to keep track of the previous packet separately. Signed-off-by: Martin Storsjö <martin@martin.st>
* rtpdec: Remove a woefully misplaced commentMartin Storsjö2013-01-14
| | | | | | | | The code below the comment does not at all relate to statistics, and even if moved to the right place, the comment adds little value. Signed-off-by: Martin Storsjö <martin@martin.st>
* rtmpproto: Fix assignments in if()Michael Niedermayer2013-01-14
| | | | Signed-off-by: Martin Storsjö <martin@martin.st>
* lavf: Fix assignments in if()Michael Niedermayer2013-01-14
| | | | Signed-off-by: Martin Storsjö <martin@martin.st>
* rtpdec: Send a valid "delay since SR" value in the RTCP RR packetsMartin Storsjö2013-01-12
| | | | | | | | | | | Previously, we always signalled a zero time since the last RTCP SR, which is dubious. The code also suggested that this would be the difference in RTP NTP time units (32.32 fixed point), while it actually is in in 1/65536 second units. (RFC 3550 section 6.4.1) Signed-off-by: Martin Storsjö <martin@martin.st>
* rtpdec: Calculate and report packet reception jitterMartin Storsjö2013-01-12
| | | | | | | | | This brings back some code that was added originally in 4a6cc061 but never was used, and was removed as unused in 4cc843fa. The code is updated to actually work and is tested to return sane values. Signed-off-by: Martin Storsjö <martin@martin.st>
* rtpdec: Fix the calculation of expected number of packetsMartin Storsjö2013-01-12
| | | | | | | | | The base_seq variable is set to first_seq - 1 (in rtp_init_sequence), so no + 1 is needed here. This avoids reporting 1 lost packet from the start. Signed-off-by: Martin Storsjö <martin@martin.st>
* rtpdec: Remove a useless todo commentMartin Storsjö2013-01-12
| | | | | | | | | The question can be answered: No, we do not know the initial sequence number from the SDP. In certain cases, it can be known from the RTP-Info response header in RTSP though. (In that case, we use it as timestamp origin, but not for rtp receiver statistics.) Signed-off-by: Martin Storsjö <martin@martin.st>
* rtsp: Remove an outdated commentMartin Storsjö2013-01-12
| | | | | | | | It is unclear what the bug exactly was and if it ever was fixed, and we don't even support decoding via faad any longer. The comment has been present since d0deedcb in 2006. Signed-off-by: Martin Storsjö <martin@martin.st>
* rtsp: Remove references to weirdly named variables in other filesMartin Storsjö2013-01-12
| | | | | | | | One of them is renamed now, but mentioning it by name serves no purpose here. The other table mentioned ceased to exist under that name in 4934884a1 in 2006. Signed-off-by: Martin Storsjö <martin@martin.st>
* rtp: Rename a static variable to normal naming conventionsMartin Storsjö2013-01-12
| | | | Signed-off-by: Martin Storsjö <martin@martin.st>
* rtp: Cosmetic cleanupMartin Storsjö2013-01-12
| | | | | | | Remove leftover debug comments, fix brace placement and add whitespace, remove unnecessary and weirdly placed braces. Signed-off-by: Martin Storsjö <martin@martin.st>
* matroska: Fix use after freeDale Curtis2013-01-11
| | | | | Signed-off-by: Dale Curtis <dalecurtis@chromium.org> Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
* rtpdec_vp8: Don't trim too much data from broken framesMartin Storsjö2013-01-10
| | | | | | | | | | | | | Previously, for broken frames, we only returned the first partition of the frame (we would append all the received packets to the packet buffer, then set pkt->size to the size of the first partition, since the rest of the frame could have lost data inbetween) - now instead return the full buffered data we have, but don't append anything more to the buffer after the lost packet discontinuity. Decoding the truncated packet should hopefully get better quality than trimming out everything after the first partition. Signed-off-by: Martin Storsjö <martin@martin.st>
* rtpdec_vp8: Simplify code by using an existing helper functionMartin Storsjö2013-01-10
| | | | Signed-off-by: Martin Storsjö <martin@martin.st>
* rtpdec: Add a terminating null byte at the end of the SDES/CNAMEMartin Storsjö2013-01-10
| | | | | | | | | | | | | | | | This is required by RFC 3550 (section 6.5): The list of items in each chunk MUST be terminated by one or more null octets, the first of which is interpreted as an item type of zero to denote the end of the list. This was implicitly added as padding before, unless the host name length matched up so no padding was added. This makes wireshark parse the packets properly if other RTCP items are appended to the same packet. Signed-off-by: Martin Storsjö <martin@martin.st>
* yuv4mpeg: do not use deprecated functionsLuca Barbato2013-01-09
| | | | Use the libavutil replacement.
* oggdec: fix faulty cleanup prototypeLuca Barbato2013-01-09
|
* idcin: return 0 from idcin_read_packet() on success.Justin Ruggles2013-01-09
| | | | This matches the AVInputFormat.read_packet() API.
* idcin: better error handlingJustin Ruggles2013-01-09
| | | | | | | | Add some additional checks for EOF and print error messages on an incomplete header or packet. FATE reference updated for id-cin-video due to the demuxer no longer returning a partial video packet at EOF.
* idcin: check for integer overflow when calling av_get_packet()Justin Ruggles2013-01-09
| | | | | chunk_size is unsigned 32-bit, but av_get_packet() takes a signed int as the packet size.
* idcin: allow seeking back to the first packetJustin Ruggles2013-01-09
| | | | | Also, do not allow seek-by-byte, as there is no way to find the next packet boundary.
* idcin: set AV_PKT_FLAG_KEY for video packets with a paletteJustin Ruggles2013-01-09
|
* idcin: set start_time and packet duration instead of manually tracking pts.Justin Ruggles2013-01-09
| | | | Also, use 1 / sample_rate for audio stream time_base.
* idcin: set channel_layoutJustin Ruggles2013-01-09
|
* idcin: fix check for presence of an audio streamJustin Ruggles2013-01-09
|
* idcin: validate header parametersJustin Ruggles2013-01-09
| | | | Avoids using unsupported parameters and signed integer overflows.
* au: remove unnecessary castsJustin Ruggles2013-01-09
|
* au: return AVERROR codes instead of -1Justin Ruggles2013-01-09
|
* au: cosmetics: pretty-print and remove pointless commentsJustin Ruggles2013-01-09
|
* au: use ff_raw_write_packet()Justin Ruggles2013-01-09
|
* au: set stream start time and packet durationsJustin Ruggles2013-01-09
|
* au: use %u when printing id and channels since they are unsignedJustin Ruggles2013-01-09
|
* au: validate sample rateJustin Ruggles2013-01-09
|
* au: move skipping of unused data to before parameter validationJustin Ruggles2013-01-09
| | | | Also do not unnecessarily skip 0 bytes.
* au: do not arbitrarily limit channel countJustin Ruggles2013-01-09
| | | | | Nothing in the AU specification sets a limit on channel count. We only need to avoid an overflow in the packet size calculation.
* au: do not set pkt->size directlyJustin Ruggles2013-01-09
| | | | It is already set by av_get_packet() even for partial reads.
* au: set block_align and use it in au_read_packet()Justin Ruggles2013-01-09
|
* au: set bit rateJustin Ruggles2013-01-09
|
* au: validate bits-per-sample separately from codec tagJustin Ruggles2013-01-09
|
* rtpdec_vp8: Mark broken packets with AV_PKT_FLAG_CORRUPTMartin Storsjö2013-01-09
| | | | | | | | This allows the caller to either include them (and get more packets decoded, but possibly some nonperfect frames), or discard them (by setting fflags=discardcorrupt). Signed-off-by: Martin Storsjö <martin@martin.st>