dwbuiten / d2vsource

D2V parser and decoder for VapourSynth
GNU Lesser General Public License v2.1
32 stars 6 forks source link

Output is faded compared to ffms2 #28

Closed Noctem closed 8 years ago

Noctem commented 8 years ago

I've only tested this with one video so far, but I noticed that the colors I got with d2vsource are noticeably duller than ffms2. Is there a reason for that? VapourSynth Editor reports that the format is YUV422P8 for both of them.

c.d2v.Source(input=r'video.d2v') example-d2vsource

c.ffms2.Source(source="video.ts") example-ffms2

dubhater commented 8 years ago

You must have YUVRGB_Scale=1 in the d2v file. It means that d2vsource will mark the frames as full range YUV. Either change that to 0, or add clip = c.std.SetFrameProp(clip, prop="_ColorRange", intval=1) right after the source filter. (Yes, the values for YUVRGB_Scale and the _ColorRange property are backwards.)

If you created the d2v file with dgindex, there is an option in one of the menus where you can pick the colour range. If you created it with d2vwitch, there is no way to pick the colour range (yet).

http://rationalqm.us/dgmpgdec/DGIndexManual.html#AppendixA http://www.vapoursynth.com/doc/apireference.html#reserved-frame-properties http://www.vapoursynth.com/doc/functions/setframeprop.html

Noctem commented 8 years ago

Excellent, thanks. Setting YUVRGB_Scale to 0 fixed it. I should have checked on that.