History

avfilter/vf_pixdesctest: also take into account undefined alpha components

Ensure those bits are copied, which will result in the output being the same as the input, where swscale set them to the equivalent of fully opaque.

James Almer committed 2 years ago

Commit dfd7acf1 parent 8debc5a12 files · +12 −12Browse files

Unified · Split

12 files
  1. libavfilter/vf_pixdesctest.c +1 −1
  2. tests/ref/fate/filter-pixdesc-0bgr +1 −1
  3. tests/ref/fate/filter-pixdesc-0rgb +1 −1
  4. tests/ref/fate/filter-pixdesc-bgr0 +1 −1
  5. tests/ref/fate/filter-pixdesc-rgb0 +1 −1
  6. tests/ref/fate/filter-pixdesc-v30xle +1 −1
  7. tests/ref/fate/filter-pixdesc-vuyx +1 −1
  8. tests/ref/fate/filter-pixdesc-x2bgr10le +1 −1
  9. tests/ref/fate/filter-pixdesc-x2rgb10le +1 −1
  10. tests/ref/fate/filter-pixdesc-xv30le +1 −1
  11. tests/ref/fate/filter-pixdesc-xv36be +1 −1
  12. tests/ref/fate/filter-pixdesc-xv36le +1 −1
libavfilter/vf_pixdesctest.c+1−1
@@ -84,7 +84,7 @@ static int filter_frame(AVFilterLink *inlink, AVFrame *in) · 83 unmodified lines
8484 if (priv->pix_desc->flags & AV_PIX_FMT_FLAG_PAL)
8585 memcpy(out->data[1], in->data[1], AVPALETTE_SIZE);
8686
87− for (c = 0; c < priv->pix_desc->nb_components; c++) {
87+ for (c = 0; c < FF_ARRAY_ELEMS(priv->pix_desc->comp); c++) {
8888 const int w1 = c == 1 || c == 2 ? cw : w;
8989 const int h1 = c == 1 || c == 2 ? ch : h;
9090
tests/ref/fate/filter-pixdesc-0bgr+1−1
@@ -1 +1 @@
1−pixdesc-0bgr 89fa866f5532548a67b6e742b4d49e03
1+pixdesc-0bgr f8b4f2a30d477709e6f414039c8d9602
tests/ref/fate/filter-pixdesc-0rgb+1−1
@@ -1 +1 @@
1−pixdesc-0rgb b181e1d3d4ca1e64d55f434e97c9fdba
1+pixdesc-0rgb f38dad4f69a806881b4cc3f9953e0a15
tests/ref/fate/filter-pixdesc-bgr0+1−1
@@ -1 +1 @@
1−pixdesc-bgr0 5bf31ebb28690035b15eb8252c11b630
1+pixdesc-bgr0 62400c257204fe1ddf61a7bc3a405531
tests/ref/fate/filter-pixdesc-rgb0+1−1
@@ -1 +1 @@
1−pixdesc-rgb0 bd816424fbe4d56b22b5b0f9a238e26e
1+pixdesc-rgb0 eb2182d10f034e3c791598726744f20e
tests/ref/fate/filter-pixdesc-v30xle+1−1
@@ -1 +1 @@
1−pixdesc-v30xle 96e7b6248f347559d40a5154d36083e0
1+pixdesc-v30xle f0f0ee6ff29b97cdd05034a7f7c19cd5
tests/ref/fate/filter-pixdesc-vuyx+1−1
@@ -1 +1 @@
1−pixdesc-vuyx ebc83f9793eb4eddbb0a37fdcb67a33d
1+pixdesc-vuyx a27703ac894af1a90df131dc3c590833
tests/ref/fate/filter-pixdesc-x2bgr10le+1−1
@@ -1 +1 @@
1−pixdesc-x2bgr10le e9d67bd3d8912529148916d78c18c93a
1+pixdesc-x2bgr10le 0ea287ba7ea42330714e7020f2fde7d0
tests/ref/fate/filter-pixdesc-x2rgb10le+1−1
@@ -1 +1 @@
1−pixdesc-x2rgb10le b50c6ddaf37214a06251c29798f94d6d
1+pixdesc-x2rgb10le d34a932222b55f4041742b95837b272e
tests/ref/fate/filter-pixdesc-xv30le+1−1
@@ -1 +1 @@
1−pixdesc-xv30le 701d821940e3f837864393e1c7878843
1+pixdesc-xv30le 4ec53e18ad4e4c188ddc869db5e137a0
tests/ref/fate/filter-pixdesc-xv36be+1−1
@@ -1 +1 @@
1−pixdesc-xv36be 94d17b770b2a519e30952bdeb4e46391
1+pixdesc-xv36be eea153c1e290161700b854b34c02edda
tests/ref/fate/filter-pixdesc-xv36le+1−1
@@ -1 +1 @@
1−pixdesc-xv36le 9d00bb58092f8b6d5d6fd71a8aec719a
1+pixdesc-xv36le 82b19f66b18a2161a5c051066938506e

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t