summaryrefslogtreecommitdiff
path: root/libavformat
Commit message (Collapse)AuthorAge
...
* | movenc-test: Add tests for negative cts offsetsMartin Storsjö2017-09-28
| | | | | | | | | | Signed-off-by: Martin Storsjö <martin@martin.st> Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
* | movenc: Add an option for enabling negative CTS offsetsMartin Storsjö2017-09-28
| | | | | | | | | | | | | | | | | | | | | | | | | | This reduces the need for an edit list; streams that start with e.g. dts=-1, pts=0 can be encoded as dts=0, pts=0 (which is valid in mov/mp4) by shifting the dts values of all packets forward. This avoids the need for edit lists for such streams (while they still are needed for audio streams with encoder delay). This eases conformance with the DASH-IF interoperability guidelines. Signed-off-by: Martin Storsjö <martin@martin.st> Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
* | Merge commit '0539d84d985e811e5989ef27c13f7e2dda0f9b89'James Almer2017-09-28
|\| | | | | | | | | | | | | | | | | * commit '0539d84d985e811e5989ef27c13f7e2dda0f9b89': asfdec: Account for different Format Data sizes See 76853a3e0ce4d4ef09ffcca7307991b8db832cd4 Merged-by: James Almer <jamrial@gmail.com>
| * asfdec: Account for different Format Data sizesAlexandra Hájková2017-02-15
| | | | | | | | | | | | | | | | | | | | Some muxers may use the BMP_HEADER Format Data size instead of the ASF-specific one. Bug-Id: 1020 CC: libav-stable@libav.org Signed-off-by: Diego Biurrun <diego@biurrun.de>
* | Merge commit 'b446f0e98f85e2e931b476e52b319f1c49244660'James Almer2017-09-28
|\| | | | | | | | | | | | | | | | | * commit 'b446f0e98f85e2e931b476e52b319f1c49244660': mov: Do not try to parse multiple stsd for the same track See 8b43ee4054af799e388d380b379a13a60849c1b5 Merged-by: James Almer <jamrial@gmail.com>
| * mov: Do not try to parse multiple stsd for the same trackLuca Barbato2017-02-15
| | | | | | | | | | | | | | Bug-Id: 1017 CC: libav-stable@libav.org Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
| * Use the new AVIOContext destructor.Anton Khirnov2017-02-11
| |
| * avio: add a destructor for AVIOContextAnton Khirnov2017-02-11
| | | | | | | | | | Before this commit, AVIOContext is to be freed with a plain av_free(), which prevents us from adding any deeper structure to it.
* | Merge commit '53ea595eec984e3109310e8bb7ff4b5786d91057'James Almer2017-09-27
|\| | | | | | | | | | | | | | | | | * commit '53ea595eec984e3109310e8bb7ff4b5786d91057': mov: Rework stsc index validation See e26e6240b6700c5e8c16d0f092f1ad46805a723c. Merged-by: James Almer <jamrial@gmail.com>
| * mov: Rework stsc index validationVittorio Giovara2017-02-10
| | | | | | | | | | In order to avoid potential integer overflow change the comparison and make sure to use the same unsigned type for both elements.
| * hlsenc: Correctly write down all 16 bytes in hexLuca Barbato2017-02-10
| | | | | | | | Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
| * Use bitstream_init8() where appropriateDiego Biurrun2017-02-07
| |
* | Merge commit '8e67039c6312ba520945f2c01b7b14df056d5ed1'James Almer2017-09-26
|\| | | | | | | | | | | | | * commit '8e67039c6312ba520945f2c01b7b14df056d5ed1': asfdec: Use the ASF stream count when iterating Merged-by: James Almer <jamrial@gmail.com>
| * asfdec: Use the ASF stream count when iteratingJohn Stebbins2017-02-04
| | | | | | | | | | | | | | | | | | The AVFormat stream count can be larger due external factors, such as an id3 tag appended. Avoid an out of bound read. Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
* | Merge commit '15a92e0c402c830b607f905d6bf203b6cfb4fa8c'James Almer2017-09-26
|\| | | | | | | | | | | | | * commit '15a92e0c402c830b607f905d6bf203b6cfb4fa8c': rtmp: Correctly handle the Window Acknowledgement Size packets Merged-by: James Almer <jamrial@gmail.com>
| * rtmp: Correctly handle the Window Acknowledgement Size packetsMartin Storsjö2017-02-03
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This swaps which field is set when the Window Acknowledgement Size and Set Peer BW packets are received, renames the fields in order to clarify their role further and adds verbose comments explaining their respective roles and how well the code currently does what it is supposed to. The Set Peer BW packet tells the receiver of the packet (which can be either client or server) that it should not send more data if it already has sent more data than the specified number of bytes, without receiving acknowledgement for them. Actually checking this limit is currently not implemented. In order to be able to check that properly, one can send the Window Acknowledgement Size packet, which tells the receiver of the packet that it needs to send Acknowledgement packets (RTMP_PT_BYTES_READ) at least after receiving a given number of bytes since the last Acknowledgement. Therefore, when we receive a Window Acknowledgement Size packet, this sets the maximum number of bytes we can receive without sending an Acknowledgement; therefore when handling this packet we should set the receive_report_size field (previously client_report_size). Signed-off-by: Martin Storsjö <martin@martin.st>
* | Merge commit 'a1a143adb0fd11c474221431417cff25db7d920f'James Almer2017-09-26
|\| | | | | | | | | | | | | * commit 'a1a143adb0fd11c474221431417cff25db7d920f': rtmp: Rename packet types to closer match the spec Merged-by: James Almer <jamrial@gmail.com>
| * rtmp: Rename packet types to closer match the specMartin Storsjö2017-02-03
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Also rename comments and log messages accordingly, and add clarifying comments for some hardcoded values. The previous names were taken from older, reverse engineered references. These names match the official public rtmp specification, and matches the names used by wirecast in annotating captured streams. These names also avoid hardcoding the roles of server and client, since the handling of them is irrelevant of whether we act as server or client. The RTMP_PT_PING type maps to RTMP_PT_USER_CONTROL. The SERVER_BW and CLIENT_BW types are a bit more intertwined; RTMP_PT_SERVER_BW maps to RTMP_PT_WINDOW_ACK_SIZE and RTMP_PT_CLIENT_BW maps to RTMP_PT_SET_PEER_BW. Signed-off-by: Martin Storsjö <martin@martin.st>
* | Merge commit 'fd9212f2edfe9b107c3c08ba2df5fd2cba5ab9e3'James Almer2017-09-26
|\| | | | | | | | | | | | | * commit 'fd9212f2edfe9b107c3c08ba2df5fd2cba5ab9e3': Mark some arrays that never change as const. Merged-by: James Almer <jamrial@gmail.com>
| * Mark some arrays that never change as const.Anton Khirnov2017-02-01
| |
| * h261dec: Convert to the new bitstream readerAlexandra Hájková2017-01-31
| |
| * golomb: Convert to the new bitstream readerDiego Biurrun2017-01-31
| |
* | Merge commit '708e84cda1bdbffb92847f3d6ccf6fbeb26d9948'James Almer2017-09-26
|\| | | | | | | | | | | | | * commit '708e84cda1bdbffb92847f3d6ccf6fbeb26d9948': mov: Avoid memcmp of uninitialised data Merged-by: James Almer <jamrial@gmail.com>
| * mov: Avoid memcmp of uninitialised dataMark Thompson2017-01-30
| | | | | | | | | | | | | | | | | | The string codec name need not be as long as the value we are comparing it to, so memcmp may make decisions derived from uninitialised data that valgrind then complains about (though the overall result of the function will always be the same). Use strncmp instead, which will stop at the first zero byte and therefore not encounter this issue.
* | Merge commit '7295b7373862ee54903b33d6ef3335531dfa93ad'Rodger Combs2017-09-26
|\| | | | | | | | | | | | | * commit '7295b7373862ee54903b33d6ef3335531dfa93ad': dashenc: add webm support Merged-by: Rodger Combs <rodger.combs@gmail.com>
| * dashenc: add webm supportPeter Große2017-01-31
| | | | | | | | | | | | | | Use webm muxer for VP8, VP9 and Opus codec, mp4 muxer otherwise. Signed-off-by: Peter Große <pegro@friiks.de> Signed-off-by: Martin Storsjö <martin@martin.st>
* | Merge commit '01f1f017d831cf14617aaaeafcec3ae3a81efce7'Rodger Combs2017-09-26
|\| | | | | | | | | | | | | * commit '01f1f017d831cf14617aaaeafcec3ae3a81efce7': dashenc: use avio_dynbuf instead of packet_write callback Merged-by: Rodger Combs <rodger.combs@gmail.com>
| * dashenc: use avio_dynbuf instead of packet_write callbackPeter Große2017-01-31
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The dash_write function drops data, if no IOContext is initialized. Since the mp4 muxer is used in "frag_custom" mode, data is only written when calling av_write_frame(NULL) explicitly and thus there will be no data loss. To add support for webm as subordinate muxer, which doesn't have such a mode, a dynamic buffer is required to provide an always initialized IOContext. Signed-off-by: Peter Große <pegro@friiks.de> Signed-off-by: Martin Storsjö <martin@martin.st>
* | Merge commit 'dce2929efa8e82b0832a828f7e8cb81ff8c20a4e'Rodger Combs2017-09-26
|\| | | | | | | | | | | | | * commit 'dce2929efa8e82b0832a828f7e8cb81ff8c20a4e': dashenc: copy language and role metadata from streams assigned to sets Merged-by: Rodger Combs <rodger.combs@gmail.com>
| * dashenc: copy language and role metadata from streams assigned to setsPeter Große2017-01-31
| | | | | | | | | | Signed-off-by: Peter Große <pegro@friiks.de> Signed-off-by: Martin Storsjö <martin@martin.st>
* | Merge commit 'ca9bc9de690258d4761a19b0df6e9c9113b80115'Rodger Combs2017-09-26
|\| | | | | | | | | | | | | * commit 'ca9bc9de690258d4761a19b0df6e9c9113b80115': dashenc: default to one AdaptationSet per stream Merged-by: Rodger Combs <rodger.combs@gmail.com>
| * dashenc: default to one AdaptationSet per streamPeter Große2017-01-31
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Previously all mapped streams of a media type (video, audio) where assigned to a single AdaptationSet. Using the DASH live profile it is mandatory, that the segments of all representations are aligned, which is currently not enforced. This leads to problems when using video streams with different key frame intervals. So to play safe, default to one AdaptationSet per stream, unless overwritten by explicit assignment. To get the old assignment scheme, use -adaptation_sets "id=0,streams=v id=1,streams=a" Signed-off-by: Peter Große <pegro@friiks.de> Signed-off-by: Martin Storsjö <martin@martin.st>
* | Merge commit 'efd2fc41b3f0749f9715d50b581f22bbaa8c5b99'Rodger Combs2017-09-26
|\| | | | | | | | | | | | | * commit 'efd2fc41b3f0749f9715d50b581f22bbaa8c5b99': dashenc: allow assigning all streams of a media type to an AdaptationSet Merged-by: Rodger Combs <rodger.combs@gmail.com>
| * dashenc: allow assigning all streams of a media type to an AdaptationSetPeter Große2017-01-31
| | | | | | | | | | | | | | | | | | Using the characters "v" or "a" instead of stream index numbers for assigning streams in the adaption_set option, all streams matching that given type will be added to the AdaptationSet. Signed-off-by: Peter Große <pegro@friiks.de> Signed-off-by: Martin Storsjö <martin@martin.st>
* | Merge commit '3d23a5f96ad72961c14ba3a0c2add8f2ab374b61'Rodger Combs2017-09-26
|\| | | | | | | | | | | | | * commit '3d23a5f96ad72961c14ba3a0c2add8f2ab374b61': dashenc: add support for assigning streams to AdaptationSets Merged-by: Rodger Combs <rodger.combs@gmail.com>
| * dashenc: add support for assigning streams to AdaptationSetsPeter Große2017-01-31
| | | | | | | | | | | | | | | | | | Also makes sure all streams are assigned to exactly one AdaptationSet. This patch is originally based partially on code by Vignesh Venkatasubramanian. Signed-off-by: Peter Große <pegro@friiks.de> Signed-off-by: Martin Storsjö <martin@martin.st>
* | Merge commit '9df9309d233f59d9706444a1e24ac24139f2640d'Rodger Combs2017-09-26
|\| | | | | | | | | | | | | * commit '9df9309d233f59d9706444a1e24ac24139f2640d': dashenc: calculate stream bitrate from first segment if not available Merged-by: Rodger Combs <rodger.combs@gmail.com>
| * dashenc: calculate stream bitrate from first segment if not availablePeter Große2017-01-31
| | | | | | | | | | | | | | | | | | Bandwidth information is required in the manifest, but not always provided by the demuxer. In that case calculate the bandwith based on the size and duration of the first segment. Signed-off-by: Peter Große <pegro@friiks.de> Signed-off-by: Martin Storsjö <martin@martin.st>
* | Revert "lavf/dashenc: update bitrates on dash_write_trailer"James Almer2017-09-26
| | | | | | | | | | | | | | | | This reverts commit 89c0fda5f43d8a3d3a1c538ff8d72e6737bc7d8e. A different solution will be committed instead. Signed-off-by: James Almer <jamrial@gmail.com>
* | lavf/tls_gnutls: fix warnings from version checkMoritz Barsnick2017-09-26
| | | | | | | | | | | | | | | | | | | | | | | | | | | | The GnuTLS version is checked through the macro GNUTLS_VERSION_NUMBER, but this wasn't introduced before 2.7.2. Building with older versions of GnuTLS (using icc) warns: src/libavformat/tls_gnutls.c(38): warning #193: zero used for undefined preprocessing identifier "GNUTLS_VERSION_NUMBER" #if HAVE_THREADS && GNUTLS_VERSION_NUMBER <= 0x020b00 This adds a fallback to the older, deprecated LIBGNUTLS_VERSION_NUMBER macro. Signed-off-by: Moritz Barsnick <barsnick@gmx.net>
* | lavf/tls_gnutls: fix compilation with GnuTLS 2.xMoritz Barsnick2017-09-26
| | | | | | | | | | | | | | | | Commit 598e41684066feba701d19ca7443d24b9e5efa77 added use of GNUTLS_E_PREMATURE_TERMINATION, which wasn't introduced to GnuTLS before 2.99.x / 3.x. This fixes compilation with older versions. Signed-off-by: Moritz Barsnick <barsnick@gmx.net>
* | avformat/img2enc: remove av_dup_packet() callJames Almer2017-09-25
| | | | | | | | | | | | It's unnecessary after a call to av_packet_ref(). Signed-off-by: James Almer <jamrial@gmail.com>
* | avformat: replace all uses of av_copy_packet()James Almer2017-09-25
| | | | | | | | Signed-off-by: James Almer <jamrial@gmail.com>
* | libavformat : add mov dataformat tag for HapAlphaOnly and HapQAlphaMartin Vignali2017-09-24
| | | | | | | | Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
* | avformat/libopenmpt: Query duration and metadata after selecting subsongJörn Heusipp2017-09-24
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Duration depends on the selected subsong and thus must be queried after selecting the subsong. There is no compelling reason to query other metadata earlier either. Tested with libopenmpt version: 0.2.8760-beta27 Libopenmpt configure options: --without-ogg --without-vorbis --without-vorbisfile --without-portaudio --without-portaudiocpp --without-mpg123 --without-pulseaudio --without-sndfile --without-flac Signed-off-by: Jörn Heusipp <osmanx@problemloesungsmaschine.de> Signed-off-by: Josh de Kock <josh@itanimul.li>
* | avformat/mpeg: zero initialize idx_pktJames Almer2017-09-23
| | | | | | | | | | | | Prevents use of uninitialized stack. Signed-off-by: James Almer <jamrial@gmail.com>
* | avformat/mxfdec: use the common packet pts setter function for opatom filesMarton Balint2017-09-23
| | | | | | | | | | | | Fixes ticket #6631. Signed-off-by: Marton Balint <cus@passwd.hu>
* | avformat/mxfdec: factorize packet pts setter functionMarton Balint2017-09-23
| | | | | | | | Signed-off-by: Marton Balint <cus@passwd.hu>
* | avformat/gif: use av_packet_alloc()James Almer2017-09-23
| | | | | | | | Signed-off-by: James Almer <jamrial@gmail.com>
* | avformat/apngenc: use av_packet_alloc()James Almer2017-09-23
| | | | | | | | Signed-off-by: James Almer <jamrial@gmail.com>