Lurk all you'd like, but why not register and post some pics? Registering also makes it easier to find the good stuff. Need help?

Go Back   Digital Grin Photography Forum > Photo Finish > Finishing School
Dgrinner
Password
Register FAQ Shooters Calendar Reviews Tutorials Gallery Books Search Today's Posts Mark Forums Read

Reply
 
Thread Tools Display Modes
Old Nov-02-2009, 06:04 AM   #1
Carmelo75
Learning grins
 
Join Date: Jul 2009
Posts: 143
my digital grain technique - C&C please

hi everybody,

I would like to get some opinions about a digital grain rendering technique on which I am working in my spare time.

I do not want to enter here in the debate whether digital film grain makes sense or not; I think many people used high speed films for artistical reasons more than for necessity, so why not obtain something similar with digital files?

After having tried the simple recipes found on the web, which basically suggest to take either a random noise pattern or a scanned film image and blend it to your image in overlay mode, I was totally unhappy of the result when printing the images on A4 or more, so I decided to go my way and take a different approach.

BE AWARE: this is not a commercial software, and I'm ready to share all the details of what I am doing, if there are people interested. On the other end, the technique is not simple and cannot be translated into, say, a photoshop action, so I prefer to provide a long and detailed description only if there are poeple interested in it...

Here is a test image showing one possible grain rendering. The top part contains a grainy picture at the native resolution of my camera (12M pixels); the bottom contains a detail of the top one, corresponding to the resolution at which the grain is rendered (about 3.5x).

Hope the post is pertinent to this forum, and that you'll find it interesting .

Carmelo.
Attached Images
 
Carmelo75 is offline   Reply With Quote
Old Nov-02-2009, 06:05 AM   #2
Carmelo75
Learning grins
 
Join Date: Jul 2009
Posts: 143
here is the original cropped image, before grain rendering (at 100% magnification)
Attached Images
 
Carmelo75 is offline   Reply With Quote
Old Nov-02-2009, 09:30 AM   #3
Qarik
Krazy Korean
 
Qarik's Avatar
 
Join Date: Oct 2007
Location: San Jose, CA
Posts: 2,572
Quote:
Originally Posted by Carmelo75
here is the original cropped image, before grain rendering (at 100% magnification)
interesting..seem to be working. I wonder if you have any shots of something less abstract..a face for example.
__________________
D700, D200
24-70mm and 70-200mm (vr2) 2.8
85mm and 50mm 1.4
45mm PC
tokina 11-16mm
sb900 x2

http://www.danielkimphotography.com
Qarik is offline   Reply With Quote
Old Nov-02-2009, 12:19 PM   #4
Carmelo75
Learning grins
 
Join Date: Jul 2009
Posts: 143
Sure I have it, no problem. I'll post something tomorrow...
Carmelo75 is offline   Reply With Quote
Old Nov-02-2009, 01:06 PM   #5
pathfinder
Drive By Digital Shooter
 
pathfinder's Avatar
 
Join Date: Jan 2004
Location: western Indiana
Posts: 11,629
I am hoping you plan to detail the specific steps you are using to create this grain in your images.

I look forward to seeing your specific steps, that we may duplicate this for our viewer's images here.
__________________
Pathfinder

Moderator of the Technique Forum and the Finishing School on Dgrin

www.pathfinder.smugmug.com
pathfinder is offline   Reply With Quote
Old Nov-03-2009, 11:42 AM   #6
Carmelo75
Learning grins
 
Join Date: Jul 2009
Posts: 143
Ok, I'll try to briefly describe the steps, and give another, less abstract application of the method.

The steps that produce the grain effect shown here are, in a simplified form, the following:

1) the original image is magnified 4x and divided into small tiles

2) in each tile, the pixels are replaced by "digital grains"

2a) the location of the new grain is choosen randomly inside the tile
2b) the size of the new grain is tandomly choosen, according to a user-defined distribution
2c) the average grayscale tone of the image in the region covered by the grain is computed, and is randomized to obtain the "grain tone"
2d) the grayscale value of the image pixels in the grain region is replaced by the "grain tone"

3) Steps 2a-2d are repeated until all pixels in the tile have been processed, then the tile is downscaled by 4x to obtain the final grainy image, and the next tile is started

The result is an image made of grayscale "patches" of random shape and size, whose darkness is IN AVERAGE equivalent to that of the original image. Compared to the simple overlay blend method, one gets more pronounced and natural grains in the shadow and highlights portions, and there is more control on the size and strength of the grain structure. Moreover, the grains can be rendered at virtually any resolution, making it possible to upscale the images without pixelization effects.

Here is the original test image:



Here is a comparison of the two methods.

Overaly noise blend:


Digital grain:


This is a 100% magnification detail of the above original image:


Overlay noise blend:


Digital grain:


The images are pretty similar in the mid tones, but the difference in the dark and light regions is evident... I personally find the last image more realistic, but I would like to get your opinions (you are also free to tell me that I should stop loosing my spare time...).


I plan to make some documentation ad the code available at this address:

http://digitalgrain.sourceforge.net/

All kind of comments will be appreciated.

Carmelo.
Carmelo75 is offline   Reply With Quote
Old Nov-03-2009, 11:54 AM   #7
Qarik
Krazy Korean
 
Qarik's Avatar
 
Join Date: Oct 2007
Location: San Jose, CA
Posts: 2,572
honest assessment.

I can see the differences..I am ambivalent about them mostly. I think your method is more realistic but marginally so. It is very clever though. I am reminded of what some other poster once said about you PS gurus..you guys find the most fiendishly clever and complicated tricks to do something that can be done very simply another way.
__________________
D700, D200
24-70mm and 70-200mm (vr2) 2.8
85mm and 50mm 1.4
45mm PC
tokina 11-16mm
sb900 x2

http://www.danielkimphotography.com
Qarik is offline   Reply With Quote
Old Nov-03-2009, 12:21 PM   #8
Carmelo75
Learning grins
 
Join Date: Jul 2009
Posts: 143
Quote:
Originally Posted by Qarik
honest assessment.

I can see the differences..I am ambivalent about them mostly. I think your method is more realistic but marginally so. It is very clever though. I am reminded of what some other poster once said about you PS gurus..you guys find the most fiendishly clever and complicated tricks to do something that can be done very simply another way.
Thanks for looking and commenting Quarik, I appreciated.

First, let me state that I am not a PS guru at all, in fact all I descibed is not done in PS, as I would not know how to do obtain it. But I am a reasonably good programmer, and I wrote my own small image processing program for pure curiosity to see the result...

In fact, before starting all that I have printed a couple of A4 pictures with a grainy look produced with the overlay method, and found the result quite unnatural. The difference is not so evident in web pictures, but it becomes (at least for me) annoying when I come to printing.

The point is that I have not found any simple way of getting a nice grain in shadow areas with PS or other programs (I have for example tried TrueGrain in the demo version, but I have not been impressed too much) .
Therefore I decided to try something different, maybe more complicated but with hopefully more pleasing results.

I usually do not like to complicate my life more than needed, but I like to follow the ideas and see where they bring...

Carmelo.
Carmelo75 is offline   Reply With Quote
Old Nov-04-2009, 04:23 PM   #9
Qarik
Krazy Korean
 
Qarik's Avatar
 
Join Date: Oct 2007
Location: San Jose, CA
Posts: 2,572
Quote:
Originally Posted by Carmelo75
Thanks for looking and commenting Quarik, I appreciated.

First, let me state that I am not a PS guru at all, in fact all I descibed is not done in PS, as I would not know how to do obtain it. But I am a reasonably good programmer, and I wrote my own small image processing program for pure curiosity to see the result...

In fact, before starting all that I have printed a couple of A4 pictures with a grainy look produced with the overlay method, and found the result quite unnatural. The difference is not so evident in web pictures, but it becomes (at least for me) annoying when I come to printing.

The point is that I have not found any simple way of getting a nice grain in shadow areas with PS or other programs (I have for example tried TrueGrain in the demo version, but I have not been impressed too much) .
Therefore I decided to try something different, maybe more complicated but with hopefully more pleasing results.

I usually do not like to complicate my life more than needed, but I like to follow the ideas and see where they bring...

Carmelo.
ahh..I thought you did this in PS. I know that LR3 is adding a "film grain" module to it arsenal. That should be interesting. Lastly you could on some occasion simply shoot at a higher iso and/or underxpose and push exposure in post to create noise if that is an option.
__________________
D700, D200
24-70mm and 70-200mm (vr2) 2.8
85mm and 50mm 1.4
45mm PC
tokina 11-16mm
sb900 x2

http://www.danielkimphotography.com
Qarik is offline   Reply With Quote
Old Nov-04-2009, 10:24 PM   #10
Carmelo75
Learning grins
 
Join Date: Jul 2009
Posts: 143
Quote:
Originally Posted by Qarik
ahh..I thought you did this in PS. I know that LR3 is adding a "film grain" module to it arsenal. That should be interesting. Lastly you could on some occasion simply shoot at a higher iso and/or underxpose and push exposure in post to create noise if that is an option.
I will try to understand what the LR3 film grain module is doing, hope it does better than the film grain filter in PS...

Shooting at high iso is in fact not really an option, as digital noise is very different from true grain. In particular, noise is a randomization of the CCD/CMOS readings that is in first approximation independent of the actual pixel luminosity, and only depends on the sensor gain and exposure time. As a consequence, it also appears in deep shadows or highlights, so that at high iso you cannot obtain pure black or pure white...
Carmelo75 is offline   Reply With Quote
Reply

Tell The World!

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is On

Forum Jump


Times are GMT -8.   It's 09:52 AM.


Powered by vBulletin® Version 3.8.5
Copyright ©2000 - 2010, Jelsoft Enterprises Ltd.