Martin Storsjö [Thu, 12 Jan 2017 14:52:33 +0000 (16:52 +0200)]
arm/aarch64: vp9lpf: Calculate !hev directly
Previously we first calculated hev, and then negated it.
Since we were able to schedule the negation in the middle
of another calculation, we don't see any gain in all cases.
Before: Cortex A7 A8 A9 A53 A53/AArch64
vp9_loop_filter_v_4_8_neon: 147.0 129.0 115.8 89.0 88.7
vp9_loop_filter_v_8_8_neon: 242.0 198.5 174.7 140.0 136.7
vp9_loop_filter_v_16_8_neon: 500.0 419.5 382.7 293.0 275.7
vp9_loop_filter_v_16_16_neon: 971.2 825.5 731.5 579.0 453.0
After:
vp9_loop_filter_v_4_8_neon: 143.0 127.7 114.8 88.0 87.7
vp9_loop_filter_v_8_8_neon: 241.0 197.2 173.7 140.0 136.7
vp9_loop_filter_v_16_8_neon: 497.0 419.5 379.7 293.0 275.7
vp9_loop_filter_v_16_16_neon: 965.2 818.7 731.4 579.0 452.0
Signed-off-by: Martin Storsjö <martin@martin.st>
Martin Storsjö [Wed, 4 Jan 2017 10:57:56 +0000 (12:57 +0200)]
aarch64: vp9itxfm: Optimize 16x16 and 32x32 idct dc by unrolling
This work is sponsored by, and copyright, Google.
Before: Cortex A53
vp9_inv_dct_dct_16x16_sub1_add_neon: 235.3
vp9_inv_dct_dct_32x32_sub1_add_neon: 555.1
After:
vp9_inv_dct_dct_16x16_sub1_add_neon: 180.2
vp9_inv_dct_dct_32x32_sub1_add_neon: 475.3
Signed-off-by: Martin Storsjö <martin@martin.st>
Martin Storsjö [Wed, 4 Jan 2017 11:08:51 +0000 (13:08 +0200)]
arm: vp9itxfm: Optimize 16x16 and 32x32 idct dc by unrolling
This work is sponsored by, and copyright, Google.
Before: Cortex A7 A8 A9 A53
vp9_inv_dct_dct_16x16_sub1_add_neon: 273.0 189.5 211.7 235.8
vp9_inv_dct_dct_32x32_sub1_add_neon: 752.0 459.2 862.2 553.9
After:
vp9_inv_dct_dct_16x16_sub1_add_neon: 226.5 145.0 225.1 171.8
vp9_inv_dct_dct_32x32_sub1_add_neon: 721.2 415.7 727.6 475.0
Signed-off-by: Martin Storsjö <martin@martin.st>
Martin Storsjö [Sat, 17 Dec 2016 11:14:38 +0000 (13:14 +0200)]
aarch64: vp9mc: Calculate less unused data in the 4 pixel wide horizontal filter
No measured speedup on a Cortex A53, but other cores might benefit.
Signed-off-by: Martin Storsjö <martin@martin.st>
Martin Storsjö [Sat, 17 Dec 2016 11:09:50 +0000 (13:09 +0200)]
arm: vp9mc: Calculate less unused data in the 4 pixel wide horizontal filter
Before: Cortex A7 A8 A9 A53
vp9_put_8tap_smooth_4h_neon: 378.1 273.2 340.7 229.5
After:
vp9_put_8tap_smooth_4h_neon: 352.1 222.2 290.5 229.5
Signed-off-by: Martin Storsjö <martin@martin.st>
Martin Storsjö [Fri, 16 Dec 2016 22:55:41 +0000 (00:55 +0200)]
aarch64: vp9mc: Simplify the extmla macro parameters
Fold the field lengths into the macro.
This makes the macro invocations much more readable, when the
lines are shorter.
This also makes it easier to use only half the registers within
the macro.
Signed-off-by: Martin Storsjö <martin@martin.st>
Vittorio Giovara [Fri, 3 Feb 2017 12:05:27 +0000 (13:05 +0100)]
mov: Rework stsc index validation
In order to avoid potential integer overflow change the comparison
and make sure to use the same unsigned type for both elements.
Vittorio Giovara [Tue, 7 Feb 2017 15:01:41 +0000 (10:01 -0500)]
imgutils: Document av_image_get_buffer_size()
Luca Barbato [Thu, 9 Feb 2017 22:27:41 +0000 (23:27 +0100)]
hlsenc: Correctly write down all 16 bytes in hex
Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
Martin Storsjö [Fri, 10 Feb 2017 07:20:39 +0000 (09:20 +0200)]
utvideodec: Add a missing include
This was missing from
77c23704c76, fixing building.
Signed-off-by: Martin Storsjö <martin@martin.st>
Timo Rothenpieler [Tue, 7 Feb 2017 02:04:39 +0000 (18:04 -0800)]
nvenc: make gpu indices independent of supported capabilities
Do not allocate a CUDA context for every available gpu.
Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
Derek Buitenhuis [Wed, 8 Feb 2017 14:42:16 +0000 (14:42 +0000)]
avcodec: Mark some codecs with threadsafe init as such
Signed-off-by: Derek Buitenhuis <derek.buitenhuis@gmail.com>
Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
Martin Storsjö [Tue, 3 Jan 2017 14:11:56 +0000 (16:11 +0200)]
aarch64: vp9itxfm: Fix incorrect vertical alignment
Signed-off-by: Martin Storsjö <martin@martin.st>
Martin Storsjö [Tue, 3 Jan 2017 21:11:51 +0000 (23:11 +0200)]
aarch64: vp9itxfm: Update a comment to refer to a register with a different name
Signed-off-by: Martin Storsjö <martin@martin.st>
Martin Storsjö [Tue, 3 Jan 2017 14:46:17 +0000 (16:46 +0200)]
aarch64: vp9itxfm: Use the right lane sizes in 8x8 for improved readability
Signed-off-by: Martin Storsjö <martin@martin.st>
Martin Storsjö [Tue, 3 Jan 2017 12:55:46 +0000 (14:55 +0200)]
aarch64: vp9itxfm: Use a single lane ld1 instead of ld1r where possible
The ld1r is a leftover from the arm version, where this trick is
beneficial on some cores.
Use a single-lane load where we don't need the semantics of ld1r.
Signed-off-by: Martin Storsjö <martin@martin.st>
Martin Storsjö [Tue, 3 Jan 2017 14:39:41 +0000 (16:39 +0200)]
aarch64: vp9itxfm: Share instructions for loading idct coeffs in the 8x8 function
Signed-off-by: Martin Storsjö <martin@martin.st>
Martin Storsjö [Tue, 3 Jan 2017 14:38:56 +0000 (16:38 +0200)]
arm: vp9itxfm: Share instructions for loading idct coeffs in the 8x8 function
Signed-off-by: Martin Storsjö <martin@martin.st>
Martin Storsjö [Tue, 22 Nov 2016 20:58:35 +0000 (22:58 +0200)]
aarch64: vp9itxfm: Do separate functions for half/quarter idct16 and idct32
This work is sponsored by, and copyright, Google.
This avoids loading and calculating coefficients that we know will
be zero, and avoids filling the temp buffer with zeros in places
where we know the second pass won't read.
This gives a pretty substantial speedup for the smaller subpartitions.
The code size increases from 14740 bytes to 24292 bytes.
The idct16/32_end macros are moved above the individual functions; the
instructions themselves are unchanged, but since new functions are added
at the same place where the code is moved from, the diff looks rather
messy.
Before:
vp9_inv_dct_dct_16x16_sub1_add_neon: 236.7
vp9_inv_dct_dct_16x16_sub2_add_neon: 1051.0
vp9_inv_dct_dct_16x16_sub4_add_neon: 1051.0
vp9_inv_dct_dct_16x16_sub8_add_neon: 1051.0
vp9_inv_dct_dct_16x16_sub12_add_neon: 1387.4
vp9_inv_dct_dct_16x16_sub16_add_neon: 1387.6
vp9_inv_dct_dct_32x32_sub1_add_neon: 554.1
vp9_inv_dct_dct_32x32_sub2_add_neon: 5198.5
vp9_inv_dct_dct_32x32_sub4_add_neon: 5198.6
vp9_inv_dct_dct_32x32_sub8_add_neon: 5196.3
vp9_inv_dct_dct_32x32_sub12_add_neon: 6183.4
vp9_inv_dct_dct_32x32_sub16_add_neon: 6174.3
vp9_inv_dct_dct_32x32_sub20_add_neon: 7151.4
vp9_inv_dct_dct_32x32_sub24_add_neon: 7145.3
vp9_inv_dct_dct_32x32_sub28_add_neon: 8119.3
vp9_inv_dct_dct_32x32_sub32_add_neon: 8118.7
After:
vp9_inv_dct_dct_16x16_sub1_add_neon: 236.7
vp9_inv_dct_dct_16x16_sub2_add_neon: 640.8
vp9_inv_dct_dct_16x16_sub4_add_neon: 639.0
vp9_inv_dct_dct_16x16_sub8_add_neon: 842.0
vp9_inv_dct_dct_16x16_sub12_add_neon: 1388.3
vp9_inv_dct_dct_16x16_sub16_add_neon: 1389.3
vp9_inv_dct_dct_32x32_sub1_add_neon: 554.1
vp9_inv_dct_dct_32x32_sub2_add_neon: 3685.5
vp9_inv_dct_dct_32x32_sub4_add_neon: 3685.1
vp9_inv_dct_dct_32x32_sub8_add_neon: 3684.4
vp9_inv_dct_dct_32x32_sub12_add_neon: 5312.2
vp9_inv_dct_dct_32x32_sub16_add_neon: 5315.4
vp9_inv_dct_dct_32x32_sub20_add_neon: 7154.9
vp9_inv_dct_dct_32x32_sub24_add_neon: 7154.5
vp9_inv_dct_dct_32x32_sub28_add_neon: 8126.6
vp9_inv_dct_dct_32x32_sub32_add_neon: 8127.2
Signed-off-by: Martin Storsjö <martin@martin.st>
Martin Storsjö [Tue, 22 Nov 2016 09:07:38 +0000 (11:07 +0200)]
arm: vp9itxfm: Do a simpler half/quarter idct16/idct32 when possible
This work is sponsored by, and copyright, Google.
This avoids loading and calculating coefficients that we know will
be zero, and avoids filling the temp buffer with zeros in places
where we know the second pass won't read.
This gives a pretty substantial speedup for the smaller subpartitions.
The code size increases from 12388 bytes to 19784 bytes.
The idct16/32_end macros are moved above the individual functions; the
instructions themselves are unchanged, but since new functions are added
at the same place where the code is moved from, the diff looks rather
messy.
Before: Cortex A7 A8 A9 A53
vp9_inv_dct_dct_16x16_sub1_add_neon: 273.0 189.5 212.0 235.8
vp9_inv_dct_dct_16x16_sub2_add_neon: 2102.1 1521.7 1736.2 1265.8
vp9_inv_dct_dct_16x16_sub4_add_neon: 2104.5 1533.0 1736.6 1265.5
vp9_inv_dct_dct_16x16_sub8_add_neon: 2484.8 1828.7 2014.4 1506.5
vp9_inv_dct_dct_16x16_sub12_add_neon: 2851.2 2117.8 2294.8 1753.2
vp9_inv_dct_dct_16x16_sub16_add_neon: 3239.4 2408.3 2543.5 1994.9
vp9_inv_dct_dct_32x32_sub1_add_neon: 758.3 456.7 864.5 553.9
vp9_inv_dct_dct_32x32_sub2_add_neon: 10776.7 7949.8 8567.7 6819.7
vp9_inv_dct_dct_32x32_sub4_add_neon: 10865.6 8131.5 8589.6 6816.3
vp9_inv_dct_dct_32x32_sub8_add_neon: 12053.9 9271.3 9387.7 7564.0
vp9_inv_dct_dct_32x32_sub12_add_neon: 13328.3 10463.2 10217.0 8321.3
vp9_inv_dct_dct_32x32_sub16_add_neon: 14176.4 11509.5 11018.7 9062.3
vp9_inv_dct_dct_32x32_sub20_add_neon: 15301.5 12999.9 11855.1 9828.2
vp9_inv_dct_dct_32x32_sub24_add_neon: 16482.7 14931.5 12650.1 10575.0
vp9_inv_dct_dct_32x32_sub28_add_neon: 17589.5 15811.9 13482.8 11333.4
vp9_inv_dct_dct_32x32_sub32_add_neon: 18696.2 17049.2 14355.6 12089.7
After:
vp9_inv_dct_dct_16x16_sub1_add_neon: 273.0 189.5 211.7 235.8
vp9_inv_dct_dct_16x16_sub2_add_neon: 1203.5 998.2 1035.3 763.0
vp9_inv_dct_dct_16x16_sub4_add_neon: 1203.5 998.1 1035.5 760.8
vp9_inv_dct_dct_16x16_sub8_add_neon: 1926.1 1610.6 1722.1 1271.7
vp9_inv_dct_dct_16x16_sub12_add_neon: 2873.2 2129.7 2285.1 1757.3
vp9_inv_dct_dct_16x16_sub16_add_neon: 3221.4 2520.3 2557.6 2002.1
vp9_inv_dct_dct_32x32_sub1_add_neon: 753.0 457.5 866.6 554.6
vp9_inv_dct_dct_32x32_sub2_add_neon: 7554.6 5652.4 6048.4 4920.2
vp9_inv_dct_dct_32x32_sub4_add_neon: 7549.9 5685.0 6046.9 4925.7
vp9_inv_dct_dct_32x32_sub8_add_neon: 8336.9 6704.5 6604.0 5478.0
vp9_inv_dct_dct_32x32_sub12_add_neon: 10914.0 9777.2 9240.4 7416.9
vp9_inv_dct_dct_32x32_sub16_add_neon: 11859.2 11223.3 9966.3 8095.1
vp9_inv_dct_dct_32x32_sub20_add_neon: 15237.1 13029.4 11838.3 9829.4
vp9_inv_dct_dct_32x32_sub24_add_neon: 16293.2 14379.8 12644.9 10572.0
vp9_inv_dct_dct_32x32_sub28_add_neon: 17424.3 15734.7 13473.0 11326.9
vp9_inv_dct_dct_32x32_sub32_add_neon: 18531.3 17457.0 14298.6 12080.0
Signed-off-by: Martin Storsjö <martin@martin.st>
Martin Storsjö [Sun, 5 Feb 2017 20:53:55 +0000 (22:53 +0200)]
aarch64: vp9itxfm: Move the load_add_store macro out from the itxfm16 pass2 function
This allows reusing the macro for a separate implementation of the
pass2 function.
Signed-off-by: Martin Storsjö <martin@martin.st>
Martin Storsjö [Sun, 5 Feb 2017 20:55:20 +0000 (22:55 +0200)]
arm: vp9itxfm: Move the load_add_store macro out from the itxfm16 pass2 function
This allows reusing the macro for a separate implementation of the
pass2 function.
Signed-off-by: Martin Storsjö <martin@martin.st>
Martin Storsjö [Wed, 23 Nov 2016 12:03:05 +0000 (14:03 +0200)]
aarch64: vp9itxfm: Make the larger core transforms standalone functions
This work is sponsored by, and copyright, Google.
This reduces the code size of libavcodec/aarch64/vp9itxfm_neon.o from
19496 to 14740 bytes.
This gives a small slowdown of a couple of tens of cycles, but makes
it more feasible to add more optimized versions of these transforms.
Before:
vp9_inv_dct_dct_16x16_sub4_add_neon: 1036.7
vp9_inv_dct_dct_16x16_sub16_add_neon: 1372.2
vp9_inv_dct_dct_32x32_sub4_add_neon: 5180.0
vp9_inv_dct_dct_32x32_sub32_add_neon: 8095.7
After:
vp9_inv_dct_dct_16x16_sub4_add_neon: 1051.0
vp9_inv_dct_dct_16x16_sub16_add_neon: 1390.1
vp9_inv_dct_dct_32x32_sub4_add_neon: 5199.9
vp9_inv_dct_dct_32x32_sub32_add_neon: 8125.8
Signed-off-by: Martin Storsjö <martin@martin.st>
Martin Storsjö [Wed, 23 Nov 2016 08:56:12 +0000 (10:56 +0200)]
arm: vp9itxfm: Make the larger core transforms standalone functions
This work is sponsored by, and copyright, Google.
This reduces the code size of libavcodec/arm/vp9itxfm_neon.o from
15324 to 12388 bytes.
This gives a small slowdown of a couple tens of cycles, up to around
150 cycles for the full case of the largest transform, but makes
it more feasible to add more optimized versions of these transforms.
Before: Cortex A7 A8 A9 A53
vp9_inv_dct_dct_16x16_sub4_add_neon: 2063.4 1516.0 1719.5 1245.1
vp9_inv_dct_dct_16x16_sub16_add_neon: 3279.3 2454.5 2525.2 1982.3
vp9_inv_dct_dct_32x32_sub4_add_neon: 10750.0 7955.4 8525.6 6754.2
vp9_inv_dct_dct_32x32_sub32_add_neon: 18574.0 17108.4 14216.7 12010.2
After:
vp9_inv_dct_dct_16x16_sub4_add_neon: 2060.8 1608.5 1735.7 1262.0
vp9_inv_dct_dct_16x16_sub16_add_neon: 3211.2 2443.5 2546.1 1999.5
vp9_inv_dct_dct_32x32_sub4_add_neon: 10682.0 8043.8 8581.3 6810.1
vp9_inv_dct_dct_32x32_sub32_add_neon: 18522.4 17277.4 14286.7 12087.9
Signed-off-by: Martin Storsjö <martin@martin.st>
Diego Biurrun [Wed, 8 Feb 2017 17:06:34 +0000 (18:06 +0100)]
configure: Correctly recurse in do_check_deps()
Fixes all sorts of configuration problems introducec by
dad7a9c7c0ae
on non-Linux or non-vanilla configs. Also removes a line made redundant
in that commit.
Martin Storsjö [Mon, 6 Feb 2017 22:25:19 +0000 (00:25 +0200)]
omx: Use the EOS flag to handle flushing at the end
This avoids having to count the number of frames sent to the codec
and the number of output packets received; instead just wait until
the encoder returns a buffer with the EOS flag set.
Signed-off-by: Martin Storsjö <martin@martin.st>
Diego Biurrun [Fri, 20 Jan 2017 16:17:16 +0000 (17:17 +0100)]
configure: Rework dependency handling for conflicting components
This makes the feature more visible and obvious.
Diego Biurrun [Mon, 23 Jan 2017 10:57:14 +0000 (11:57 +0100)]
configure: Add name parameter to require_pkg_config() helper function
This allows distinguishing between the internal variable name for
external libraries and the pkg-config package name. Having both
names available avoids special-casing outside the helper function
when the two identifiers do not match.
Diego Biurrun [Mon, 6 Jun 2016 11:20:17 +0000 (13:20 +0200)]
Use bitstream_init8() where appropriate
Diego Biurrun [Fri, 20 Jan 2017 14:29:07 +0000 (15:29 +0100)]
configure: Use cppflags check helper functions where appropriate
Diego Biurrun [Fri, 3 Feb 2017 09:15:40 +0000 (10:15 +0100)]
configure: Add stdlib.h #include to CPPFLAGS check helper functions
This ensures that added CPPFLAGS are validated against libc headers.
Alexandra Hájková [Fri, 15 Apr 2016 08:46:06 +0000 (10:46 +0200)]
wma: Convert to the new bitstream reader
Martin Storsjö [Thu, 1 Dec 2016 09:10:19 +0000 (11:10 +0200)]
aarch64: vp9itxfm: Restructure the idct32 store macros
This avoids concatenation, which can't be used if the whole macro
is wrapped within another macro.
This is also arguably more readable.
Signed-off-by: Martin Storsjö <martin@martin.st>
Martin Storsjö [Sat, 4 Feb 2017 20:16:09 +0000 (22:16 +0200)]
arm: vp9itxfm: Avoid .irp when it doesn't save any lines
This makes it more readable.
Signed-off-by: Martin Storsjö <martin@martin.st>
John Stebbins [Thu, 12 Jan 2017 20:36:26 +0000 (13:36 -0700)]
asfdec: Use the ASF stream count when iterating
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>
Diego Biurrun [Wed, 1 Feb 2017 12:27:30 +0000 (13:27 +0100)]
asm: Consistently uppercase SECTION markers
Diego Biurrun [Tue, 31 Jan 2017 14:46:50 +0000 (15:46 +0100)]
build: Ignore generated .version files
Martin Storsjö [Tue, 31 Jan 2017 14:15:56 +0000 (16:15 +0200)]
rtmp: Correctly handle the Window Acknowledgement Size packets
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>
Martin Storsjö [Tue, 31 Jan 2017 13:47:00 +0000 (15:47 +0200)]
rtmp: Rename packet types to closer match the spec
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>
Diego Biurrun [Sun, 22 Jan 2017 15:15:38 +0000 (16:15 +0100)]
configure: Add require_cpp_condition() convenience function
Simplifies checking for conditions in external library headers and
aborting if said conditions are not met.
Diego Biurrun [Sun, 22 Jan 2017 15:04:09 +0000 (16:04 +0100)]
configure: Add require_header() convenience function
Simplifies checking for external library headers and aborting if
the external library support was requested, but is not available.
Diego Biurrun [Sun, 22 Jan 2017 15:05:25 +0000 (16:05 +0100)]
configure: Simplify libxcb check
Alexandra Hájková [Thu, 17 Mar 2016 13:21:24 +0000 (14:21 +0100)]
svq3: Convert to the new bitstream reader
Diego Biurrun [Mon, 23 Jan 2017 12:17:24 +0000 (13:17 +0100)]
configure: Drop weak dependencies on external libraries for webm muxer
Weak dependencies on external libraries do not obviate having to
explicitly enable these libraries, so the weak dependency does not
simplify the configure command line nor have any real effect.
Diego Biurrun [Mon, 23 Jan 2017 16:59:56 +0000 (17:59 +0100)]
configure: Add proper weak dependency of drawtext filter on libfontconfig
Diego Biurrun [Fri, 20 Jan 2017 14:30:36 +0000 (15:30 +0100)]
configure: Simplify inline asm check with appropriate helper function
Diego Biurrun [Fri, 20 Jan 2017 14:29:57 +0000 (15:29 +0100)]
configure: Merge compiler/libc/os hacks sections
wm4 [Mon, 16 Jan 2017 16:32:18 +0000 (17:32 +0100)]
lavc: deprecate refcounted_frames field
No deprecation guards, because the old decode API (for which this field
is needed) doesn't have any either.
This field should be removed together with the old decode calls.
Signed-off-by: Anton Khirnov <anton@khirnov.net>
wm4 [Mon, 16 Jan 2017 15:42:17 +0000 (16:42 +0100)]
hwcontext_cuda: implement frames_get_constraints
Copied and modified from hwcontext_qsv.c.
Signed-off-by: Anton Khirnov <anton@khirnov.net>
Anton Khirnov [Sun, 3 Jul 2016 08:09:36 +0000 (10:09 +0200)]
Mark some arrays that never change as const.
Anton Khirnov [Mon, 30 Jan 2017 20:35:42 +0000 (21:35 +0100)]
avconv: allow -b to be used with streamcopy
In this mode it tells the muxer about the bitrate of the input stream.
Alexandra Hájková [Sat, 19 Mar 2016 16:32:04 +0000 (17:32 +0100)]
ffv1: Convert to the new bitstream reader
Alexandra Hájková [Sun, 10 Apr 2016 09:44:20 +0000 (11:44 +0200)]
h261dec: Convert to the new bitstream reader
Alexandra Hájková [Tue, 22 Mar 2016 15:09:39 +0000 (16:09 +0100)]
shorten: Convert to the new bitstream reader
Alexandra Hájková [Tue, 22 Mar 2016 09:26:03 +0000 (10:26 +0100)]
ralf: Convert to the new bitstream reader
Alexandra Hájková [Mon, 21 Mar 2016 19:23:36 +0000 (20:23 +0100)]
loco: Convert to the new bitstream reader
Alexandra Hájková [Sat, 19 Mar 2016 16:40:55 +0000 (17:40 +0100)]
fic: Convert to the new bitstream reader
Alexandra Hájková [Sat, 19 Mar 2016 14:39:03 +0000 (15:39 +0100)]
dirac: Convert to the new bitstream reader
Alexandra Hájková [Sat, 19 Mar 2016 11:39:03 +0000 (12:39 +0100)]
cavs: Convert to the new bitstream reader
Alexandra Hájková [Sat, 23 Apr 2016 13:19:08 +0000 (15:19 +0200)]
aic: Convert to the new bitstream reader
Diego Biurrun [Mon, 30 Jan 2017 19:24:38 +0000 (20:24 +0100)]
golomb: Convert to the new bitstream reader
Diego Biurrun [Wed, 25 Jan 2017 18:11:24 +0000 (19:11 +0100)]
configure: Add proper weak dependency of avformat on network
Andreas Cadhalpun [Tue, 31 Jan 2017 00:59:38 +0000 (01:59 +0100)]
pgssubdec: reset rle_data_len/rle_remaining_len on allocation error
The code relies on their validity and otherwise can try to access a NULL
object->rle pointer, causing segmentation faults.
Signed-off-by: Andreas Cadhalpun <Andreas.Cadhalpun@googlemail.com>
Signed-off-by: Diego Biurrun <diego@biurrun.de>
Mark Thompson [Sun, 29 Jan 2017 19:45:59 +0000 (19:45 +0000)]
mov: Avoid memcmp of uninitialised data
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.
Mark Thompson [Tue, 29 Nov 2016 20:38:29 +0000 (20:38 +0000)]
vaapi_encode: Add VP8 support
Mark Thompson [Tue, 29 Nov 2016 22:12:46 +0000 (22:12 +0000)]
vaapi_encode: Pass framerate parameters to driver
Only do this when building for a recent VAAPI version - initial
driver implementations were confused about the interpretation of the
framerate field, but hopefully this will be consistent everywhere
once 0.40.0 is released.
Mark Thompson [Sun, 29 Jan 2017 14:12:20 +0000 (14:12 +0000)]
vaapi_h264: Enable VBR mode
Default to using VBR when a target bitrate is set, unless the max rate
is also set and matches the target. Changes to the Intel driver mean
that min_qp is also respected in this case, so set a codec default to
unset the value rather than using the current default inherited from
the MPEG-4 part 2 encoder.
Mark Thompson [Sun, 29 Jan 2017 14:11:03 +0000 (14:11 +0000)]
vaapi_encode: Support VBR mode
This includes a backward-compatibility hack to choose CBR anyway on
old drivers which have no CBR support, so that existing programs will
continue to work their options now map to VBR.
Peter Große [Sun, 29 Jan 2017 14:26:33 +0000 (15:26 +0100)]
doc: add dash muxer
Signed-off-by: Peter Große <pegro@friiks.de>
Signed-off-by: Martin Storsjö <martin@martin.st>
Peter Große [Sun, 29 Jan 2017 14:26:32 +0000 (15:26 +0100)]
dashenc: add webm support
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>
Peter Große [Sun, 29 Jan 2017 14:26:31 +0000 (15:26 +0100)]
dashenc: use avio_dynbuf instead of packet_write callback
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>
Peter Große [Sun, 29 Jan 2017 14:26:30 +0000 (15:26 +0100)]
dashenc: copy language and role metadata from streams assigned to sets
Signed-off-by: Peter Große <pegro@friiks.de>
Signed-off-by: Martin Storsjö <martin@martin.st>
Peter Große [Sun, 29 Jan 2017 14:26:29 +0000 (15:26 +0100)]
dashenc: default to one AdaptationSet per stream
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>
Peter Große [Sun, 29 Jan 2017 14:26:28 +0000 (15:26 +0100)]
dashenc: allow assigning all streams of a media type to an AdaptationSet
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>
Peter Große [Sun, 29 Jan 2017 14:26:27 +0000 (15:26 +0100)]
dashenc: add support for assigning streams to AdaptationSets
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>
Peter Große [Mon, 30 Jan 2017 12:49:44 +0000 (13:49 +0100)]
dashenc: calculate stream bitrate from first segment if not available
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>
Peter Große [Sun, 29 Jan 2017 14:26:25 +0000 (15:26 +0100)]
dashenc: separate segments based on current segment duration
The current implementation creates new segments comparing
pkt->pts - first_pts > nb_segs * min_seg_duration
This works fine, but if the keyframe interval is smaller than "min_seg_duration"
segments shorter than the minimum segment duration are created.
Example: keyint=50, min_seg_duration=
3000000
segment 1 contains keyframe 1 (duration=2s < total_duration=3s)
and keyframe 2 (duration=4s >= total_duration=3s)
segment 2 contains keyframe 3 (duration=6s >= total_duration=6s)
segment 3 contains keyframe 4 (duration=8s < total_duration=9s)
and keyframe 5 (duration=10s >= total_duration=9s)
...
Segment 2 is only 2s long, shorter than min_seg_duration = 3s.
To fix this, new segments are created based on the actual written duration.
Otherwise the option name "min_seg_duration" is misleading.
Signed-off-by: Peter Große <pegro@friiks.de>
Signed-off-by: Martin Storsjö <martin@martin.st>
Peter Große [Sun, 29 Jan 2017 19:41:22 +0000 (20:41 +0100)]
dashenc: add option to provide UTC timing source
If set, adds a UTCTiming tag in the manifest.
This is part of the recommendations listed in the "Guidelines for
Implementations: DASH-IF Interoperability Points" [1][2]
Section 4.7 describes means for the Availability Time Synchronization.
A usable default is "https://time.akamai.com/?iso"
[1] http://dashif.org/guidelines/
[2] http://dashif.org/wp-content/uploads/2016/12/DASH-IF-IOP-v4.0-clean.pdf
(current version as of writing)
Signed-off-by: Peter Große <pegro@friiks.de>
Signed-off-by: Martin Storsjö <martin@martin.st>
Diego Biurrun [Sun, 21 Sep 2014 09:48:21 +0000 (11:48 +0200)]
configure: Clean up temporary files on interrupt
Michał Górny [Sun, 21 Sep 2014 09:38:25 +0000 (11:38 +0200)]
configure: Place all temporary files in one separate directory
Place all temporary files within a single, quasi-atomically created
temporary directory rather than relying on unsafe 'mktemp -u'. This
prevents possible race conditions in case two parallel 'mktemp -u' calls
returned the same path. Additionally, it reduces TMPDIR pollution by
keeping all test files in a single subdirectory.
Signed-off-by: Diego Biurrun <diego@biurrun.de>
Luca Barbato [Wed, 25 Jan 2017 14:59:09 +0000 (15:59 +0100)]
rtmp: Account for bytes_read wraparound
Servers seem to be happy to receive the wrapped-around value as long
as they receive a report, otherwise they timeout.
Initially reported and analyzed by Thomas Bernhard.
Mark Thompson [Mon, 9 Jan 2017 19:17:37 +0000 (19:17 +0000)]
vaapi_encode: Add MPEG-2 support
Anton Schubert [Thu, 26 Jan 2017 23:25:09 +0000 (00:25 +0100)]
dashenc: increase buffer time hint in the manifest
to avoid rebuffering on the clientside for difficult network conditions.
Signed-off-by: Anton Schubert <ischluff@mailbox.org>
Signed-off-by: Martin Storsjö <martin@martin.st>
Peter Große [Thu, 26 Jan 2017 23:25:08 +0000 (00:25 +0100)]
dashenc: add mandatory id to AdaptationSet and Period in manifest
Signed-off-by: Peter Große <pegro@friiks.de>
Signed-off-by: Martin Storsjö <martin@martin.st>
Anton Schubert [Thu, 26 Jan 2017 23:25:07 +0000 (00:25 +0100)]
dashenc: fix ISO8601 UTC parsing
Appends Z to timestamp to force ISO8601 datetime parsing as UTC.
Without Z, some browsers (Chrome) interpret the timestamp as
localtime and others (Firefox) interpret it as UTC.
Signed-off-by: Anton Schubert <ischluff@mailbox.org>
Signed-off-by: Martin Storsjö <martin@martin.st>
Diego Biurrun [Wed, 14 Dec 2016 19:35:18 +0000 (20:35 +0100)]
build: Map -Wall compiler flag to -W3 for MSVC and -Wextra to -W4
These are more appropriate warning level equivalents.
Diego Biurrun [Wed, 25 Jan 2017 17:40:51 +0000 (18:40 +0100)]
build: Detect blocks C language extension and add it as VDA dependency
Newer versions of OS X use the blocks extension in VDA-related headers.
Some compilers, like current gcc, do not support the blocks extension
and fail to compile code using those headers.
Martin Storsjö [Wed, 25 Jan 2017 13:11:23 +0000 (15:11 +0200)]
configure: Add quotes around a variable which might be empty
If we only have a target compiler but no host compiler, the $type
variable will be empty once.
(Currently we fail to do a cross build if no host compiler is available
due to using the host compiler for processing option lists though.
But despite that, this comparison in configure needs quotes.)
Signed-off-by: Martin Storsjö <martin@martin.st>
Luca Barbato [Wed, 25 Jan 2017 23:06:50 +0000 (00:06 +0100)]
fifo: Return the correct AVERROR value
Diego Biurrun [Thu, 19 Jan 2017 10:36:52 +0000 (11:36 +0100)]
configure: Use proper compiler-specific speed flags for hostcc
Diego Biurrun [Thu, 15 Dec 2016 11:20:06 +0000 (12:20 +0100)]
configure: Move optflags checks to a more sensible place
Alexandra Hájková [Wed, 13 Apr 2016 19:00:34 +0000 (21:00 +0200)]
tak: Convert to the new bitstream reader
Diego Biurrun [Tue, 21 Jun 2016 12:35:53 +0000 (14:35 +0200)]
magicyuv: Convert to the new bitstream reader
Diego Biurrun [Tue, 21 Jun 2016 12:39:18 +0000 (14:39 +0200)]
truemotion2rt: Convert to the new bitstream reader
Alexandra Hájková [Fri, 15 Apr 2016 08:45:11 +0000 (10:45 +0200)]
wavpack: Convert to the new bitstream reader
Alexandra Hájková [Mon, 18 Apr 2016 08:56:03 +0000 (10:56 +0200)]
mpc: Convert to the new bitstream reader
Diego Biurrun [Sun, 16 Oct 2016 10:33:45 +0000 (12:33 +0200)]
des-test: Pass the proper types to av_des_*() functions
Fixes a number of incompatible pointer type warnings.
Diego Biurrun [Sun, 6 Dec 2015 11:45:10 +0000 (12:45 +0100)]
swscale-test: const correctness for pointer variable
libswscale/swscale-test.c:369:20: warning: passing argument 2 of ‘sws_scale’ from incompatible pointer type [-Wincompatible-pointer-types]
libswscale/swscale.h:207:5: note: expected ‘const uint8_t * const* {aka const unsigned char * const*}’ but argument is of type ‘uint8_t ** {aka unsigned char **}’
Dave Yeo [Sat, 21 Jan 2017 06:19:56 +0000 (22:19 -0800)]
OS/2: Try to commit memory above 1GB
Signed-off-by: Dave Yeo <dave.r.yeo@gmail.com>
Signed-off-by: Diego Biurrun <diego@biurrun.de>
Alexandra Hájková [Sat, 9 Apr 2016 17:37:46 +0000 (19:37 +0200)]
dxtory: Convert to the new bitstream reader