How does image stacking work in Photoshop?

  • 1
  • Question
  • Updated 6 years ago
I'm taking an image processing class at school, and have a project on image stacking. I've taken several images and stacked them in Photoshop, and have gotten a nice photo with depth of field reconstruction. Now I have to get a little more technical with how Photoshop does this. Can you give me a brief idea what algorithms are used to determine what is used for the final image? I'm guessing an algorithm using edge detection is one of them that determines what is in focus.
Photo of Sandy Robin

Sandy Robin

  • 2 Posts
  • 0 Reply Likes

Posted 6 years ago

  • 1
Photo of Chris Cox

Chris Cox

  • 20280 Posts
  • 765 Reply Likes
The current image stacking modes in Photoshop already name the algorithm used.

Oh, you're talking about FOCUS stacking (which is separate and different from image stacking in Photoshop) -- no, that one is not documented.
Photo of Sandy Robin

Sandy Robin

  • 2 Posts
  • 0 Reply Likes
Yes, I meant focus stacking. Can you tell me what algorithms are used in general terms?
Photo of Chris Cox

Chris Cox

  • 20280 Posts
  • 765 Reply Likes
General terms: look for the parts that are sharpest on each layer, smooth the regions around those parts to build a mask for each layer, merge the layers.