diff options
author | Philip Langdale <philipl@overt.org> | 2018-03-02 09:09:05 -0800 |
---|---|---|
committer | Philip Langdale <philipl@overt.org> | 2018-03-03 15:20:19 -0800 |
commit | dd3f1e3a1186ac2cd3d4ce71944626a2c3f200f1 (patch) | |
tree | 051f19362cacb6adc8b2dff6919eb280ac426705 /libswscale/swscale_unscaled.c | |
parent | 1c7f1f38c533382710361ef7e765f1de4f7dfa78 (diff) | |
download | ffmpeg-dd3f1e3a1186ac2cd3d4ce71944626a2c3f200f1.tar.gz |
swscale: Introduce a helper to identify semi-planar formats
This cleans up the ever-more-unreadable list of semi-planar
exclusions for selecting the planar copy wrapper.
Diffstat (limited to 'libswscale/swscale_unscaled.c')
-rw-r--r-- | libswscale/swscale_unscaled.c | 7 |
1 files changed, 1 insertions, 6 deletions
diff --git a/libswscale/swscale_unscaled.c b/libswscale/swscale_unscaled.c index 766c9b4872..13f9cd83e3 100644 --- a/libswscale/swscale_unscaled.c +++ b/libswscale/swscale_unscaled.c @@ -1930,12 +1930,7 @@ void ff_get_unscaled_swscale(SwsContext *c) (isPlanarYUV(srcFormat) && isPlanarYUV(dstFormat) && c->chrDstHSubSample == c->chrSrcHSubSample && c->chrDstVSubSample == c->chrSrcVSubSample && - dstFormat != AV_PIX_FMT_NV12 && dstFormat != AV_PIX_FMT_NV21 && - dstFormat != AV_PIX_FMT_P010LE && dstFormat != AV_PIX_FMT_P010BE && - dstFormat != AV_PIX_FMT_P016LE && dstFormat != AV_PIX_FMT_P016BE && - srcFormat != AV_PIX_FMT_NV12 && srcFormat != AV_PIX_FMT_NV21 && - srcFormat != AV_PIX_FMT_P010LE && srcFormat != AV_PIX_FMT_P010BE && - srcFormat != AV_PIX_FMT_P016LE && srcFormat != AV_PIX_FMT_P016BE)) + !isSemiPlanarYUV(srcFormat) && !isSemiPlanarYUV(dstFormat))) { if (isPacked(c->srcFormat)) c->swscale = packedCopyWrapper; |