You can see this script in action on my blog:
www.armanbohn.com/blogClick on the camera scripts category.
NOTE:
You must use PhyrePhox's build in order to generate random numbers!!!!
Get it here:
http://chdk.setepontos.com/index.php/topic,978.0.htmlThis code will "wobble" the focus a random amount each frame. You can set the max. limit of the wobble and number of frames to shoot.
You need to set the focus manually before running the script.
It gives a nice, chaotic pulse to the focus.
@title Focus Wobble
@param a Focus wobble +/- (mm)
@default a 50
@param b # of frames
@default b 48
a=a*2
get_focus f
print "Current focus ",f,"mm"
sleep 2000
g=f
for s = 1 to b
random z
x=z%(a)
g=f-(a/2)+x
if g<0 then let g=0
set_focus g
print "Shot ",s," focus ",g,"mm"
shoot
next s