Commit Graph

64 Commits

Author SHA1 Message Date
Anton Mitrofanov 4815ccadb1 Bump dates to 2024 2024-01-13 14:45:39 +03:00
Anton Mitrofanov 17df75b32e Bump dates to 2023 2023-01-28 16:37:02 +03:00
Anton Mitrofanov ab393c85eb Bump dates to 2022 2022-01-24 19:46:08 +03:00
Ziemowit Zabawa d8debbc6dd Fix typos with codespell tool
This includes fixing convert_method_to_flag so it recognizes "gauss"
parameter properly instead of silently defaulting to bicubic.
2021-09-29 21:11:16 +00:00
Anton Mitrofanov 8e5e8340f0 Bump dates to 2021 2021-01-24 16:38:34 +03:00
Anton Mitrofanov 33f9e14746 Fix warning: comparison of integers of different signs [-Wsign-compare] 2020-04-09 15:36:22 +03:00
Anton Mitrofanov 04e6c65e6b Bump dates to 2020 2020-02-29 22:02:01 +03:00
Anton Mitrofanov 7923c5818b Limit maximum supported resolution
And other resolution dependent buffers checks.
Closes videolan/x264#10.
2019-11-27 02:49:27 +03:00
Henrik Gramner ec1d32302d Bump dates to 2019 2019-03-06 22:45:52 +03:00
Henrik Gramner 6aa4b5929d Eliminate the use of strtok()
Also fix the string parsing in param_apply_tune() to correctly compare
the entire string, not just the first N characters.
2019-03-03 23:52:40 +01:00
Emanuele Ruffaldi 698c5a32e6 4:0:0 (monochrome) encoding support
Virtually zero increase in compression efficiency compared to 4:2:0 with empty
chroma planes. Performance is better though, especially with fast settings.
2018-08-06 23:24:12 +02:00
Henrik Gramner ca5408b13c Bump dates to 2018 2018-01-17 18:31:04 +01:00
Henrik Gramner 1221f09747 filters/resize: Upgrade to a newer libavutil API
Use the AVComponentDescriptor depth field instead of depth_minus1.
2017-12-24 23:47:27 +03:00
Vittorio Giovara 71ed44c731 Unify 8-bit and 10-bit CLI and libraries
Add 'i_bitdepth' to x264_param_t with the corresponding '--output-depth' CLI
option to set the bit depth at runtime.

Drop the 'x264_bit_depth' global variable. Rather than hardcoding it to an
incorrect value, it's preferable to induce a linking failure. If applications
relies on this symbol this will make it more obvious where the problem is.

Add Makefile rules that compiles modules with different bit depths. Assembly
on x86 is prefixed with the 'private_prefix' define, while all other archs
modify their function prefix internally.

Templatize the main C library, x86/x86_64 assembly, ARM assembly, AARCH64
assembly, PowerPC assembly, and MIPS assembly.

The depth and cache CLI filters heavily depend on bit depth size, so they
need to be duplicated for each value. This means having to rename these
filters, and adjust the callers to use the right version.

Unfortunately the threaded input CLI module inherits a common.h dependency
(input/frame -> common/threadpool -> common/frame -> common/common) which
is extremely complicated to address in a sensible way. Instead duplicate
the module and select the appropriate one at run time.

Each bitdepth needs different checkasm compilation rules, so split the main
checkasm target into two executables.
2017-12-24 23:47:24 +03:00
Vittorio Giovara 8f2437d333 Drop the x264 prefix from static functions and variables 2017-12-24 23:11:30 +03:00
Henrik Gramner dcf406978b Support YUYV and UYVY packed 4:2:2 raw input
Packed YUV is arguably more common than planar YUV when dealing with raw
4:2:2 content.

We can utilize the existing plane_copy_deinterleave() functions with some
additional minor constraints (we cannot assume any particular alignment
or overread the input buffer).

Enables assembly optimizations on x86.
2017-05-21 22:41:07 +02:00
Henrik Gramner c7a2e327be Bump dates to 2017 2017-01-21 14:10:37 +01:00
Anton Mitrofanov eaf2fc20c8 Various cosmetics of semicolon use 2016-09-20 21:01:56 +03:00
Henrik Gramner 0082b71719 cli: Refactor filter option parsing
The old code contained a whole bunch of memory leaks, unchecked mallocs,
sections of dead code, etc. and was generally overly complex.

Also consolidate some memory allocations into a single one.
2016-04-12 17:10:29 +02:00
Henrik Gramner d23d186552 Bump dates to 2016 2016-01-17 00:30:13 +01:00
Henrik Gramner 3d972062c8 cli: Use memory-mapped input frames for yuv and y4m
Improves performance by avoiding extraneous memory copying.
Most beneficial on fast settings.

On average around 5-10% faster overall on ultrafast but the
performance improvement can be even larger in some cases.
2016-01-17 00:30:13 +01:00
Anton Mitrofanov fad44d59b3 Fix a few static analyzer performance hints 2015-10-11 18:44:54 +02:00
Yu Xiaolei 627f891c57 NV21 input support
Eliminates an extra copy when encoding Android camera preview images.

Checkasm test by Janne Grunau.
ARM assembly with improvements from Janne Grunau.
2015-07-25 22:52:54 +02:00
Anton Mitrofanov 8e71b432e5 Update configure for auto detection of system libx264 configuration 2015-02-23 20:09:33 +03:00
Anton Mitrofanov d7ccd89f1b Bump dates to 2015 2015-02-23 13:34:44 +03:00
Tristan Matthews 021c0dc6c9 filters: fix sizeof mismatch 2014-08-26 09:19:17 -07:00
Anton Mitrofanov 95beb822e6 Fix memory leak when using select_every filter 2014-08-26 09:19:17 -07:00
James Weaver 41227fa253 v210 input support
Assembly based on code by Henrik Gramner and Loren Merritt.
2014-01-21 13:40:13 -08:00
Henrik Gramner 807aeaaae7 Bump dates to 2014
Also update AUTHORS file and my e-mail address in the headers of various files.
2014-01-08 11:15:45 -08:00
Anton Mitrofanov 05f04384a1 Update to current libav/ffmpeg API 2013-10-25 10:35:35 -07:00
Anton Mitrofanov 50a0c33b9b Fix possible crashes in resize and crop filters with high bitdepth input 2013-10-24 12:15:57 -07:00
Loren Merritt 732b072ae2 Bump dates to 2013 2013-01-08 16:01:32 -08:00
Anton Mitrofanov 7cfe43cc7f Add support for RGB formats in bit-depth conversion filter 2012-05-14 18:53:19 -07:00
Anton Mitrofanov 82d8cdde56 Use TV range algorithm for bit-depth conversions
Such sources are more common, so better to be correct for the common case.
This also produces less error for the case of full range than the previous algorithm produced for the case of TV range.
2012-02-04 07:18:16 -08:00
Hii 27a7b05b83 Bump dates to 2012 2012-02-04 07:18:13 -08:00
Anton Mitrofanov f59b310fd8 Fix normalization of colorspace when input is packed YUV 4:2:2 2012-02-04 07:16:28 -08:00
Steven Walters 3ea6a8b22e Resize filter updates
Use AVPixFmtDescriptors to pick the most compatible x264 csp for any pixel format.
Fix deprecated use of av_set_int.
Now requires libavutil >= 51.19.0
2012-01-15 13:03:54 -08:00
Steven Walters 6767f96783 YUV range detection and support for x264CLI
Two new options: --input-range and --range.
--input-range forces the range of the input in case of misdetection; auto by default.
-- range sets the range of the output; x264cli will convert if necessary, TV by default.
--fullrange is now removed as a CLI option (but the libx264 API is unchanged).
2011-12-01 12:27:47 -08:00
Henrik Gramner 5b0cb86f27 4:2:2 encoding support 2011-09-21 09:54:44 -07:00
Anton Mitrofanov 8b72a9e4c8 Fix intermediate conversion for YUVJ* pixfmts with 4:4:4 encoding 2011-08-24 10:23:00 -07:00
Fiona Glaser 51821635e8 Fix typo in help 2011-08-24 10:22:20 -07:00
Anton Mitrofanov e93cfd6adc Various cosmetics 2011-07-22 04:03:10 -07:00
Anton Mitrofanov 670d818118 Fix spurious "stream properties changed" with --seek option on some inputs 2011-07-18 09:16:35 -07:00
Anton Mitrofanov bb784df93d Fix incorrect chroma swap for some input pixfmts
Problem occurred if pixfmt of lavf/ffms input was PIX_FMT_RGB24 or PIX_FMT_YUV444P.
2011-07-14 16:37:54 -07:00
Anton Mitrofanov ad1c2c8e38 Fix resize filter crash with YUVJ* input pixfmt 2011-07-09 21:15:59 -07:00
Fiona Glaser a93e4c4a75 4:4:4 encoding support 2011-07-09 21:15:52 -07:00
Steven Walters 63eb8bc9b4 Resize filter updates
Fix use of deprecated sws_getContext.
Fix uses of sws_format_name.
Fix stream change warning not occurring on the first resolution change.
Drop cpu detection, as it is now performed internally by swscale.
Update swscale version requirements.
2011-06-14 19:43:13 -07:00
Fiona Glaser d6daf2b914 Cosmetics: fix some signedness issues found by -Wsign-compare 2011-04-12 01:37:26 -07:00
Sean McGovern ee9bc136e9 Bump dates to 2011 2011-01-25 12:16:24 -08:00
Steven Walters 0c4fa824ff Fix broken YV12 handling in the resize filter 2011-01-10 11:38:36 -08:00