Virtual Camera: The Raw-conversion Challenge

Started Jan 19, 2013 | Discussions thread
ForumParentFirstPreviousNextNext unread
Flat view
Marianne Oelund
Veteran MemberPosts: 4,296Gear list
Like?
Virtual Camera: The Raw-conversion Challenge
Jan 19, 2013

Testing cameras and lenses is tedious, to put it mildly.  Countless hours of setup, tweaking, trying to optimize lighting/white-balance/focus, while keeping consistency between the items tested.  Investigating tradeoffs between various settings can be challenging.  Using physical charts, lights, lenses and cameras to produce suitable images for putting our post-processing tools and skills to the test can be a frustrating endeavor.

Enter the Virtual Camera, which I am hoping will prove to be a useful tool for studying the setups and tradeoffs we will use in photography.  Especially with regard to evaluating post-processing regimens, the Virtual Camera can provide some very difficult material indeed.

I am looking forward to results from users, demonstrating the subtle differences between various raw converters and techniques.  Please do take advantage of this opportunity to test your own prowess with your favorite converter.

What is the Virtual Camera?

This is the Optical simulator application, with the addition of a raw-output capability which allows the simulated raw data to be processed by any raw converter.  If it is run in the presence of a suitable NEF file (one is provided in the application .zip), it will write a test-image patch to that file.  A patch is 400x200 pixels in size (or 400x100 if the AA-filter step is omitted), and may be placed at any position in the raw image.  Multiple runs can accumulate many patches in a single NEF file.

Each patch contains a vertical-bar set at a specified frequency, which has been subjected to aperture diffraction, lens blur, defocus, etc.  The bars are given a gradual shift, to exercise all of the possible offsets between the image and the Bayer sensor arrray, i.e., the bars are at a slight slant.  With AA-filter simulation enabled, each patch has an upper and lower section; the lower one shows the result post-AA-filter.

You may find the application Vcam.zip on my Optical simulation web page.  The archive contains Vcam.exe (a concole application which runs in a Windows Command Prompt window), file TempDX.NEF, spreadsheet Plots_template.xls, batch file stepf.bat, and several .jpg files which are NEF output sets converted by Raw Therapee.  The patches in the .jpg files are not labeled, but if you refer to the stepf.bat file, it will show you which patches correspond to which signal frequencies.

To run Vcam, copy the file TempDX.NEF to Output.NEF, then issue a Vcam command from the Command Prompt window.  Details of the control switches are provided on the Optical simulation web page.  Here is an example sequence of commands to demonstrate:

Vcam /b /f5.6 /L0 /h

Vcam /b /f2.8 t=3 /L0 /h y=300

Vcam /b /p4 /f4 t=2.5 a=0.35 /L0 /h y=600

All three of these commands use the /b switch to specify vertical bars, the /L0 switch to turn on sensel-data output, and the /h switch to place data into the Trace.csv file in a horizontal format.  The /L0 or /L switch is required, or there will be no raw output, but the /h switch is optional.

The first command specifies aperture f/5.6 and uses the default test-object period, which is at the Nyquist frequency.  The image patch will be placed in the upper-left corner of Output.NEF, and will include both pre-AA and post-AA versions (default AA filter is a shift of plus/minus 0.4 sensel widths).  To suppress the post-AA portion of the patch, use switch /a0.

The second command specifies aperture f/2.8, a test-object period of 3.0 (corresponding to 2/3 of Nyquist frequency), and places the patch 300 pixels below the first one in the Output.NEF file.

The last command includes a 4um lens blur, aperture f/4, test-object period of 2.5 (corresponding to 0.8*Nyquist freq.), a tighter AA filter of 0.35-sensel-width shift, and the image patch will be placed 600 pixels below the corner in the Output.NEF file.

To create a large set of image patches over a range of frequencies, you may use stepf.bat.  Just substitute "stepf" for "Vcam" and it will take your switch settings and apply them to multiple runs of Vcam, with each output patch placed at a unique position in Output.NEF.  [Note regarding switch syntax:  Although I tend to be rather free-form about which switch syntax I use, when running the stepf batch file, you must use the syntax with the forward-slash prefix, e.g., /t3.  Switches using the equals sign will lose that symbol and will be ignored.]

The following posts will show some Output.NEF samples converted to .jpg files by Raw Therapee.  They contain many interesting "features."

-- hide signature --

Qualities possessed by God in infinite proportion: Love, Grace, Power, Righteousness, Wisdom, . . .
Qualities possessed by humans in infinite proportion: Ignorance.
- Marianne

ForumParentFirstPreviousNextNext unread
Flat view
ForumParentFirstPreviousNextNext unread
Keyboard shortcuts:
FForum PPrevious NNext WNext unread UUpvote SSubscribe RReply QQuote BBookmark post MMy threads
Color scheme? Blue / Yellow