History

tests/fate: force MPEG range for rawvideo tests

The input file is MPEG range, so we should also encode to MPEG range before comparing against it. This bug was avoided in the past because YUVJ inputs were automatically converted back to limited range when converting to a different pixfmt (in the absence of tagging). However, with proper YUV negotiation in place, the default behavior is to preserve the YUV range wherever possible. Since `rawvideo` does not signal or care about the YUV range, we need to explicitly request the desired output range to force a conversion. Affects all rawvideo tests, in particular vsynth and owdenoise.

Niklas Haas committed 3 years ago

Commit da80ee21 parent 504c1ff3 files · +3 −3Browse files

Unified · Split

3 files
  1. tests/fate-run.sh +1 −1
  2. tests/fate/filter-video.mak +1 −1
  3. tests/fate/vcodec.mak +1 −1
tests/fate-run.sh+1−1
@@ -500,7 +500,7 @@ pixfmt_conversion(){ · 499 unmodified lines
500500 run_avconv $DEC_OPTS -r 1 -f image2 -c:v pgmyuv -i $raw_src \
501501 $ENC_OPTS -f rawvideo -t 1 -s 352x288 -pix_fmt $conversion $target_path/$raw_dst || return
502502 do_avconv $file $DEC_OPTS -f rawvideo -s 352x288 -pix_fmt $conversion -i $target_path/$raw_dst \
503− $ENC_OPTS -f rawvideo -s 352x288 -pix_fmt yuv444p
503+ $ENC_OPTS -f rawvideo -s 352x288 -pix_fmt yuv444p -color_range mpeg
504504 }
505505
506506 video_filter(){
tests/fate/filter-video.mak+1−1
@@ -2,7 +2,7 @@ · 1 unmodified line
22 VIDEO_FILTER = $(call ALLYES, $(1:%=%_FILTER) $(2) FILE_PROTOCOL IMAGE2_DEMUXER PGMYUV_DECODER RAWVIDEO_ENCODER NUT_MUXER MD5_PROTOCOL)
33
44 FATE_FILTER_SAMPLES-$(call FILTERDEMDECENCMUX, PERMS OWDENOISE TRIM SCALE, SMJPEG, MJPEG, RAWVIDEO, RAWVIDEO, PIPE_PROTOCOL) += fate-filter-owdenoise-sample
5−fate-filter-owdenoise-sample: CMD = ffmpeg -auto_conversion_filters -idct simple -i $(TARGET_SAMPLES)/smjpeg/scenwin.mjpg -vf "trim=duration=0.5,perms=random,owdenoise=10:20:20:enable=not(between(t\,0.2\,1.2))" -an -f rawvideo -
5+fate-filter-owdenoise-sample: CMD = ffmpeg -auto_conversion_filters -idct simple -i $(TARGET_SAMPLES)/smjpeg/scenwin.mjpg -vf "trim=duration=0.5,perms=random,owdenoise=10:20:20:enable=not(between(t\,0.2\,1.2))" -an -f rawvideo -color_range mpeg -
66 fate-filter-owdenoise-sample: REF = $(SAMPLES)/filter-reference/owdenoise-scenwin.raw
77 fate-filter-owdenoise-sample: CMP_TARGET = 1
88 fate-filter-owdenoise-sample: FUZZ = 3539
tests/fate/vcodec.mak+1−1
@@ -6,7 +6,7 @@ fate-vsynth%: CODEC = $(word 3, $(subst -, ,$(@))) · 5 unmodified lines
66 fate-vsynth%: FMT = avi
77 fate-vsynth%: DEFAULT_SIZE = -s 352x288
88 fate-vsynth3-%: DEFAULT_SIZE = -s $(FATEW)x$(FATEH)
9−fate-vsynth%: CMD = enc_dec "rawvideo $(DEFAULT_SIZE) -pix_fmt yuv420p $(RAWDECOPTS)" $(SRC) $(FMT) "-c $(CODEC) $(ENCOPTS)" rawvideo "-pix_fmt yuv420p -fps_mode passthrough $(DECOPTS)" "" "" ${TWOPASS}
9+fate-vsynth%: CMD = enc_dec "rawvideo $(DEFAULT_SIZE) -color_range mpeg -pix_fmt yuv420p $(RAWDECOPTS)" $(SRC) $(FMT) "-c $(CODEC) $(ENCOPTS)" rawvideo "-pix_fmt yuv420p -color_range mpeg -fps_mode passthrough $(DECOPTS)" "" "" ${TWOPASS}
1010 fate-vsynth%: CMP_UNIT = 1
1111 fate-vsynth%: REF = $(SRC_PATH)/tests/ref/vsynth/$(@:fate-%=%)
1212

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