ffmpeg.git
4 years agomovenc: Assume streams starting at pts=0 for discontinuous fragments with editlists
Martin Storsjö [Mon, 5 Jan 2015 13:13:04 +0000 (15:13 +0200)]
movenc: Assume streams starting at pts=0 for discontinuous fragments with editlists

This allows producing fragments discontinously where the video
stream has b-frames (but starts at pts=0), but doesn't work for the
cases with audio with preroll.

Signed-off-by: Martin Storsjö <martin@martin.st>
4 years agomovenc: Add an API unit test for fragmenting options/calls
Martin Storsjö [Thu, 5 Nov 2015 22:12:11 +0000 (00:12 +0200)]
movenc: Add an API unit test for fragmenting options/calls

Contrary to the normal fate tests that run via avconv, this tests
nontrivial call sequences that are only doable via the API
(mainly for different corner cases when using the muxer for
segmenting).

The test muxes fake packet data (with extradata that looks
enough like proper data to make the file be viewable with e.g.
boxdumper) and checks the hash of the produced files. The test also
verifies that fragments produced via different call sequences remain
identical (to avoid e.g. updating the output hashes and suddenly
having fragments that used to be identical suddenly diverging), for
fragments written with frag_discont and/or delay_moov.

Signed-off-by: Martin Storsjö <martin@martin.st>
4 years agomovenc: Automatically flush after writing the initial moov
Martin Storsjö [Fri, 6 Nov 2015 23:18:05 +0000 (01:18 +0200)]
movenc: Automatically flush after writing the initial moov

In most other cases when writing fragmented mp4 files, the output
IO context is flushed after each fragment. Also flush it after
writing the initial moov, to have it behave in the same way.

Signed-off-by: Martin Storsjö <martin@martin.st>
4 years agovsrc_color: implement frame rate
John Stebbins [Tue, 3 Nov 2015 17:57:28 +0000 (09:57 -0800)]
vsrc_color: implement frame rate

Signed-off-by: Anton Khirnov <anton@khirnov.net>
4 years agovf_showinfo: show timebase & framerate too
Michael Niedermayer [Tue, 3 Nov 2015 17:57:27 +0000 (09:57 -0800)]
vf_showinfo: show timebase & framerate too

(cherry picked from ffmpeg commit fdb93996811bacfa7b82995cdc0f93c46f3dc6cc)
Signed-off-by: Anton Khirnov <anton@khirnov.net>
4 years agovf_frei0r: also set AVFilterLink.frame_rate
Michael Niedermayer [Tue, 3 Nov 2015 17:57:26 +0000 (09:57 -0800)]
vf_frei0r: also set AVFilterLink.frame_rate

(cherry picked from ffmpeg commit 353cf95f948ef7c6139c8ead79e9eeb9eb8d2e6e)
Signed-off-by: Anton Khirnov <anton@khirnov.net>
4 years agovf_framepack: Check and update frame_rate
Michael Niedermayer [Tue, 3 Nov 2015 17:57:25 +0000 (09:57 -0800)]
vf_framepack: Check and update frame_rate

(cherry picked from ffmpeg commit a46a23d30fea9c8a5570e07ec4d9c9b4eaa6eb4f)
Signed-off-by: Anton Khirnov <anton@khirnov.net>
4 years agovf_interlace: implement frame rate
Michael Niedermayer [Tue, 3 Nov 2015 17:57:24 +0000 (09:57 -0800)]
vf_interlace: implement frame rate

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
(cherry picked from ffmpeg commit 227b4458fb434875b127a0c2306fa3b899a770bf)
Signed-off-by: Anton Khirnov <anton@khirnov.net>
4 years agosetpts: add FRAME_RATE constant
Stefano Sabatini [Tue, 3 Nov 2015 17:57:23 +0000 (09:57 -0800)]
setpts: add FRAME_RATE constant

Useful for dealing with constant frame-rate video.

(cherry picked from ffmpeg commit 722762f7e1212b4d02142778fabfdd73375722e0)

Signed-off-by: Anton Khirnov <anton@khirnov.net>
4 years agotestsrc: set output framerate
Stefano Sabatini [Tue, 3 Nov 2015 17:57:22 +0000 (09:57 -0800)]
testsrc: set output framerate

(cherry picked from ffmpeg commit 7cd5fa35fecc2717223459d04822faed6bbd40fa)

Signed-off-by: Anton Khirnov <anton@khirnov.net>
4 years agoyadif: update frame rate
Michael Niedermayer [Tue, 3 Nov 2015 17:57:21 +0000 (09:57 -0800)]
yadif: update frame rate

(cherry picked from ffmpeg commit 31619584556466e4beab98e9b04ed4c5ba0db178)
Signed-off-by: Anton Khirnov <anton@khirnov.net>
4 years agovf_fps: set frame_rate.
Nicolas George [Tue, 3 Nov 2015 17:57:20 +0000 (09:57 -0800)]
vf_fps: set frame_rate.

(cherry picked from ffmpeg commit 0d249316043fb69a3972029bff3a2969689ba8b6)

Signed-off-by: Anton Khirnov <anton@khirnov.net>
4 years agobuffersrc: accept the frame rate as argument.
Nicolas George [Tue, 3 Nov 2015 17:57:19 +0000 (09:57 -0800)]
buffersrc: accept the frame rate as argument.

(cherry picked from ffmpeg commit 9ca440679dc535b31edd569393d8d3dda59db90e)

Signed-off-by: Anton Khirnov <anton@khirnov.net>
4 years agolavfi: add a frame_rate field to AVFilterLink.
Nicolas George [Tue, 3 Nov 2015 17:57:17 +0000 (09:57 -0800)]
lavfi: add a frame_rate field to AVFilterLink.

(cherry picked from ffmpeg commit 7b42036b3b23c85f473bf9369e37fa8da22eaf93)

Signed-off-by: Anton Khirnov <anton@khirnov.net>
4 years agoavcodec: fix doxy placement
Anton Khirnov [Fri, 6 Nov 2015 11:27:16 +0000 (12:27 +0100)]
avcodec: fix doxy placement

4 years agolavf: deprecate compute_pkt_fields2
Anton Khirnov [Wed, 7 Oct 2015 13:51:11 +0000 (15:51 +0200)]
lavf: deprecate compute_pkt_fields2

All encoders set pts and dts properly now (and have been doing that for
a while), so there is no good reason to do any timestamp guessing in the
muxer.

The newly added AVStreamInternal will be later used for storing all the
private fields currently living in AVStream.

4 years agolavf: factor out freeing an AVStream
Anton Khirnov [Sun, 20 Jul 2014 08:40:35 +0000 (08:40 +0000)]
lavf: factor out freeing an AVStream

It will be needed in other functions.

4 years agoavconv: set packet duration for CFR video streams
Anton Khirnov [Sun, 11 Oct 2015 10:07:08 +0000 (12:07 +0200)]
avconv: set packet duration for CFR video streams

4 years agolavf: initialize cur_dts to AV_NOPTS_VALUE for muxing
Anton Khirnov [Wed, 7 Oct 2015 09:48:28 +0000 (11:48 +0200)]
lavf: initialize cur_dts to AV_NOPTS_VALUE for muxing

The reasoning for setting it to zero only applies to demuxing.

4 years agolibopenh264enc: Set AVOption data type
Michael Niedermayer [Thu, 5 Nov 2015 11:04:31 +0000 (12:04 +0100)]
libopenh264enc: Set AVOption data type

Signed-off-by: Vittorio Giovara <vittorio.giovara@gmail.com>
4 years agovdpau: Remove a spurious CONFIG_H263_VDPAU_HWACCEL
Michael Niedermayer [Thu, 5 Nov 2015 11:04:43 +0000 (12:04 +0100)]
vdpau: Remove a spurious CONFIG_H263_VDPAU_HWACCEL

Fixes libavcodec/vdpau.c:282:5: warning:
    "CONFIG_H263_VDPAU_HWACCEL" is not defined [-Wundef]

Removed in d35d0c723e3c8fc8cde76bf677f67928f5e179a8.

Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
4 years agosegafilm: drop the "song and dance" for cinepak
Michael Niedermayer [Tue, 7 Jan 2014 13:38:49 +0000 (14:38 +0100)]
segafilm: drop the "song and dance" for cinepak

This seems not to do anything any more since a long time, and removing
it avoids using uninitialized memory. Also change the error value
forwarding as done everywhere else.

Partly fixes: msan_uninit-mem_7fb7d24780d0_2744_R03T.CAK
Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
Signed-off-by: Vittorio Giovara <vittorio.giovara@gmail.com>
4 years agosegafilm: set video and audio stream duration
Paul B Mahol [Thu, 5 Nov 2015 11:04:52 +0000 (12:04 +0100)]
segafilm: set video and audio stream duration

Signed-off-by: Vittorio Giovara <vittorio.giovara@gmail.com>
4 years agosegafilm: implement seeking
Paul B Mahol [Thu, 5 Nov 2015 11:04:51 +0000 (12:04 +0100)]
segafilm: implement seeking

Signed-off-by: Vittorio Giovara <vittorio.giovara@gmail.com>
4 years agovf_pad: fix x, y option expression evaluation
John Stebbins [Sun, 25 Oct 2015 18:36:10 +0000 (11:36 -0700)]
vf_pad: fix x, y option expression evaluation

Calculation of x an y based on width and height did not work when
width == 0 or height == 0.  "0" substitutes the input width and
height, but did so too late for x, y expression evaluation.

Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
4 years agoavresample: Document avresample_open() a little better
Luca Barbato [Wed, 4 Nov 2015 08:16:46 +0000 (09:16 +0100)]
avresample: Document avresample_open() a little better

Bug-Id: 911

4 years agomov: detect cover art pictures by content
wm4 [Sat, 31 Oct 2015 13:36:38 +0000 (14:36 +0100)]
mov: detect cover art pictures by content

I've got some m4a samples that had jpeg cover art marked as png. Since
these files were supposedly written by iTunes, and other software can
read it (e.g. clementine does), this should be worked around.

Since png has a very simple to detect header, while it's apparently a
real pain to detect jpeg in the general case, try to detect png and
assume jpeg otherwise. Not bothering with bmp, as I have no test case.

Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
4 years agoflashsv: Initialize the block array
Luca Barbato [Sun, 1 Nov 2015 03:07:48 +0000 (04:07 +0100)]
flashsv: Initialize the block array

Otherwise flashsv2_prime could be fed random data.

Bug-Id: 908
CC: libav-stable@libav.org
Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
4 years agotruemotion2: Fix the buffer check
Luca Barbato [Sun, 1 Nov 2015 03:07:47 +0000 (04:07 +0100)]
truemotion2: Fix the buffer check

The variable skip contains the expected size in bytes.

Bug-Id: 906
CC: libav-stable@libav.org
Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
4 years agomimic: Always return on failure
Luca Barbato [Sun, 1 Nov 2015 03:07:46 +0000 (04:07 +0100)]
mimic: Always return on failure

Bug-Id: 905
CC: libav-stable@libav.org
Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
4 years agomsnwc_tcp: Use the correct return values
Luca Barbato [Sun, 1 Nov 2015 03:07:45 +0000 (04:07 +0100)]
msnwc_tcp: Use the correct return values

Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
4 years agocosmetics: msnwc_tcp: Reformat
Luca Barbato [Sun, 1 Nov 2015 03:07:44 +0000 (04:07 +0100)]
cosmetics: msnwc_tcp: Reformat

Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
4 years agomsnwc_tcp: Correctly report failure
Luca Barbato [Sun, 1 Nov 2015 03:07:43 +0000 (04:07 +0100)]
msnwc_tcp: Correctly report failure

And prevent a memory leak

CC: libav-stable@libav.org
Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
4 years agorpza: Check the blocks left before processing one
Luca Barbato [Sun, 1 Nov 2015 03:07:42 +0000 (04:07 +0100)]
rpza: Check the blocks left before processing one

Bug-Id: 903
CC: libav-stable@libav.org
Reported-By: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
4 years agolagarith: Correctly compute hash_shift
Luca Barbato [Sun, 1 Nov 2015 13:46:17 +0000 (14:46 +0100)]
lagarith: Correctly compute hash_shift

All the values are unsigned.

Bug-Id: 907
CC: libav-stable@libav.org
Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
4 years agonut: Use the correct codec_tag when multiple are available
Luca Barbato [Thu, 3 Sep 2015 15:31:14 +0000 (17:31 +0200)]
nut: Use the correct codec_tag when multiple are available

Some codecs use the codec_tag to signal specific information and
picking the first one would lead to a broken file.

Bug-Id: 883
CC: libav-stable@libav.org
Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
4 years agoh264_parser: Rename close() to h264_close()
Diego Biurrun [Sat, 31 Oct 2015 16:21:25 +0000 (17:21 +0100)]
h264_parser: Rename close() to h264_close()

At least on AIX it conflicts with the close() libc function from unistd.h.

4 years agow32pthreads: Map MemoryBarrier to __sync_synchronize on mingw
Martin Storsjö [Wed, 28 Oct 2015 20:20:43 +0000 (22:20 +0200)]
w32pthreads: Map MemoryBarrier to __sync_synchronize on mingw

This fixes building on older mingw (both mingw.org and mingw64;
mingw64 from before May 2011).

Signed-off-by: Martin Storsjö <martin@martin.st>
4 years agoconfigure: Add a SONAME entry for the android target
Luca Barbato [Thu, 29 Oct 2015 13:01:07 +0000 (14:01 +0100)]
configure: Add a SONAME entry for the android target

In order to load libraries in Android they need to be unversioned.
The android target section was derived from the BSD ones, and they
that simply drop the SONAME

Android M requires to have a SONAME entry but unversioned.

4 years agovdpau: remove dysfunctional H.263 support
Rémi Denis-Courmont [Wed, 28 Oct 2015 19:21:51 +0000 (21:21 +0200)]
vdpau: remove dysfunctional H.263 support

The VDPAU API never explicitly supported H.263 in the first place.

Signed-off-by: Vittorio Giovara <vittorio.giovara@gmail.com>
4 years agoomadec: Fix position of opening parenthesis
Vittorio Giovara [Thu, 29 Oct 2015 13:06:06 +0000 (14:06 +0100)]
omadec: Fix position of opening parenthesis

4 years agoh264: Print the complete user message
Vittorio Giovara [Thu, 22 Oct 2015 12:13:29 +0000 (14:13 +0200)]
h264: Print the complete user message

Previously the message was cut off at 256th byte.
This will allow dumping the complete x264 encode info when needed.

Signed-off-by: Vittorio Giovara <vittorio.giovara@gmail.com>
4 years agoh264: Print user data SEI under normal debug verbosity
Vittorio Giovara [Thu, 22 Oct 2015 12:13:28 +0000 (14:13 +0200)]
h264: Print user data SEI under normal debug verbosity

Drop the need of setting -debug bugs since it's not a bug, and the
message is already under a AV_LOG_DEBUG log level. Instead only print
it when there is an actual string in it.

4 years agopng: read and write stereo3d frame side data information
Kirill Gavrilov [Tue, 27 Oct 2015 17:27:03 +0000 (18:27 +0100)]
png: read and write stereo3d frame side data information

Use optional sTER chunk defining side-by-side stereo pair
within "Extensions to the PNG 1.2 Specification", version 1.3.0.

Signed-off-by: Vittorio Giovara <vittorio.giovara@gmail.com>
4 years agoos_support: Don't try to return the service name as a string in getnameinfo
Martin Storsjö [Wed, 28 Oct 2015 20:19:12 +0000 (22:19 +0200)]
os_support: Don't try to return the service name as a string in getnameinfo

Some systems may be lacking getservbyport; the previous ifdef wasn't
quite enough since it still assumed that struct servent was defined,
as pointed out by Clément Gregoire.

Simply remove the possibility to return non-numeric services in
getnameinfo; no caller of getnameinfo within libavformat
currently try to use getnameinfo for retrieving the port number without
NI_NUMERICSERV, and falling back on getservbyport may be non-threadsafe.

Signed-off-by: Martin Storsjö <martin@martin.st>
4 years agoconfigure: Add -D_CRT_NONSTDC_NO_WARNINGS when building with msvc
Martin Storsjö [Wed, 28 Oct 2015 19:41:46 +0000 (21:41 +0200)]
configure: Add -D_CRT_NONSTDC_NO_WARNINGS when building with msvc

This silences warnings like this one:
libavformat/file.c(62) : warning C4996: 'read': The POSIX name for this
item is deprecated. Instead, use the ISO C++ conformant name: _read.
See online help for details.

Signed-off-by: Martin Storsjö <martin@martin.st>
4 years agolibopenh264enc: Count and warn about the number of skipped frames
Martin Storsjö [Wed, 28 Oct 2015 09:12:42 +0000 (11:12 +0200)]
libopenh264enc: Count and warn about the number of skipped frames

Signed-off-by: Martin Storsjö <martin@martin.st>
4 years agolibopenh264enc: Add an option for controlling the frame skipping
Martin Storsjö [Wed, 28 Oct 2015 09:06:36 +0000 (11:06 +0200)]
libopenh264enc: Add an option for controlling the frame skipping

This allows enabling the frame skipping, which is required for the
encoder to properly hit the target bitrate.

Signed-off-by: Martin Storsjö <martin@martin.st>
4 years agoopus: Do not call vector_fmul_scalar on zero samples
Kieran Kunhya [Wed, 28 Oct 2015 16:01:56 +0000 (17:01 +0100)]
opus: Do not call vector_fmul_scalar on zero samples

The x86 variant of this function crashes in that specific case.

CC: libav-devel@libav.org
4 years agoopus: Buffer the samples from the correct offset
Michael Niedermayer [Tue, 27 Oct 2015 12:47:12 +0000 (13:47 +0100)]
opus: Buffer the samples from the correct offset

When not all the opus stream have the same amount of decoded samples
process the least amount and store what is left from the other streams.

Bug-Id: 909
CC: libav-stable@libav.org
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
4 years agoavpicture: Deprecate the single fields
Luca Barbato [Tue, 27 Oct 2015 20:53:26 +0000 (21:53 +0100)]
avpicture: Deprecate the single fields

Silence pointless warnings from gcc.

4 years agoavconv: support infinite loop for the loop option
Alexandra Hájková [Wed, 21 Oct 2015 10:03:58 +0000 (12:03 +0200)]
avconv: support infinite loop for the loop option

Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
4 years agoavpacket: Provide an alloc and a free function for the struct
Luca Barbato [Fri, 23 Oct 2015 09:11:34 +0000 (11:11 +0200)]
avpacket: Provide an alloc and a free function for the struct

Pave the way for having the size of the AVPacket struct not part
of the ABI.

4 years agoavpacket: Deprecate av_dup_packet
Luca Barbato [Fri, 23 Oct 2015 09:11:33 +0000 (11:11 +0200)]
avpacket: Deprecate av_dup_packet

As documented, `av_dup_packet` is broken by design, `av_packet_ref`
matches the AVFrame ref-counted API and can be safely used instead.

4 years agoavformat: Rework add_to_pktbuf
Luca Barbato [Fri, 23 Oct 2015 09:11:32 +0000 (11:11 +0200)]
avformat: Rework add_to_pktbuf

Make it return an error and check its return value when it is used.
Simplify the usage by calling `av_packet_ref` internally when needed.

4 years agoavpacket: Replace av_free_packet with av_packet_unref
Luca Barbato [Fri, 23 Oct 2015 09:11:31 +0000 (11:11 +0200)]
avpacket: Replace av_free_packet with av_packet_unref

`av_packet_unref` matches the AVFrame ref-counted API and can be used as
a drop in replacement.

Deprecate `av_free_packet`.

4 years agoavformat: Always return ref-counted AVPacket
Luca Barbato [Fri, 23 Oct 2015 09:11:30 +0000 (11:11 +0200)]
avformat: Always return ref-counted AVPacket

And drop the av_dup_packet from the input_thread.

4 years agoavprobe: Unref the packet once it is used
Luca Barbato [Fri, 23 Oct 2015 09:11:29 +0000 (11:11 +0200)]
avprobe: Unref the packet once it is used

Make sure it does not leak packets.

CC: libav-stable@libav.org
4 years agoroqvideodec: use av_frame_copy
Hendrik Leppkes [Fri, 23 Oct 2015 13:24:11 +0000 (15:24 +0200)]
roqvideodec: use av_frame_copy

CC: libav-stable@libav.org
Signed-off-by: Vittorio Giovara <vittorio.giovara@gmail.com>
4 years agohap: Set avctx.bits_per_coded_sample
Tom Butterworth [Fri, 23 Oct 2015 12:40:16 +0000 (14:40 +0200)]
hap: Set avctx.bits_per_coded_sample

Fixes an issue where alpha is ignored in some players.

Signed-off-by: Vittorio Giovara <vittorio.giovara@gmail.com>
4 years agocmdutils: Check for and report the correct codec capability
Vittorio Giovara [Mon, 19 Oct 2015 11:57:22 +0000 (13:57 +0200)]
cmdutils: Check for and report the correct codec capability

4 years agoscreenpresso: Drop parameter change check
Vittorio Giovara [Mon, 19 Oct 2015 12:34:09 +0000 (14:34 +0200)]
screenpresso: Drop parameter change check

Size can never change, allowing us to use ff_reget_buffer, and to
simplify the code a little.

4 years agompegvideo_enc: Fix encoding videos with less frames than the delay of the encoder
Alexis Ballier [Fri, 23 Oct 2015 13:23:43 +0000 (15:23 +0200)]
mpegvideo_enc: Fix encoding videos with less frames than the delay of the encoder

When the encoder is fed with less frames than its delay, the picture list
looks like { NULL, NULL, ..., frame, frame, frame }. When flushing the
encoder (input frame == NULL), we need to ensure the picture list is
shifted enough so that we do not return an empty packet, which would
mean the encoder has finished, while it has not encoded any frame.

Signed-off-by: Vittorio Giovara <vittorio.giovara@gmail.com>
4 years agompegvideo_enc: Merge ifs with identical conditions
Michael Niedermayer [Fri, 23 Oct 2015 13:23:42 +0000 (15:23 +0200)]
mpegvideo_enc: Merge ifs with identical conditions

Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
4 years agompegvideo_enc: Factor new_picture unref out
Michael Niedermayer [Fri, 23 Oct 2015 13:23:41 +0000 (15:23 +0200)]
mpegvideo_enc: Factor new_picture unref out

Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
4 years agoinnoHeim/Rsupport Screen Capture Codec decoder
Vittorio Giovara [Mon, 19 Oct 2015 12:23:43 +0000 (14:23 +0200)]
innoHeim/Rsupport Screen Capture Codec decoder

Signed-off-by: Vittorio Giovara <vittorio.giovara@gmail.com>
4 years agokvazaar: Add libkvazaar HEVC encoder
Arttu Ylä-Outinen [Tue, 25 Aug 2015 08:33:19 +0000 (11:33 +0300)]
kvazaar: Add libkvazaar HEVC encoder

Signed-off-by: Arttu Ylä-Outinen <arttu.yla-outinen@tut.fi>
Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
4 years agompjpeg: Cope with multipart lacking the initial CRLF
Luca Barbato [Thu, 22 Oct 2015 03:07:05 +0000 (05:07 +0200)]
mpjpeg: Cope with multipart lacking the initial CRLF

Some server in the wild do not put the boundary at a newline
as rfc1347 7.2.1 states.
Cope with that by reading a line and if it is not empty reading
a second one.

Reported-By: bitingsock
4 years agoimg2enc: Make sure the images are atomically written
Luca Barbato [Tue, 20 Oct 2015 17:49:13 +0000 (19:49 +0200)]
img2enc: Make sure the images are atomically written

Users that want to generate a live-preview and serve it
would otherwise get partial images.

4 years agolibx264: Make sure the extradata are padded
Luca Barbato [Tue, 20 Oct 2015 19:12:30 +0000 (21:12 +0200)]
libx264: Make sure the extradata are padded

4 years agomovenc: Honor flush requests with delay_moov, when some tracks lack samples
Martin Storsjö [Tue, 20 Oct 2015 19:30:03 +0000 (22:30 +0300)]
movenc: Honor flush requests with delay_moov, when some tracks lack samples

This also makes sure that a fragmented file without the empty_moov
flag (i.e. with a non-empty initial moov fragment) actually gets
written, if some of the tracks turn out to not have any samples.

Signed-off-by: Martin Storsjö <martin@martin.st>
4 years agortsp: Allow $ as interleaved packet indicator before a complete response header
Martin Storsjö [Wed, 21 Oct 2015 08:56:36 +0000 (11:56 +0300)]
rtsp: Allow $ as interleaved packet indicator before a complete response header

Some RTSP servers ("HiIpcam/V100R003 VodServer/1.0.0") respond to
our keepalive GET_PARAMETER request by a truncated RTSP header
(lacking the final empty line to indicate a complete response
header). Prior to 764ec70149, this worked just fine since we
reacted to the $ as interleaved packet indicator anywhere.

Since $ is a valid character within the response header lines,
764ec70149 changed it to be ignored there. But to keep
compatibility with such broken servers, we need to at least
allow reacting to it at the start of lines.

Signed-off-by: Martin Storsjö <martin@martin.st>
4 years agolavc: Deprecate AVPicture structure and related functions
Vittorio Giovara [Wed, 14 Oct 2015 09:33:28 +0000 (11:33 +0200)]
lavc: Deprecate AVPicture structure and related functions

This structure served as a bridge between data pointers and frames,
but it suffers from several limitations:
- it is not refcounted and data must be copied to every time
- it cannot be expanded without ABI break due to being used on the stack
- its functions are just wrappers to imgutils which add a layer of
  unneeded indirection, and maintenance burden
- it allows hacks like embedding uncompressed data in packets
- its use is often confusing to our users

AVFrame provides a much better API, and, if a full blown frame is not
needed, it is just as simple and more straightfoward to use data and
linesize arrays directly.

Signed-off-by: Vittorio Giovara <vittorio.giovara@gmail.com>
4 years agoutils: Use data buffers directly instead of an AVPicture
Vittorio Giovara [Wed, 14 Oct 2015 09:33:27 +0000 (11:33 +0200)]
utils: Use data buffers directly instead of an AVPicture

Signed-off-by: Vittorio Giovara <vittorio.giovara@gmail.com>
4 years agoavplay: Replace avpicture functions with imgutils
Vittorio Giovara [Wed, 14 Oct 2015 09:33:26 +0000 (11:33 +0200)]
avplay: Replace avpicture functions with imgutils

Signed-off-by: Vittorio Giovara <vittorio.giovara@gmail.com>
4 years agolavc: Add data and linesize to AVSubtitleRect
Vittorio Giovara [Wed, 14 Oct 2015 09:33:25 +0000 (11:33 +0200)]
lavc: Add data and linesize to AVSubtitleRect

Use the new fields directly instead of the ones from AVPicture.
This removes a layer of indirection which serves no pratical purpose
whatsoever, and will help in removing AVPicture structure completely
later.

Every subtitle encoder/decoder seamlessly points to the new arrays,
so it is possible to deprecate AVSubtitleRect.pict.

Signed-off-by: Vittorio Giovara <vittorio.giovara@gmail.com>
4 years agoReplace any remaining avpicture function with imgutils
Vittorio Giovara [Wed, 14 Oct 2015 09:33:24 +0000 (11:33 +0200)]
Replace any remaining avpicture function with imgutils

avpicture_get_size() -> av_image_get_buffer_size()

Signed-off-by: Vittorio Giovara <vittorio.giovara@gmail.com>
4 years agonuv: Replace avpicture functions with imgutils
Vittorio Giovara [Wed, 14 Oct 2015 09:33:23 +0000 (11:33 +0200)]
nuv: Replace avpicture functions with imgutils

Signed-off-by: Vittorio Giovara <vittorio.giovara@gmail.com>
4 years agodpx: Replace avpicture functions with imgutils
Vittorio Giovara [Wed, 14 Oct 2015 09:33:22 +0000 (11:33 +0200)]
dpx: Replace avpicture functions with imgutils

Signed-off-by: Vittorio Giovara <vittorio.giovara@gmail.com>
4 years agoroqvideodec: Replace avpicture functions with imgutils
Vittorio Giovara [Wed, 14 Oct 2015 09:33:21 +0000 (11:33 +0200)]
roqvideodec: Replace avpicture functions with imgutils

Signed-off-by: Vittorio Giovara <vittorio.giovara@gmail.com>
4 years agorawdec: Replace avpicture functions with imgutils
Luca Barbato [Wed, 14 Oct 2015 09:33:20 +0000 (11:33 +0200)]
rawdec: Replace avpicture functions with imgutils

Signed-off-by: Vittorio Giovara <vittorio.giovara@gmail.com>
4 years agorawenc: Replace avpicture functions with imgutils
Luca Barbato [Wed, 14 Oct 2015 09:33:19 +0000 (11:33 +0200)]
rawenc: Replace avpicture functions with imgutils

Signed-off-by: Vittorio Giovara <vittorio.giovara@gmail.com>
4 years agomsrle: Use AVFrame instead of AVPicture
Vittorio Giovara [Wed, 14 Oct 2015 09:33:18 +0000 (11:33 +0200)]
msrle: Use AVFrame instead of AVPicture

Callers always use a frame and cast it to AVPicture, change
ff_msrle_decode() to accept an AVFrame directly instead.

Signed-off-by: Vittorio Giovara <vittorio.giovara@gmail.com>
4 years agoAPIchanges: Fill in missing dates and hashes
Vittorio Giovara [Wed, 14 Oct 2015 13:17:41 +0000 (15:17 +0200)]
APIchanges: Fill in missing dates and hashes

4 years agoavconv: add support for Intel QSV-accelerated transcoding
Anton Khirnov [Tue, 13 Oct 2015 12:11:35 +0000 (14:11 +0200)]
avconv: add support for Intel QSV-accelerated transcoding

Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
4 years agoqsvenc: add an API for allocating opaque surfaces
Anton Khirnov [Sun, 11 Oct 2015 20:02:26 +0000 (22:02 +0200)]
qsvenc: add an API for allocating opaque surfaces

4 years agoqsvenc: cosmetics, reindent
Anton Khirnov [Thu, 1 Oct 2015 17:42:33 +0000 (19:42 +0200)]
qsvenc: cosmetics, reindent

4 years agoqsvenc: set the timestamp for PIX_FMT_QSV frames as well
Anton Khirnov [Thu, 1 Oct 2015 17:41:56 +0000 (19:41 +0200)]
qsvenc: set the timestamp for PIX_FMT_QSV frames as well

4 years agoqsvenc: support passing arbitrary external buffers to the encoder
Anton Khirnov [Wed, 5 Aug 2015 13:22:34 +0000 (15:22 +0200)]
qsvenc: support passing arbitrary external buffers to the encoder

4 years agow32pthreads: fix mingw build on x86 with -msse2 or higher
Hendrik Leppkes [Wed, 14 Oct 2015 21:18:17 +0000 (23:18 +0200)]
w32pthreads: fix mingw build on x86 with -msse2 or higher

When SSE2 or higher compiler optimizations are used, mingw uses
the _mm_mfence intrinsic for MemoryBarrier, however it doesn't include
the appropriate headers automatically.

Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
4 years agowrapped_avframe: Drop a now-unused variable
Luca Barbato [Fri, 16 Oct 2015 12:45:45 +0000 (14:45 +0200)]
wrapped_avframe: Drop a now-unused variable

4 years agompeg12: Unbreak building stale code
Luca Barbato [Fri, 16 Oct 2015 06:45:04 +0000 (08:45 +0200)]
mpeg12: Unbreak building stale code

Broken in 2d59159508c5c1830cc5da907a9454e229077320

4 years agoaac: Make codec init run under ff_thread_once
Derek Buitenhuis [Wed, 14 Oct 2015 18:24:35 +0000 (14:24 -0400)]
aac: Make codec init run under ff_thread_once

This makes AAC init threadsafe.

Signed-off-by: Derek Buitenhuis <derek.buitenhuis@gmail.com>
4 years agofate: Move screenpresso to the appropriate screen capture file
Vittorio Giovara [Wed, 14 Oct 2015 13:13:11 +0000 (15:13 +0200)]
fate: Move screenpresso to the appropriate screen capture file

4 years agolavc: AV-prefix a few left out capabilities
Vittorio Giovara [Wed, 14 Oct 2015 13:08:49 +0000 (15:08 +0200)]
lavc: AV-prefix a few left out capabilities

4 years agocmdutils: Print general codec capabilities
Vittorio Giovara [Wed, 14 Oct 2015 13:07:10 +0000 (15:07 +0200)]
cmdutils: Print general codec capabilities

4 years agocmdutils: Add auto to threading capabilities report
Vittorio Giovara [Wed, 14 Oct 2015 13:07:09 +0000 (15:07 +0200)]
cmdutils: Add auto to threading capabilities report

And use 'none' when such capabilities are not set.

Signed-off-by: Vittorio Giovara <vittorio.giovara@gmail.com>
4 years agoh264: Run VLC init under pthread_once
Derek Buitenhuis [Wed, 7 Oct 2015 16:33:01 +0000 (12:33 -0400)]
h264: Run VLC init under pthread_once

This makes the h.264 decoder threadsafe to initialize.

Signed-off-by: Derek Buitenhuis <derek.buitenhuis@gmail.com>
Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
4 years agothread: Provide no-op variants for pthread_once
Luca Barbato [Wed, 7 Oct 2015 20:43:38 +0000 (22:43 +0200)]
thread: Provide no-op variants for pthread_once

4 years agodxva: Include last the internal header
Luca Barbato [Tue, 13 Oct 2015 21:20:33 +0000 (23:20 +0200)]
dxva: Include last the internal header

It redefines _WIN32_WINNT, possibly causing problems with the
w32pthreads.h header.