On Tue, 24 May 2005, Dik Takken wrote: > I recently switched from yuvscaler to y4mscaler for reasons known to > some of you ;) and came across a problem: The croma data in the image > that has been processed via y4mscaler looks weird. I compared the > output of the command > > smil2yuv -i 2 test.dv | y4mscaler -O chromass=420_MPEG2 -S option=sinc:4 | > yuvcorrect -Y LUMINANCE_1.0_16_235_127_127 -Y > CHROMINANCE_0.0_4_128_4_128_16_240 | yuvplay > > smil2yuv test.dv | yuvcorrect -Y LUMINANCE_1.0_16_235_127_127 -Y > CHROMINANCE_0.0_4_128_4_128_16_240 | yuvplay > > The difference is attached to this mail. I tried playing with the -S > option of y4mscaler, but I did not manage to get a decent picture.
The -S option isn't critical - a higher number of taps would preserve a slightly higher level of detail but wouldn't make a huge difference. > What is it that I'm doing wrong? Using "-i 2" with smil2yuv. From smil2yuv's usage summary: Usage: smil2yuv [ -i type ] [ -a audio-file ] file [ file ... ] Where: file is smil, dv avi (1 or 2) or raw dv -i type - 0 no deinterlacing, 1 bad deinterlacing 2 experimental 4:1:1 subsampling (more to follow) "2" means 4:1:1 - and I thought you were dealing with PAL DV which is one of the 4:2:0 variants. I think that "-i 2" is forcing smil2yuv to treat PALDV data as 4:1:1 rather than 4:2:0. The result will be rather severe misalignment of the chroma planes ;) That's my theory at the moment. What happens if you combine the two commands above into: smil2yuv test.dv | \ y4mscaler -O chromass=420_MPEG2 -S option=sinc:4 | \ yuvcorrect -Y LUMINANCE_1.0_16_235_127_127 -Y CHROMINANCE_0.0_4_128_4_128_16_240 | yuvplay 4:1:1 frames and 4:2:0 frames occupy the same amount of space so it's possible to feed 4:1:1 data into a program expecting 4:2:0 and no crash will happen. But you'll get "special effects" type of colors ;) Cheers, Steven Schultz ------------------------------------------------------- This SF.Net email is sponsored by Yahoo. Introducing Yahoo! Search Developer Network - Create apps using Yahoo! Search APIs Find out how you can build Yahoo! directly into your own Applications - visit http://developer.yahoo.net/?fr=offad-ysdn-ostg-q22005 _______________________________________________ Mjpeg-users mailing list Mjpeg-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/mjpeg-users