Author Topic: Long Exposure Simulation via Shutterless FRSP  (Read 4738 times)

garry23

  • Contributor
  • Hero Member
  • *****
  • Posts: 2218
Long Exposure Simulation via Shutterless FRSP
« on: May 21, 2016, 10:14:23 AM »
As a stills photographer I often wish to do long exposures, eg to smooth out skies or moving water, or 'eliminate' people from the scene.

Usually this would be where an ND filter would come into play. But what if you don't have an ND filter to hand, or that your ND filter doesn't give you the exposure time you desire for your artistic vision.

This is where the attached script might 'save the day'.

The usual caveats apply, eg I developed it for my workflow, it doesn't have much error checking and I've tested it on my gear, ie a 5D3.

The script makes use of the Full Res Silent Picture taking in ML and uses the Intervalometer, because at the moment I can't work out how to trigger FRSP in a Lua script, other than by using the Intervalometer  >:(

The script is limited (and checks) that the base exposure is set between 0.25 and 14 secs (to ensure it fits within the FRSP needs).

Before use, simply choose what format of FRSP you wish to use, ie DNG or MLV (remember with MLV you will need to load the MLV module and carry out MLV to DNG conversion in post). Todate I have personally stuck with DNG-FRSPs.

The script is not fast, ie it will not capture a 60 sec simulated exposure in 'real time'. But it will do all the work for you and not 'harm your shutter  ;)

To use, simply go into LV and you will find the LE Simulator under the Shoot menu.

Set the exposure (you can set Dual ISO on as well), eg manually or using ETTR auto or hints.

Choose bookends if you wish to add a DNG 'dark' frame at the beginning and end of the capture sequence, ie to help identify a bracket set in post.

Select the LE time you wish to simulate. Note if the LE time is less than the base exposure time, at least one image will be captured.

WARNING this is a LE simulator, thus, for example, if you wished to simulate a 60 second exposure with a base exposure of, say, 0.5s, you will need to capture some 120 images. So be prepared to wait for the script to do its stuff.

Because I could only get FRSP triggered via the intervalometer, the script will flash the LV on and of a few times, and you will see the ML menu flash on and off. If I can work out how to trigger FRSP from Lua without using the intervalometer, I'll update the script.

Once the script has finished (the LV will come back on) 'all' you need to do is to ingest your images in to your favorite post processing tool to process the LE bracket set. I personally use Photoshop-CC via a smart object and use medium or mean stacking.

Note: I set and reset ML menu items in the script.

As usual, I welcome any feedback to help me in my scripting developments and will respond to any suggestions to make the script better, ie I'm not really a programmer.

Cheers

Garry

Code: [Select]
--[[
LE simulation using shutterless, Full Res Silent Picture bracketing.
Creates (same exposure) brackets for post processing a simulated LE exposure, eg via PS-CC mean smart filter stack
User must re-select FRSP mode, ie DNG or MLV and Dual-ISO if required
Base exposure must be between 0.25-14 secs
Finally, because of my 'work arounds' for triggering the intervalomter function in Lua, the LV will flash on and off a few times
Version 0.5
*******************************************************************************************************
*   *
* If you reference this script, please consider acknowledging me: http://photography.grayheron.net/   *
*   *
*******************************************************************************************************
--]]

function my_shoot()
-- Grab a/some timelapse image(s)
lv.pause()  -- switch off LV, if on, but keep shutter open
menu.open()
menu.close()
repeat -- hang around until finished
msleep (300)
until interval.running == 0 -- when intervalometer has finished
end

function check_bookend()
if keymenu.submenu["Bookends?"].value == "yes"
then
lv.pause()  -- switch off LV, if on, but keep shutter open
local tv = camera.shutter.ms
local av = camera.aperture.value
menu.set("Expo","Expo. Override",1)
camera.shutter.value = 0.3
camera.aperture.value = 20
menu.set("Intervalometer","Start after",0)
menu.set("Shoot","Intervalometer",1)
menu.set("Intervalometer","Take Pics...",0)
menu.set("Intervalometer","Start trigger",0)
menu.set("Intervalometer","Stop after",1)
menu.set("Shoot","Silent Picture",1)
menu.set("Silent Picture","Silent Mode",5)
my_shoot()
camera.shutter.ms = tv
camera.aperture.value = av
end
end

function go() -- and run the script
if camera.shutter.value < 0.25 or camera.shutter.value > 14 then -- not fit for FRSP use
-- Set to a 'safe' condition before exiting
menu.close()
menu.set("Shoot","Intervalometer",0)
menu.set("Shoot","Silent Picture",0)
menu.set("Intervalometer","Start trigger",1)
beep (3, 200 , 500)  -- display warning message
display.notify_box("Adjust your shutter time: 0.25-14 secs", 5000)
else -- alright to use FRSP
lv.start()  -- just in case
check_bookend()
local LE_brackets = math.ceil(keymenu.submenu["LE Time?"].value/camera.shutter.value)
local delay = tonumber(keymenu.submenu["Delay"].value)
if keymenu.submenu["Bookends?"].value == "yes" then delay = 0 end
-- Ensure Intervalometer and FRSP menus are set correctly
menu.set("Shoot","Intervalometer",1)
menu.set("Intervalometer","Take Pics...",0)
menu.set("Intervalometer","Start trigger",0)
menu.set("Intervalometer","Start after",delay)
menu.set("Intervalometer","Stop after",LE_brackets)
menu.set("Intervalometer","Manual FocusRamp",0)
menu.set("Shoot","Silent Picture",1)
menu.set("Silent Picture","Silent Mode",5)
menu.set("Expo","Expo. Override",1)
-- trigger intervalometer via ML menu close
my_shoot()
msleep(100)
check_bookend()
lv.resume() -- switch LV back on, from using intervalometer, to signify end of bracketing
-- Set Intervalometer and FRSP to a 'safe' condition before exiting
menu.set("Shoot","Intervalometer",0)
menu.set("Shoot","Silent Picture",0)
menu.set("Intervalometer","Start trigger",1)
display.notify_box("LE sim script finished", 5000)
beep(3)
end
end

keymenu = menu.new
{
    parent = "Shoot",
    name = "LE Simulator",
    help = "Only uses FRSP",
depends_on = DEPENDS_ON.LIVEVIEW,
    submenu =
{
{
name = "Run Script",
help = "Does what it says after pressing SET",
depends_on = DEPENDS_ON.LIVEVIEW,
select = function(this) task.create(go) end,
},
{
name = "LE Time?",
help = "Simulated LE time in seconds",
min = 1,
           max = 600,
value = 1
},
{
name = "Delay",
help = "Delays script start by stated number of secs",
choices = {"2","5","0"},
},{
name = "Bookends?",
help = "Places a dark frame at start and end of focus bracket set",
choices = {"no","yes"},
}
}
}

Greg

  • Contributor
  • Hero Member
  • *****
  • Posts: 607
Re: Long Exposure Simulation via Shutterless FRSP
« Reply #1 on: May 21, 2016, 02:05:46 PM »
http://www.magiclantern.fm/forum/index.php?topic=12523.msg156393#msg156393

We need to understand how to work TwoAdd - http://www.magiclantern.fm/forum/index.php?topic=13408
With TwoAdd, we should get a shutter speed 1/camera_fps (currently limit is write speed).

Example 70D (7FPS) :
1/7s * 64frames = 10 seconds exposure (the image will be 3EV more DR).

garry23

  • Contributor
  • Hero Member
  • *****
  • Posts: 2218
Re: Long Exposure Simulation via Shutterless FRSP
« Reply #2 on: May 21, 2016, 02:10:26 PM »
@Greg

Yes I was aware of that approach, but I don't see how that approach would work if your base exposure was, say, 5s or 10s.

Or have I got is wrong?

Cheers

Garry

garry23

  • Contributor
  • Hero Member
  • *****
  • Posts: 2218
Re: Long Exposure Simulation via Shutterless FRSP
« Reply #3 on: May 21, 2016, 06:19:12 PM »
@Greg

Postscript

I must say I'm a little confused by your dynamic range comment.

If each exposure is the same, I can't see how you 'gain' DR. I could see how you might increase the S/N ratio, by reducing the noise by the stacking algorithm used, ie medium or mean, ie sqrt impact.

But I would love to be educated.


dmilligan

  • Developer
  • Hero Member
  • *****
  • Posts: 3218
  • 60Da / 1100D / EOSM
Re: Long Exposure Simulation via Shutterless FRSP
« Reply #4 on: May 21, 2016, 07:34:13 PM »
I can't see how you 'gain' DR. I could see how you might increase the S/N ratio
Gaining DR and increasing the SNR are the same thing. The "top" of the DR is limited by clipping point (white), the "bottom" of the DR is limited by noise. Lower the noise and you've increased the DR.

garry23

  • Contributor
  • Hero Member
  • *****
  • Posts: 2218
Re: Long Exposure Simulation via Shutterless FRSP
« Reply #5 on: May 21, 2016, 07:36:53 PM »
 :)