Magic Lantern Forum

Using Magic Lantern => Post-processing Workflow => Topic started by: mindogas on October 23, 2012, 11:13:21 AM

Title: 422ToImage - Silence Pic YUV422 images to JPEG, PNG, BMP and TIF converter
Post by: mindogas on October 23, 2012, 11:13:21 AM
For learning timelapse and testing purpose Silence Pic is unbeatable feature. I'm using it for testing motorized timelapse slider and it's motor/camera controller. I'm doing lots off shoots while testing and without this function my camera would be in the middle/end of it's shutter resource. Problem we are facing - slow image conversation from *.422 files to well known formats. For example in  Intel Xeon E5606 2,13GHz, 4 Core and 6GB RAM workstation original ML program converted only 1.6 frames per second.

Software:
Idea was to make fast and useful software for this job. After same work with I finished with it. Programming was done with C# language in Visual Studio 2010 environment.

(http://img820.imageshack.us/img820/2130/clipboard01gfs.jpg)

Compare:
In mentioned Intel Xeon E5606 workstation this software doing 35 frames per second performance. To compare speed I made few videos in my home PC (using V1.0 version).
422-jpg-v2.exe processing 100 pictures in 1024x680:

My software processing same files:

And one more time my software doing 999 pictures:


At the end this software looks promising. Now to convert lots of files we do not need to wait long time. Event with one core CPU this program doing it's job faster because software constructing new image using Fast Bitmap methodology. After some works in spare time software now have HDR image generation, resize, rotate, crop options. Nowaday we are facing v1.6 version but with help with users developing continues.

422ToImage 1.9 features:

Download:
Windows binaries could be downloaded here: https://bitbucket.org/mindogas/422toimage/downloads
Visual Studio 2010 source code: https://bitbucket.org/mindogas/422toimage/src

I think someone will find this software usable. I'm looking forward to continue developing and upgrading this software so all suggestion and bug reports are welcome.
Title: Re: 422ToImage - Silence Pic YUV422 images to JPEG, PNG and BMP converter
Post by: kihlbahkt on October 23, 2012, 07:06:37 PM
Mindogas,
Thanks for your development efforts on this app.

In the readme file you have a link to enblend/enfuse that does not work. I used the URL below to get to the software.

http://sourceforge.net/projects/enblend/files/latest/download

Title: Re: 422ToImage - Silence Pic YUV422 images to JPEG, PNG and BMP converter
Post by: 1% on October 24, 2012, 03:21:23 AM
Thanks! You make .422 usable for me. Willing to say the other programs are crap.
Title: Re: 422ToImage - Silence Pic YUV422 images to JPEG, PNG and BMP converter
Post by: mindogas on October 24, 2012, 05:44:57 AM
Quote from: kihlbahkt on October 23, 2012, 07:06:37 PM
Mindogas,
Thanks for your development efforts on this app.

In the readme file you have a link to enblend/enfuse that does not work. I used the URL below to get to the software.

http://sourceforge.net/projects/enblend/files/latest/download
Thanks for pointing this mistake. Fixing right now.
Title: Re: 422ToImage - Silence Pic YUV422 images to JPEG, PNG and BMP converter
Post by: a1ex on October 24, 2012, 02:57:06 PM
You may also want to sync with this: https://bitbucket.org/hudson/magic-lantern/changeset/5dd16c4e08fc
Title: Re: 422ToImage - Silence Pic YUV422 images to JPEG, PNG and BMP converter
Post by: mindogas on October 24, 2012, 03:07:49 PM
Quote from: a1ex on October 24, 2012, 02:57:06 PM
You may also want to sync with this: https://bitbucket.org/hudson/magic-lantern/changeset/5dd16c4e08fc
Thanks for pointing. Actually I'm tracking changes in ML source, so I would found thous changes too.
For now I fixed 1x resolution and added photo mode to resolution.xml file but i will publish it with next bigger software version update. While 5D3 port are not stable i thing were is no hurry to do update right now.
Title: Re: 422ToImage - Silence Pic YUV422 images to JPEG, PNG and BMP converter
Post by: kihlbahkt on October 25, 2012, 07:22:36 AM
Found another small issue. Misspelling in dialog that appears when the user has selected check box to delete original 422 files and then hits Start button.

original is misspelled as orgilan.

Your software makes using 422 files very easy. Nice job.
Title: Re: 422ToImage - Silence Pic YUV422 images to JPEG, PNG and BMP converter
Post by: mindogas on October 25, 2012, 07:25:31 AM
Quote from: kihlbahkt on October 25, 2012, 07:22:36 AM
Found another small issue. Misspelling in dialog that appears when the user has selected check box to delete original 422 files and then hits Start button.

original is misspelled as orgilan.

Your software makes using 422 files very easy. Nice job.
OK, my English is a little bit worst i think :)
Fixed. Thanks.
Title: Re: 422ToImage - Silence Pic YUV422 images to JPEG, PNG and BMP converter
Post by: kihlbahkt on October 25, 2012, 10:53:45 PM
http://www.youtube.com/watch?v=KM3KEPYNgoE

Here is a 7 sec example of simple silent picture sequence converted using 422toImage to JPEG then exported from Premiere Pro as a movie.
look for the squirrel...

Mindogas,

Software works great for simple and fast conversion of .422 files. Have not previously done much with silent pic but this app is great.
Title: Re: 422ToImage - Silence Pic YUV422 images to JPEG, PNG and BMP converter
Post by: mindogas on November 06, 2012, 01:26:54 PM
Some help needed for testing new feature - tool for finding unknown image resolution.

This tool will appear you pressing start button and program finds out that image have weird size. Some screenshots:
(http://img7.imageshack.us/img7/4638/001ofa.jpg)
(http://img41.imageshack.us/img41/5954/002jea.jpg)
The list of resolutions depends from size of the image. If you find correct option by pressing Save button resolutions.xml will be updated and conversions starts with new setup.

Please anyone try this at home: https://bitbucket.org/mindogas/422toimage/downloads/1.7beta.zip (left resolutions.xml blank for this reason)
Title: Re: 422ToImage - Silence Pic YUV422 images to JPEG, PNG and BMP converter
Post by: ilguercio on November 06, 2012, 01:45:30 PM
Is this for high-res pictures as well? I might submit my findings from my 50D.
Title: Re: 422ToImage - Silence Pic YUV422 images to JPEG, PNG and BMP converter
Post by: mindogas on November 06, 2012, 01:55:59 PM
Quote from: ilguercio on November 06, 2012, 01:45:30 PM
Is this for high-res pictures as well? I might submit my findings from my 50D.
No, this is only for simple and zoomed silence pictures. For now HiRez images have the same resolution for all cameras if this option is possible.
Title: Re: 422ToImage - Silence Pic YUV422 images to JPEG, PNG and BMP converter
Post by: ilguercio on November 06, 2012, 01:56:35 PM
Quote from: mindogas on November 06, 2012, 01:55:59 PM
No, this is only for simple and zoomed silence pictures. For now HiRez images have the same resolution for all cameras if this option is possible.
Ok, thanks.
:)
Title: Re: 422ToImage - Silence Pic YUV422 images to JPEG, PNG and BMP converter
Post by: ilguercio on November 06, 2012, 02:19:17 PM
I still don't understand, i can convert 422 files from my 50D easily (burst or continuous and simple SP) and i can't get HR or SP while recording to be converted. So, what is this for? Am i missing something? Aren't the resolution of all these files known?
Title: Re: 422ToImage - Silence Pic YUV422 images to JPEG, PNG and BMP converter
Post by: mindogas on November 06, 2012, 02:29:24 PM
Quote from: ilguercio on November 06, 2012, 02:19:17 PM
I still don't understand, i can convert 422 files from my 50D easily (burst or continuous and simple SP) and i can't get HR or SP while recording to be converted. So, what is this for? Am i missing something? Aren't the resolution of all these files known?
While resolution.xml is empty you shouldn't be able to convert SimplePictures in continues, burst or other modes. For thous files you should be asked to setup custom resolution. This tool is for future cameras then new resolutions will came. Regarding Hirez there is one bug now. I'll fix it later.
Title: Re: 422ToImage - Silence Pic YUV422 images to JPEG, PNG and BMP converter
Post by: ilguercio on November 06, 2012, 02:34:08 PM
Thanks, i got that resolution.xml error the first time i used your converter but i don't get it anymore.
Let me know when you manage to solve the issue with HR silent pics.
Thanks again.
Title: Re: 422ToImage - Silence Pic YUV422 images to JPEG, PNG and BMP converter
Post by: mindogas on November 06, 2012, 02:37:42 PM
Quote from: ilguercio on November 06, 2012, 02:34:08 PM
Thanks, i got that resolution.xml error the first time i used your converter but i don't get it anymore.
Let me know when you manage to solve the issue with HR silent pics.
Thanks again.
Weird question: are you playing with this beta build: https://bitbucket.org/mindogas/422toimage/downloads/1.7beta.zip?
Also: HR silent pics troubles for 50D are not converter problem but ML.
Title: Re: 422ToImage - Silence Pic YUV422 images to JPEG, PNG and BMP converter
Post by: ilguercio on November 06, 2012, 02:40:18 PM
Quote from: mindogas on November 06, 2012, 02:37:42 PM
Weird question: are you playing with this beta build: https://bitbucket.org/mindogas/422toimage/downloads/1.7beta.zip?
Also: HR silent pics troubles for 50D are not converter problem but ML.
Nope, i was talking about the previous one. I'll move to 1.7 in a second ;)
Title: Re: 422ToImage - Silence Pic YUV422 images to JPEG, PNG and BMP converter
Post by: mindogas on November 06, 2012, 02:45:25 PM
Quote from: ilguercio on November 06, 2012, 02:40:18 PM
Nope, i was talking about the previous one. I'll move to 1.7 in a second ;)
As i sad this update is for unknown YUV resolutions. This won't for resolving 50D ML bugs.
Title: Re: 422ToImage - Silence Pic YUV422 images to JPEG, PNG and BMP converter
Post by: ilguercio on November 06, 2012, 02:49:18 PM
Ok, i got it.
Nice to know about the 50D.
No zoom:1024*680
5X and 10X zoom: 944*632
Title: Re: 422ToImage - Silence Pic YUV422 images to JPEG, PNG and BMP converter
Post by: cosmo.lv on February 23, 2013, 04:12:50 AM
Quote from: mindogas on November 06, 2012, 02:45:25 PM
As i sad this update is for unknown YUV resolutions. This won't for resolving 50D ML bugs.

Hi, and thanks for such a great work, but is any hope for MAC users, i mean native application for mac?
Title: Re: 422ToImage - Silence Pic YUV422 images to JPEG, PNG and BMP converter
Post by: mindogas on March 04, 2013, 03:38:01 PM
Quote from: cosmo.lv on February 23, 2013, 04:12:50 AM
Hi, and thanks for such a great work, but is any hope for MAC users, i mean native application for mac?
No chances from my side.  Generally I'm programming only applications for Windows OS and Atmel's and I have no spare time to learn MAC stuff :)
I suggest to try run my software on mac over CrossOver or WineBottler. If you lucky maybe performance won't be decreased so much.
Title: Re: 422ToImage - Silence Pic YUV422 images to JPEG, PNG and BMP converter
Post by: 1% on March 04, 2013, 04:58:53 PM
It has problems running in wine on linux.
Title: Re: 422ToImage - Silence Pic YUV422 images to JPEG, PNG and BMP converter
Post by: scrax on March 05, 2013, 02:16:08 AM
Quote from: cosmo.lv on February 23, 2013, 04:12:50 AM
Hi, and thanks for such a great work, but is any hope for MAC users, i mean native application for mac?

For Osx there is a script (https://bitbucket.org/hudson/magic-lantern/src/9f88a2eef954/src/422-tif.py?at=unified) in the repo but you need to install PIL before, other dependencies are already installed on mac (Python, pip).
prepare.Lion.sh  (https://bitbucket.org/hudson/magic-lantern/src/9f88a2eef954eee947f8b67581b0cbec92dfa148/contrib/toolchain/prepare.Lion.sh?at=unified) shoud help in installing what's missing.
Title: Re: 422ToImage - Silence Pic YUV422 images to JPEG, PNG and BMP converter
Post by: escho on March 05, 2013, 05:53:47 PM
Quote from: 1% on March 04, 2013, 04:58:53 PM
It has problems running in wine on linux.

I´m running this in OpenSuse 12.2 with wine without any problems.

Edgar
Title: Re: 422ToImage - Silence Pic YUV422 images to JPEG, PNG and BMP converter
Post by: 1% on March 05, 2013, 06:20:12 PM
On linux mint it starts to open then disappears.
Title: Re: 422ToImage - Silence Pic YUV422 images to JPEG, PNG and BMP converter
Post by: escho on March 05, 2013, 08:30:29 PM
Try to start it in a terminal like this:

wine "/home/edgar/Downloads/422ToImage 1.6.2/422ToImage.exe"


And than look for errors

Edgar
Title: Re: 422ToImage - Silence Pic YUV422 images to JPEG, PNG and BMP converter
Post by: 1% on March 05, 2013, 10:29:10 PM
I see... it said to upgrade mono to 2.8.

Thanks!
Title: Re: 422ToImage - Silence Pic YUV422 images to JPEG, PNG and BMP converter
Post by: Franzkekko on May 04, 2013, 10:48:45 PM
Compliments for the software...works really good!
Well done Mindogas  8)
Title: Re: 422ToImage - Silence Pic YUV422 images to JPEG, PNG and BMP converter
Post by: kgv5 on May 06, 2013, 01:22:39 PM
Is this app able to process *.yuv files?
Title: Re: 422ToImage - Silence Pic YUV422 images to JPEG, PNG and BMP converter
Post by: mindogas on May 06, 2013, 02:46:07 PM
Quote from: kgv5 on May 06, 2013, 01:22:39 PM
Is this app able to process *.yuv files?
Yes if you recorded movie using latest code, were the end of *.YUV has extra 32 bytes defining frames properties. Updated 422ToImage v1.9 you could find here: https://bitbucket.org/mindogas/422toimage/downloads
Title: Re: 422ToImage - Silence Pic YUV422 images to JPEG, PNG, BMP and TIF converter
Post by: 1% on May 06, 2013, 03:41:13 PM
Can you add containerizing for the raw DNG sequences from Lv_rec... as just a data dump they don't play back and lv_rec would slow down adding the containers.

Tried the 422 splitting and its very convenient.
Title: Re: 422ToImage - Silence Pic YUV422 images to JPEG, PNG, BMP and TIF converter
Post by: mindogas on May 06, 2013, 05:41:11 PM
Quote from: 1% on May 06, 2013, 03:41:13 PM
Can you add containerizing for the raw DNG sequences from Lv_rec... as just a data dump they don't play back and lv_rec would slow down adding the containers.

If RAW buffers storing in card will be implemented and I will see possibilities for this function inside 422ToImage i will definitely go with it. I implemented  .yuv spitting feature after g3gg0 asked me to do so. This feature is very similar to Silence Pic's conversation.  I'm not well aware of ongoing work in the field of RAW video so for me it's had to plan anything.
Title: Re: 422ToImage - Silence Pic YUV422 images to JPEG, PNG, BMP and TIF converter
Post by: 1% on May 06, 2013, 05:48:35 PM
They are the same as the DNG silent pics just without a header... both come out of LV_rec. I think it works with 5d3/600D/6D so far.

Probably every other camera can do the DNGs in burst, might want to take a look. Quality surpasses 422.
Title: Re: 422ToImage - Silence Pic YUV422 images to JPEG, PNG, BMP and TIF converter
Post by: g3gg0 on May 06, 2013, 09:11:44 PM
afaik DNG and the raw image content in canon cameras are different.
the chdk-dng code converts the packed format as it appears in-camera into a standard TIFF format.
so its not just about adding headers :)
Title: Re: 422ToImage - Silence Pic YUV422 images to JPEG, PNG, BMP and TIF converter
Post by: 1% on May 07, 2013, 12:56:59 AM
Going to try messing with DNG4ps and iRaw... I think those are supposed to convert files like this.
Title: Re: 422ToImage - Silence Pic YUV422 images to JPEG, PNG, BMP and TIF converter
Post by: mindogas on May 08, 2013, 07:59:42 AM
Please update 422ToImage to 1.9.1 version. There was made some corrections regarding .YUV files ordering, decoding then in threads simultaneously, fixed HDR processing and some other little fixes.
Title: Re: 422ToImage - Silence Pic YUV422 images to JPEG, PNG, BMP and TIF converter
Post by: drecali on August 11, 2013, 03:15:13 AM
Thank you kindly for developing this awesome software! It works like a charm and now I feel like the sky is the limit for sneaky pictures and timelapses lol.

You're the man!
Title: Re: 422ToImage - Silence Pic YUV422 images to JPEG, PNG, BMP and TIF converter
Post by: RenatoPhoto on September 13, 2013, 08:07:48 PM
I feel stupid, is there a way to convert the VRAMx.422 files to anything in windows?  I can view them in the camera but all the converters previously made just produce interlaced lines.
Title: Re: 422ToImage - Silence Pic YUV422 images to JPEG, PNG, BMP and TIF converter
Post by: Rewind on September 13, 2013, 08:11:37 PM
[DELETE]
Title: Re: 422ToImage - Silence Pic YUV422 images to JPEG, PNG, BMP and TIF converter
Post by: RLaudi on December 22, 2013, 11:01:45 PM
Just in case someone else is using the Silence Picture YUV422 feature of ML with Mac OS X:

I haven't found a slim and quick tool for Mac OS X to convert the .422 file format into a more common format, so I took the great groundwork by Wolfgang Hofer [[email protected]] and used it as basis for a small terminal / command line tool to convert the .422 files to TGA files. I would have preferred PNG as output format, but that would have taken significantly more development time and TGA files are fine for Quicktime image import as well for creating time lapse movies with this ML feature.

You may download this tool compiled for Mac OS X including the source code (which should compile on other platforms with a few changes as well) for free at:

http://badtidude.com/dnlds/fdl.php?dnldf=MLRaw422ToTGA_MacOSX_release_2013_12_20.zip

To use it on Mac OS X, open a terminal window, drag and drop the executable file from the unpacked zip into the window, then drag and drop one ore more .422 files to the terminal window or even better the folder which contains the .422 files and hit ENTER.
Shortly after you should have a subdirectory named ML422YUVconverted containing the converted .tga files which you may import into Quicktime 7 Pro.

Please note that this tool is provided 'as is' as I've got loads of other things on my plate ;).