mirror of https://github.com/FFmpeg/FFmpeg.git
This is mostly straightforward. The major complication is that, as a result of the 16-bit chunk size limitation, ICC profiles may need to be split up into multiple chunks. We also need to make sure to allocate enough extra space in the packet to fit the ICC profile, so modify both mpegvideo_enc.c and ljpegenc.c to take into account this extra overhead, failing cleanly if necessary. Also add a FATE transcode test to ensure that the ICC profile gets written (and read) correctly. Note that this ICC profile is smaller than 64 kB, so this doesn't test the APP2 chunk re-arranging code at all. Signed-off-by: Niklas Haas <git@haasn.dev>release/5.1
parent
4a580975d4
commit
e254af3154
7 changed files with 124 additions and 9 deletions
@ -0,0 +1,42 @@ |
||||
0a323df5cdfb9574e329b9831be054a6 *tests/data/fate/jpg-icc.mjpeg |
||||
11010 tests/data/fate/jpg-icc.mjpeg |
||||
#tb 0: 1/25 |
||||
#media_type 0: video |
||||
#codec_id 0: rawvideo |
||||
#dimensions 0: 128x128 |
||||
#sar 0: 1/1 |
||||
0, 0, 0, 1, 49152, 0xaac06b42 |
||||
[FRAME] |
||||
media_type=video |
||||
stream_index=0 |
||||
key_frame=1 |
||||
pts=0 |
||||
pts_time=0.000000 |
||||
pkt_dts=0 |
||||
pkt_dts_time=0.000000 |
||||
best_effort_timestamp=0 |
||||
best_effort_timestamp_time=0.000000 |
||||
pkt_duration=1 |
||||
pkt_duration_time=0.040000 |
||||
pkt_pos=0 |
||||
pkt_size=11010 |
||||
width=128 |
||||
height=128 |
||||
pix_fmt=yuvj444p |
||||
sample_aspect_ratio=1:1 |
||||
pict_type=I |
||||
coded_picture_number=0 |
||||
display_picture_number=0 |
||||
interlaced_frame=0 |
||||
top_field_first=0 |
||||
repeat_pict=0 |
||||
color_range=pc |
||||
color_space=bt470bg |
||||
color_primaries=unknown |
||||
color_transfer=unknown |
||||
chroma_location=center |
||||
[SIDE_DATA] |
||||
side_data_type=ICC profile |
||||
size=3144 |
||||
[/SIDE_DATA] |
||||
[/FRAME] |
Loading…
Reference in new issue