summaryrefslogtreecommitdiff
path: root/libswscale/yuv2rgb.c
Commit message (Collapse)AuthorAge
* swscale/la: Add yuv2rgb_lasx.c and rgb2rgb_lasx.c filesHao Chen2022-09-10
| | | | | | | | | | ffmpeg -i 1_h264_1080p_30fps_3Mbps.mp4 -f rawvideo -pix_fmt rgb24 -y /dev/null -an before: 178fps after: 210fps Signed-off-by: Hao Chen <chenhao@loongson.cn> Reviewed-by: yinshiyou-hf@loongson.cn Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
* all: Replace if (ARCH_FOO) checks by #if ARCH_FOOAndreas Rheinhardt2022-06-15
| | | | | | | | | | | | | | | | | | This is more spec-compliant because it does not rely on dead-code elimination by the compiler. Especially MSVC has problems with this, as can be seen in https://ffmpeg.org/pipermail/ffmpeg-devel/2022-May/296373.html or https://ffmpeg.org/pipermail/ffmpeg-devel/2022-May/297022.html This commit does not eliminate every instance where we rely on dead code elimination: It only tackles branching to the initialization of arch-specific dsp code, not e.g. all uses of CONFIG_ and HAVE_ checks. But maybe it is already enough to compile FFmpeg with MSVC with whole-programm-optimizations enabled (if one does not disable too many components). Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
* swscale/yuv2rgb: Silence a set-but-unused-variable warningAndreas Rheinhardt2021-12-03
| | | | Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
* swscale: add input/output support for X2BGR10LEManuel Stoeckl2021-09-26
| | | | | Signed-off-by: Manuel Stoeckl <code@mstoeckl.com> Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
* swscale/yuv2rgb: fix conversion to X2RGB10Manuel Stoeckl2021-09-26
| | | | | | | | | This resolves a problem where conversions from YUV to X2RGB10LE would produce color values a factor 4 too small, because an 8-bit value was placed in a 10-bit channel. Signed-off-by: Manuel Stoeckl <code@mstoeckl.com> Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
* avutil/internal, swresample/audioconvert: Remove cpu.h inclusionsAndreas Rheinhardt2021-07-22
| | | | | | | | | | These inclusions are not necessary, as cpu.h is already included wherever it is needed (via direct inclusion or via the arch-specific headers). Also remove other unnecessary cpu.h inclusions from ordinary non-headers. Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
* swscale/yuv2rgb: cosmeticsLimin Wang2020-07-25
| | | | | Reviewed-by: Michael Niedermayer <michael@niedermayer.cc> Signed-off-by: Limin Wang <lance.lmwang@gmail.com>
* swscale/yuv2rgb: consider x2rgb10le on big endian hardwareFei Wang2020-07-20
| | | | | | | This fixed FATE fail report by filter-pixfmts* for x2rgb10le on big endian hardware. Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
* swscale: Add swscale input/output support for X2RGB10LEFei Wang2020-06-12
| | | | Signed-off-by: Fei Wang <fei.w.wang@intel.com>
* swscale/yuv2rgb: Fix vertical dither offset with slicesMichael Niedermayer2020-04-12
| | | | Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
* swscale/yuv2rgb: Return a more specific error code from ↵Michael Niedermayer2019-01-01
| | | | | | | ff_yuv2rgb_c_init_tables() Reviewed-by: Paul B Mahol <onemda@gmail.com> Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
* lsws/yuv2rgb: Fix yuva2rgb32 on big endian hardware.Carl Eugen Hoyos2017-10-29
|
* swscale: add bt2020 yuv2rgb coefficients.Ronald S. Bultje2016-04-01
|
* swscale: fix bt709 yuv2rgb coefficients.Ronald S. Bultje2016-04-01
| | | | | They were derived from incorrect values cr=0.2125 (should be cr=0.2126) and cb=0.0721 (should be cb=0.0722).
* sws/yuv2rgb: clarify precision of coeff and offset for mmx codeClément Bœsch2016-02-27
| | | | | It makes easier looking at the difference with the generic code just below.
* sws/yuv2rgb: avoid a few ub on signed left shiftsClément Bœsch2016-02-27
|
* yuv2rgb: Document the color space coefficientsVittorio Giovara2016-01-19
| | | | | | Based on the original documentation found in mpeg2dec (1995). Signed-off-by: Vittorio Giovara <vittorio.giovara@gmail.com>
* swscale/yuv2rgb: Factor YUVRGB_TABLE_LUMA_HEADROOM outMichael Niedermayer2016-01-14
| | | | Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
* swscale/yuv2rgb: Use av_clip_uint8()Michael Niedermayer2015-02-21
| | | | Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
* Merge commit '1dd797e3c9f179f957316a0becbec048b42df8aa'Michael Niedermayer2015-01-06
|\ | | | | | | | | | | | | * commit '1dd797e3c9f179f957316a0becbec048b42df8aa': swscale: check memory allocations Merged-by: Michael Niedermayer <michaelni@gmx.at>
| * swscale: check memory allocationsVittorio Giovara2015-01-05
| | | | | | | | | | CC: libav-stable@libav.org Bug-Id: CID 1257779
* | swscale/yuv2rgb: Fix width % 4 != 0 with bgr4_byte/rgb4_byteMichael Niedermayer2014-12-24
| | | | | | | | Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
* | swscale/yuv2rgb: Fix width % 4 != 0 with bgr4/rgb4Michael Niedermayer2014-12-24
| | | | | | | | Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
* | swscale/yuv2rgb: fix width % 8 != 0 and rgb/bgr8 outputMichael Niedermayer2014-12-24
| | | | | | | | | | | | Fixes Ticket2570 Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
* | Merge commit '880e2aa23645ed9871c66ee1cbd00f93c72d2d73'Michael Niedermayer2014-06-02
|\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * commit '880e2aa23645ed9871c66ee1cbd00f93c72d2d73': Remove all Blackfin architecture optimizations Conflicts: libavcodec/bfin/dsputil.S libavcodec/bfin/dsputil_init.c libavcodec/bfin/fdct_bfin.S libavcodec/bfin/hpel_pixels_no_rnd.S libavcodec/bfin/hpeldsp_init.c libavcodec/bfin/idct_bfin.S libavcodec/bfin/mathops.h libavcodec/bfin/pixels.S libavcodec/bfin/pixels.h libavcodec/bfin/vp3dsp.S libavcodec/bfin/vp3dsp_init.c libavutil/bfin/asm.h libavutil/bfin/attributes.h libswscale/bfin/internal_bfin.S libswscale/bfin/swscale_bfin.c libswscale/bfin/yuv2rgb_bfin.c libswscale/swscale_internal.h libswscale/version.h If someone wants to maintain blackfin support in FFmpeg, please contact ffmpeg-devel@ffmpeg.org Merged-by: Michael Niedermayer <michaelni@gmx.at>
| * Remove all Blackfin architecture optimizationsDiego Biurrun2014-06-02
| | | | | | | | | | | | Blackfin is a painful platform to work with, no test machines are available and the range of multimedia applications is dubious. Thus it only represents a maintenance burden.
* | Merge commit 'b4dd424d96f09f9bafb88e47f37df65dc4529143'Michael Niedermayer2014-03-13
|\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * commit 'b4dd424d96f09f9bafb88e47f37df65dc4529143': Remove all SPARC architecture optimizations Conflicts: Makefile configure libavcodec/sparc/dsputil_vis.c libavcodec/sparc/dsputil_vis.h libavcodec/sparc/hpeldsp_vis.c libavcodec/sparc/simple_idct_vis.c libavcodec/sparc/vis.h libswscale/sparc/yuv2rgb_vis.c libswscale/swscale_internal.h If someone wants to maintain these (or other) SPARC optimizations, please contact me or ffmpeg-devel. I am happy to revert this removial if theres someone considering to maintain this code. Merged-by: Michael Niedermayer <michaelni@gmx.at>
| * Remove all SPARC architecture optimizationsDiego Biurrun2014-03-13
| | | | | | | | | | SPARC is no longer being used in any multimedia-related fields and the VIS optimizations only represent a maintenance burden.
* | swscale/yuv2rgb: clip cy, avoid division by 0 with 0 contrastMichael Niedermayer2013-10-17
| | | | | | | | | | Found-by: durandal_1707 Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
* | swscale/yuv2rgb: make sure yuvTable is set to NULL after deallocationMichael Niedermayer2013-09-16
| | | | | | | | | | | | ensures no stale pointers remain Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
* | Merge remote-tracking branch 'qatar/master'Michael Niedermayer2013-08-29
|\| | | | | | | | | | | | | * qatar/master: cosmetics: Place arch initialization calls in alphabetical order Merged-by: Michael Niedermayer <michaelni@gmx.at>
| * cosmetics: Place arch initialization calls in alphabetical orderDiego Biurrun2013-08-29
| |
* | Merge commit '3aa682f25324d811ec284edc808eb71a46eae950'Michael Niedermayer2013-08-29
|\| | | | | | | | | | | | | * commit '3aa682f25324d811ec284edc808eb71a46eae950': swscale: consistent names for arch-specific acceleration functions Merged-by: Michael Niedermayer <michaelni@gmx.at>
| * swscale: consistent names for arch-specific acceleration functionsDiego Biurrun2013-08-29
| |
* | Merge commit 'c2503d9c8ab42ea55922e9f5a10c8bfbbbfeaf19'Michael Niedermayer2013-08-29
|\| | | | | | | | | | | | | | | | | | | * commit 'c2503d9c8ab42ea55922e9f5a10c8bfbbbfeaf19': swscale: ppc: Hide arch-specific initialization details Conflicts: libswscale/utils.c Merged-by: Michael Niedermayer <michaelni@gmx.at>
| * swscale: ppc: Hide arch-specific initialization detailsDiego Biurrun2013-08-29
| | | | | | | | Also give consistent names to init functions.
* | Merge commit 'a519583991c38d38503ab08357716513facc5725'Michael Niedermayer2013-08-29
|\| | | | | | | | | | | | | | | | | | | | | * commit 'a519583991c38d38503ab08357716513facc5725': swscale: x86: Hide arch-specific initialization details Conflicts: libswscale/x86/Makefile libswscale/x86/swscale.c Merged-by: Michael Niedermayer <michaelni@gmx.at>
| * swscale: x86: Hide arch-specific initialization detailsDiego Biurrun2013-08-28
| | | | | | | | Also give consistent names to init functions.
* | Merge commit 'aa2ba8c99e5708884a56aea9c1d96e014866f8a3'Michael Niedermayer2013-08-16
|\| | | | | | | | | | | | | | | | | | | | | | | | | | | * commit 'aa2ba8c99e5708884a56aea9c1d96e014866f8a3': swscale: Move extern declarations for tables to swscale_internal.h Conflicts: libswscale/output.c libswscale/swscale_internal.h libswscale/swscale_unscaled.c libswscale/utils.c libswscale/yuv2rgb.c Merged-by: Michael Niedermayer <michaelni@gmx.at>
| * swscale: Move extern declarations for tables to swscale_internal.hDiego Biurrun2013-08-15
| | | | | | | | Also add missing ff_ prefixes where necessary.
* | swscale: RGBA64 outputPaul B Mahol2013-05-12
| | | | | | | | | | Signed-off-by: Paul B Mahol <onemda@gmail.com> Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
* | Merge remote-tracking branch 'qatar/master'Michael Niedermayer2013-05-06
|\| | | | | | | | | | | | | * qatar/master: swscale: Use alpha from the right row in yuva2rgba_c Merged-by: Michael Niedermayer <michaelni@gmx.at>
| * swscale: Use alpha from the right row in yuva2rgba_cMartin Storsjö2013-05-06
| | | | | | | | | | | | | | | | | | | | Every other pixel had the alpha channel taken from the wrong row. This fixes bug 504. CC: libav-stable@libav.org Signed-off-by: Martin Storsjö <martin@martin.st>
* | Merge commit '6c5eac9a603a91a707d030d96ba97e2ef6b3ce50'Michael Niedermayer2013-05-06
|\| | | | | | | | | | | | | | | | | | | | | * commit '6c5eac9a603a91a707d030d96ba97e2ef6b3ce50': swscale: Remove unnecessary backslashes jpeg2000: Fix uninitialized data errors pointed out by valgrind/memcheck Conflicts: libavcodec/jpeg2000dec.c Merged-by: Michael Niedermayer <michaelni@gmx.at>
| * swscale: Remove unnecessary backslashesMartin Storsjö2013-05-06
| | | | | | | | Signed-off-by: Martin Storsjö <martin@martin.st>
* | Merge remote-tracking branch 'qatar/master'Michael Niedermayer2013-02-10
|\| | | | | | | | | | | | | | | | | | | * qatar/master: sws: disable yuv2rgb warning for planar rgb. Conflicts: libswscale/yuv2rgb.c Merged-by: Michael Niedermayer <michaelni@gmx.at>
| * sws: disable yuv2rgb warning for planar rgb.Michael Niedermayer2013-02-09
| | | | | | | | | | | | | | planar rgb formats do not use the table Signed-off-by: Michael Niedermayer <michaelni@gmx.at> Signed-off-by: Derek Buitenhuis <derek.buitenhuis@gmail.com>
* | sws: disable yuv2rgb warning for planar rgb.Michael Niedermayer2013-01-26
| | | | | | | | | | | | planar rgb formats do not use the table Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
* | yuv2rgb: fix integer overflow in fill_gv_table()Michael Niedermayer2012-10-24
| | | | | | | | | | Fixes CID703747 Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
* | yuv2rgb: fix integer overflow in fill_tableMichael Niedermayer2012-10-24
| | | | | | | | | | Fixes CID703748 Signed-off-by: Michael Niedermayer <michaelni@gmx.at>