[FFmpeg-cvslog] tests/fate: add tests for PNG side/meta data
Anton Khirnov
git at videolan.org
Thu Apr 8 12:04:11 EEST 2021
ffmpeg | branch: master | Anton Khirnov <anton at khirnov.net> | Sun Mar 21 11:10:34 2021 +0100| [8e4390de48b22cf6dd2307f0c29a3fef7016ef4c] | committer: Anton Khirnov
tests/fate: add tests for PNG side/meta data
> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=8e4390de48b22cf6dd2307f0c29a3fef7016ef4c
---
tests/fate/image.mak | 8 +++++++
tests/ref/fate/png-frame-metadata | 4 ++++
tests/ref/fate/png-side-data | 46 +++++++++++++++++++++++++++++++++++++++
3 files changed, 58 insertions(+)
diff --git a/tests/fate/image.mak b/tests/fate/image.mak
index eca8d5ab2c..226e190262 100644
--- a/tests/fate/image.mak
+++ b/tests/fate/image.mak
@@ -358,6 +358,14 @@ $(foreach CLSP,$(PNG_COLORSPACES),$(eval $(call FATE_IMGSUITE_PNG,$(CLSP))))
FATE_PNG += fate-png-int-rgb24
fate-png-int-rgb24: CMD = framecrc -i $(TARGET_SAMPLES)/png1/lena-int_rgb24.png -sws_flags +accurate_rnd+bitexact
+FATE_PNG += fate-png-frame-metadata
+fate-png-frame-metadata: CMD = run ffprobe$(PROGSSUF)$(EXESUF) -show_entries frame_tags \
+ -i $(TARGET_SAMPLES)/filter/pixelart0.png
+
+FATE_PNG += fate-png-side-data
+fate-png-side-data: CMD = run ffprobe$(PROGSSUF)$(EXESUF) -show_frames \
+ -i $(TARGET_SAMPLES)/png1/lena-int_rgb24.png
+
FATE_PNG-$(call DEMDEC, IMAGE2, PNG) += $(FATE_PNG)
FATE_IMAGE += $(FATE_PNG-yes)
fate-png: $(FATE_PNG-yes)
diff --git a/tests/ref/fate/png-frame-metadata b/tests/ref/fate/png-frame-metadata
new file mode 100644
index 0000000000..7c6d1916eb
--- /dev/null
+++ b/tests/ref/fate/png-frame-metadata
@@ -0,0 +1,4 @@
+[FRAME]
+TAG:gamma=45455/100000
+TAG:Software=GLDPNG ver 3.4
+[/FRAME]
diff --git a/tests/ref/fate/png-side-data b/tests/ref/fate/png-side-data
new file mode 100644
index 0000000000..c3d1030f96
--- /dev/null
+++ b/tests/ref/fate/png-side-data
@@ -0,0 +1,46 @@
+[FRAME]
+media_type=video
+stream_index=0
+key_frame=1
+pkt_pts=0
+pkt_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=40194
+width=128
+height=128
+pix_fmt=rgb24
+sample_aspect_ratio=1:1
+pict_type=I
+coded_picture_number=0
+display_picture_number=0
+interlaced_frame=1
+top_field_first=0
+repeat_pict=0
+color_range=pc
+color_space=unknown
+color_primaries=unknown
+color_transfer=unknown
+chroma_location=unspecified
+[SIDE_DATA]
+side_data_type=ICC profile
+name=Photoshop ICC profile
+size=3144
+[/SIDE_DATA]
+[SIDE_DATA]
+side_data_type=Mastering display metadata
+red_x=63999/100000
+red_y=33001/100000
+green_x=30000/100000
+green_y=60000/100000
+blue_x=15000/100000
+blue_y=5999/100000
+white_point_x=31269/100000
+white_point_y=32899/100000
+[/SIDE_DATA]
+[/FRAME]
More information about the ffmpeg-cvslog
mailing list