Last active
July 4, 2019 14:55
-
-
Save Jip-Hop/688253710f25d3a0ff008f908241d1b0 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
-- Crop mode toggle | |
-- Toggle between 3x crop mode | |
require('config') | |
-- end this script if not eosm | |
if camera.model_short ~= "EOSM" then | |
display.notify_box("Script not working on this cam"); | |
msleep(2000); | |
return | |
end | |
-- warnings | |
while camera.mode ~= MODE.MOVIE do | |
display.notify_box("enable MOVIE mode"); | |
msleep(1000); | |
end | |
function toggle_x3crop() | |
-- console.show(); | |
local recording = movie.recording; | |
if recording == true then | |
display.notify_box("STOPPED RECORDING"); | |
movie.stop(); | |
end | |
-- crop mode | |
if menu.get("Crop mode", "x3crop") == "x3crop" then | |
display.notify_box("DISABLED X3CROP"); | |
menu.set("Crop mode", "x3crop", 0); | |
else | |
display.notify_box("ENABLED X3CROP"); | |
menu.set("Crop mode", "x3crop", "x3crop"); | |
end | |
lv.pause(); | |
lv.start(); | |
if recording == true then | |
local max_tries = 40 | |
while max_tries > 0 do | |
max_tries = max_tries - 1 | |
msleep(100) | |
movie.start(); | |
if(movie.recording == true) then | |
display.notify_box("RESTARTED RECORDING"); | |
break | |
end | |
end | |
end | |
end | |
x3crop_toggle_menu = menu.new | |
{ | |
parent = "Movie", | |
name = "x3crop toggle", | |
help = "Pick a button to toggle x3crop in mv1080.", | |
value = 0, | |
submenu = | |
{ | |
{ | |
select = function(this) | |
if x3crop_toggle_menu.value == 0 then | |
x3crop_toggle_menu.value = 1; | |
else | |
x3crop_toggle_menu.value = 0; | |
end | |
end, | |
update = function(this) | |
if x3crop_toggle_menu.value == 0 then | |
this.name = "Enable"; | |
else | |
this.name = "Disable"; | |
end | |
end, | |
}, | |
{ | |
name = "Button", | |
choices = { "SET", "INFO", "HALFSHUTTER"}, | |
} | |
}, | |
update = function(this) | |
if this.value == 0 then | |
this.help2 = "Click Enable in submenu to activate."; | |
return "OFF"; | |
else | |
this.help2 = "" | |
return "ON, " .. this.submenu["Button"].value; | |
end | |
end, | |
}; | |
config.create_from_menu(x3crop_toggle_menu) | |
event.keypress = function(key) | |
if key == KEY[x3crop_toggle_menu.submenu["Button"].value] and menu.visible == false and x3crop_toggle_menu.value ~= 0 then | |
task.create(toggle_x3crop); | |
return false; | |
end | |
end | |
console.hide(); |
Glad you like it. I think info button is the best one too. I personally never use the info screen. Can set most settings using the button on camera. Iso can be set with the trash button I think (it's a Canon menu preference. But I agree it's not so nice to completely block the info screen. But I don't like double and long press either for frequent use. So I suggest to toggle the x3crop toggle setting with a long or double press. So e.g. long press info button to disable the x3crop toggle, then use info button as normal with single press. Then long press info to activate x3crop toggle again. Now just single press to toggle crop mode.
If this is too complicated, confusing or not possible then I'd always opt to keep the crop toggle as quick and responsive as possible and map the usual info button to the slower option (long press or double press). Because using the info screen is the task that takes longer anyway (need to manually dive into the settings on that screen etc.).
… Op 4 jul. 2019 om 10:14 heeft dannephoto ***@***.***> het volgende geschreven:
Really nice work on this. I like the INFO button and I think it´s the better button to use. One thing with this button though is that it also has a lot of goodies such as iso and also other general purpose settings tht we no longer acces once the button is reassigned. Suggestion. Short press still let´s us go into info screen. A longer push(maybe 0.5s) instead enters x3 toggle.
Another idea is to run a double push to access x3 toggle. One push would enter INFO screen.
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub, or mute the thread.
Also I didn't test what happens if you toggle x3crop while recording. Probably things will go wonky. I'd need to check if currently recording, if so stop recording, toggle crop, start new recording.
… Op 4 jul. 2019 om 10:14 heeft dannephoto ***@***.***> het volgende geschreven:
Really nice work on this. I like the INFO button and I think it´s the better button to use. One thing with this button though is that it also has a lot of goodies such as iso and also other general purpose settings tht we no longer acces once the button is reassigned. Suggestion. Short press still let´s us go into info screen. A longer push(maybe 0.5s) instead enters x3 toggle.
Another idea is to run a double push to access x3 toggle. One push would enter INFO screen.
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub, or mute the thread.
Yes, wonky time, recording stops so a watch guard while recording needed too.
What's ETC by the way? Maybe rename it to CMT?
What it means? Extended Tele Conversion. That's how a similar feature is called on some Panasonic cameras. Also I seemed to run into issues using a number (3), don't remember if it was filename, variable name or description for lua script in ML menu. So named it ETC.
… Op 4 jul. 2019 om 11:52 heeft dannephoto ***@***.***> het volgende geschreven:
Yes, wonky time, recording stops so a watch guard while recording needed too.
What ETC by the way?
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub, or mute the thread.
Hehe, I see. Yes, nunbers and also length is problematic. No more than eight characters I think.
Should now restart movie recording more or less as quick as it can when you toggle x3crop while recording.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Really nice work on this. I like the INFO button and I think it´s the better button to use. One thing with this button though is that it also has a lot of goodies such as iso and also other general purpose settings tht we no longer acces once the button is reassigned. Suggestion. Short press still let´s us go into info screen. A longer push(maybe 0.5s) instead enters x3 toggle.
Another idea is to run a double push to access x3 toggle. One push would enter INFO screen.
In my c-code equivalent I keep a 0.5 sec delay since then halfpress shutter button also can access magic zoom etc.