Focus Stacking - General Help and Assistance on using CHDK stable releases - CHDK Forum

Focus Stacking

  • 4 Replies
  • 1998 Views
Focus Stacking
« on: 29 / December / 2018, 17:40:22 »
Advertisements
I'm trying to understand how CHDK focus stacking works, but am getting a little confused.
To be clear, I am not (sic) seeking a macro focus stacking solution, but a 'landscape' focus stacking one.
In this case, I wish to stack at H/2, H and 2*H, where H is my selected hyperfocal.
As an example, let's say H is 1000mm.
In the CHDK focus stacking option I can select a number that seems to indicate 0-x, where x is my input number, but it's not clear if 0 is the first focus point or camera-zero.
In the example above, if I focus at 500mm and set x to 500mm, and use four brackets, do I assume CHDK will take brackets at 500, 1000, 1500 and 2000mm?
Any insight will be most appreciated.
Cheers
Garry

*

Offline reyalp

  • ******
  • 14110
Re: Focus Stacking
« Reply #1 on: 29 / December / 2018, 18:24:57 »
In the example above, if I focus at 500mm and set x to 500mm, and use four brackets, do I assume CHDK will take brackets at 500, 1000, 1500 and 2000mm?
Yes. The CHDK built in focus bracketing option works in millimeters from the initial subject distance.  This is probably not a very good approach (it would make more sense bracket in multiples of the initial distance like you suggested), but for now, if you want something different, you'd have to use a script instead. A script that uses the H/2, H, 2*H approach shouldn't be too difficult to write.

The other thing to watch out for is whether focus override actually works on your specific camera. There's a lot of variation between models, some need to be set to MF before it works, others only do it in AF, some Canon features like continuous AF can interfere etc.
Don't forget what the H stands for.

Re: Focus Stacking
« Reply #2 on: 29 / December / 2018, 18:30:44 »
Many thanks for the insight. BTW I'm using a G7X, so I'm not sure if scripting is fully functional.

If Lua scripting is working I'll play around with it.

I have written Lua focus stacking scripts that run on my 5D3 in ML.

Cheers

Garry

Re: Focus Stacking
« Reply #3 on: 29 / December / 2018, 18:35:56 »
BTW the H based approach means that calculating the brackets is easy, eg http://photography.grayheron.net/2018/11/focus-tutorial-part-1.html


*

Offline reyalp

  • ******
  • 14110
Re: Focus Stacking
« Reply #4 on: 29 / December / 2018, 19:53:37 »
Many thanks for the insight. BTW I'm using a G7X, so I'm not sure if scripting is fully functional.

If Lua scripting is working I'll play around with it.
Yes, scripting should be functional on G7X. If you encounter anything broken not mentioned in the platform notes, please let me know.

https://chdk.wikia.com/wiki/CHDK_Scripting_Cross_Reference_Page is a good place to start for CHDK scripting. You'll want get_dofinfo for the hyperfocal distance, set_focus to set the distance.
If you want to set it in a continuous burst like CHDK bracketing, you'll probably want to use https://chdk.wikia.com/wiki/Script_Shooting_Hooks

On G7X, focus overrides only work if the camera is in MF or AF lock. You can use set_mf or set_aflock to set these from script.
On my G7X, best "infinity" focus is generally somewhat before the max focus distance, so you might want set a hard upper limit.

Also, set_focus isn't precise or deterministic: On a given camera with identical settings, different runs of a script that does set_focus(100000) ; get_focus() might return -1, 123456 or 65341.
Don't forget what the H stands for.

 

Related Topics


SimplePortal 2.3.6 © 2008-2014, SimplePortal