Page 1 of 1

Resolved: Converting from YUV to PNG issue.

Posted: 2012-12-12T13:59:32-07:00
by Iamiuru
Hello everyone,

I'm working with a file that is captured from a firewire camera that is in YUV. I've switched to a newer Fedora (F17) and now my conversions from YUV to PNG have changed.

Old IM on F9: 6.7.1-0 Q16
New IM on F17: 6.7.9-3 Q16

The command and the raw yuv file is the same between systems, so I don't understand what is going on.

The command is:

Code: Select all

convert -size 1024x768 -sampling-factor 4:2:2 -depth 8 raw-example.yuv <outfile>.png
Here are my examples:
Old:Image New:Image

I am expecting/need the darker image for my mask generation. I suppose I can redarken the image, but not sure I can trust it if I don't know what magic is happening.

Here is the raw yuv file: http://www.foto-devel.com/images/raw-example.yuv (might need to right-click to save as)

The kicker is that the new one "raw" looks very much like my final image after I have applied my gamma correction

Code: Select all

convert inpng.png -evaluate Pow 0.45 outpng.png
Old system after gamma correction is applied: Image

I've searched the forums and changelog for YUV and 4:2:2. I haven't found much that reference much of anything. I also put the original IM 6.7.5-6 back on my F17 system to see if it did the same, and it did. I had to move up to IM6.7.9-3 due to a bug that was in IM6.7.5-6.

Any idea of what is going on here?
Thanks for your help in advance,
Jason

p.s. Sorry the model isn't very pretty. :lol:

Re: Converting from YUV to PNG issue.

Posted: 2012-12-12T14:12:42-07:00
by snibgo
"With a new version of IM, my picture is lighter/darker than before."

This immediately suggests the new feature of IM assuming that everything is sRGB, or should be converted to sRGB, unless told otherwise.

convert -size 1024x768 -sampling-factor 4:2:2 -depth 8 raw-example.yuv -colorspace RGB out.png

Re: Converting from YUV to PNG issue.

Posted: 2012-12-12T14:30:28-07:00
by Iamiuru
Thanks for the info :) I have tested it and it worked great.

I was just thinking too far into the issue. :)

Jason