Skip to content

Commit

Permalink
avcodec/proresenc_aw : use AVframe primaries, transfert, colorspace f…
Browse files Browse the repository at this point in the history
…or frame header instead of default (unknown, unknown, Rec601)

avoid color shift, on some decoding software
  • Loading branch information
mvji committed Oct 18, 2018
1 parent d7731ea commit 1a45b12
Show file tree
Hide file tree
Showing 5 changed files with 7 additions and 7 deletions.
6 changes: 3 additions & 3 deletions libavcodec/proresenc_anatoliy.c
Original file line number Diff line number Diff line change
Expand Up @@ -501,9 +501,9 @@ static int prores_encode_frame(AVCodecContext *avctx, AVPacket *pkt,
bytestream_put_be16(&buf, avctx->height);
*buf++ = 0x83; // {10}(422){00}{00}(frame){11}
*buf++ = 0;
*buf++ = 2;
*buf++ = 2;
*buf++ = 6;
*buf++ = pict->color_primaries;
*buf++ = pict->color_trc;
*buf++ = pict->colorspace;
*buf++ = 32;
*buf++ = 0;
*buf++ = 3;
Expand Down
2 changes: 1 addition & 1 deletion tests/ref/vsynth/vsynth1-prores
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
7ca7d2f9f5d8ac2ead691b1b6a70d409 *tests/data/fate/vsynth1-prores.mov
27a1293adf92cc0330652e4e81a9328d *tests/data/fate/vsynth1-prores.mov
5022821 tests/data/fate/vsynth1-prores.mov
fb4a9e025d12afc0dbbca8d82831858f *tests/data/fate/vsynth1-prores.out.rawvideo
stddev: 2.47 PSNR: 40.27 MAXDIFF: 31 bytes: 7603200/ 7603200
2 changes: 1 addition & 1 deletion tests/ref/vsynth/vsynth2-prores
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
aa57fd1221b7eefaf1f34f9d57d6a7cb *tests/data/fate/vsynth2-prores.mov
dc972bd57cec42786abddb79552b2654 *tests/data/fate/vsynth2-prores.mov
3265056 tests/data/fate/vsynth2-prores.mov
537b0ff66d7c8c3c12faa89d042e6a49 *tests/data/fate/vsynth2-prores.out.rawvideo
stddev: 1.38 PSNR: 45.29 MAXDIFF: 12 bytes: 7603200/ 7603200
2 changes: 1 addition & 1 deletion tests/ref/vsynth/vsynth3-prores
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
b060c59be88b4b089ece5ee8dc4f1c58 *tests/data/fate/vsynth3-prores.mov
f41aa3ce23eea73be3e207d5d0f18219 *tests/data/fate/vsynth3-prores.mov
105367 tests/data/fate/vsynth3-prores.mov
fff5e7ad21d78501c8fa4749bf4bf289 *tests/data/fate/vsynth3-prores.out.rawvideo
stddev: 2.80 PSNR: 39.17 MAXDIFF: 27 bytes: 86700/ 86700
2 changes: 1 addition & 1 deletion tests/ref/vsynth/vsynth_lena-prores
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
637f34b5fd81f072f76a967595fa6af7 *tests/data/fate/vsynth_lena-prores.mov
09ef7f879fa65d6626dde9a88f1674c9 *tests/data/fate/vsynth_lena-prores.mov
2844076 tests/data/fate/vsynth_lena-prores.mov
03fd29e3963716a09d232b6f817ecb57 *tests/data/fate/vsynth_lena-prores.out.rawvideo
stddev: 1.31 PSNR: 45.77 MAXDIFF: 11 bytes: 7603200/ 7603200

0 comments on commit 1a45b12

Please sign in to comment.