Okay, thank you a1ex!
Etiquette, expectations, entitlement...
@autoexec_bin | #magiclantern | Discord | Reddit | Server issues
This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.
Show posts Menu
cd test/magic-lantern
make -j2
cd platform
cd 600D*
make zip
#include <dryos.h>
#include <menu.h>
#include <bmp.h>
#include <lens.h>
#include <config.h>
#include <shoot.h>
#include <math.h>
#include <lvinfo.h>
#include <focus.h>
#include <property.h>
#include <module.h>
static int step_size = 1;
static float apertures_vector[] = {3.5, 4.0, 4.5, 5.0, 5.6, 6.3, 7.1, 8.0, 9.0, 10, 11, 13, 14, 16, 18, 20, 22};
static void dualBracketing()
{
//If lens.focus_distance is not at 250mm (closer focus/init position), then reset focus to init position.
if (lens_info.focus_dist > 25)
{
while (lens_info.focus_dist > 25) lens_focus(1, 3, 1, 1*10);
}
//Dual Bracketing loop
while (lens_info.focus_dist < lens_info.hyperfocal)
{
for(int i = 0; i < 17; i++)
{
lens_set_rawaperture(apertures_vector[i]); //Set aperture
lens_take_picture(64,false); //Take a picture
/*msleep(100); //sleep for 100ms
if (!lv) force_liveview(); //start LiveViev if turned off*/
}
lens_focus(-1, step_size, 1, 1*10); //Establir quin és el step_size òptim-->Quantes fotos necessitem per calcular depth map?
//step_size = 1 --> X photos
//step_size = 2 --> X photos
//step_size = 3 --> 6 photos
}
}
static int num_proba = 0;
static void proba()
{
lens_set_rawaperture(apertures_vector[num_proba]);
}
static struct menu_entry dualBr_menu[] =
{
{
.name = "Dual Bracketing",
.help = "Focus + Aperture Bracketing.",
.help2 = "Press Q to see the options.",
.depends_on = DEP_AUTOFOCUS,
.children = (struct menu_entry[]) {
{
.name = "Start Bracketing",
.priv = dualBracketing,
.select = run_in_separate_task,
.help = "For each step focus, does an aperture bracketing",
.help2 = "Press SET to start taking photos.",
},
{
.name = "Step Size",
.priv = &step_size,
.min = 1,
.max = 5,
.help = "Size of the focus step",
.help2 = "The smaller it is, the more pictures it take",
},
{
.name = "Proba",
.select = proba,
},
{
.name = "num_proba",
.priv = &num_proba,
.min = 0,
.max = 16,
},
MENU_EOL,
},
},
};
static unsigned int dualBr_init()
{
menu_add("Shoot", dualBr_menu, COUNT(dualBr_menu));
return 0;
}
static unsigned int dualBr_deinit()
{
return 0;
}
MODULE_INFO_START()
MODULE_INIT(dualBr_init)
MODULE_DEINIT(dualBr_deinit)
MODULE_INFO_END()
QuotePANIC: unprotected error in call to Lua API (not enough memory) abort
Page created in 0.097 seconds with 13 queries.