Author Topic: [SOLVED] CropMarks in zoomed Liveview ?  (Read 797 times)

deufrai

  • New to the forum
  • *
  • Posts: 7
[SOLVED] CropMarks in zoomed Liveview ?
« on: June 27, 2018, 11:05:06 AM »
Hi everyone

I'm a happy ML user for years now. First on a 550D and now on a 70D for almost 3 years.

As my needs change, so do my experimentations and questionning. Here's one for you guys :
I need to have cropmarks visible in LiveView even when I zoom into the liveView.

I was running an old 2015 build and just upgraded my ML to magiclantern-Nightly.2018Feb17.70D112. I cannot find a may to achieve what I just described.
Is this a feature that would need to be implemented ?

Thanks in advance for any hint and many more for this great project that saved me bucks and time for all these years

a1ex

  • Administrator
  • Hero Member
  • *****
  • Posts: 12224
  • Maintenance mode
Re: CropMarks in zoomed Liveview ?
« Reply #1 on: June 27, 2018, 11:44:50 AM »
If you enable raw video recording, the x5 zoom will act somewhat like regular LiveView (it allows you to record with 1:1 crop). That means, it will show the regular overlays, including cropmarks.

If you need the cropmarks to be zoomed in and moved together with the x5 image, that's a bit more difficult. First, they are bitmaps at the screen resolution (720x480), so magnifying them 5 times will not look very nice; they will not be very accurate either. Can be solved by implementing vector cropmarks. Second, finding the exact position of the zoomed window, relative to the entire sensor area, is a bit of hit and miss, possibly with model-specific quirks, so knowing where exactly to draw the zoomed cropmarks is not straightforward. That might be doable with some reverse engineering, if you have the patience to do the pixel peeping needed to align the images (x5 on top of x1), but I'm not sure it's worth the effort.

deufrai

  • New to the forum
  • *
  • Posts: 7
Re: CropMarks in zoomed Liveview ?
« Reply #2 on: June 27, 2018, 11:56:17 AM »
Thanks for the quick reply.

Something I did not mention, sorry, is that I'm in need of cropmarks when shooting stills.
And zoom box location / cropmark location  accuracy is not a main issue here

I will explain my workflow, and again, sorry, I should have made all this clear in the first post

I'm shooting astrophotography with the DSLR hooked to a motorizer equatorial mount.
In order to calibrate the mount I need to proceed with a few steps for which I need to have a fixed and repeatable reference point on the LV screen while LV is zoomed 10x.

I could use some (softly) adhesive tape put on the screen during this . Was just curious if this could be done with the ML cropmarks

a1ex

  • Administrator
  • Hero Member
  • *****
  • Posts: 12224
  • Maintenance mode
Re: CropMarks in zoomed Liveview ?
« Reply #3 on: June 27, 2018, 12:18:42 PM »
The x10 zoom is meant for focusing, so all overlays are disabled by default. Rather than adding yet another option in the menu for this particular use case, you may consider a Lua script that draws the "adhesive tape" on the screen when the zoom is set to x10.

This could be a good starting point (even though it was initially meant as a joke, it's a nice example):
https://www.magiclantern.fm/forum/index.php?topic=17574.0

deufrai

  • New to the forum
  • *
  • Posts: 7
Re: CropMarks in zoomed Liveview ?
« Reply #4 on: June 27, 2018, 01:23:18 PM »
That could indeed serve the purpose
So .... Diving into LUA scripting

I'll report progress

Thanks again for your prompt replies and usefull pointers !

deufrai

  • New to the forum
  • *
  • Posts: 7
Re: CropMarks in zoomed Liveview ?
« Reply #5 on: June 27, 2018, 04:48:44 PM »
OK
I started looking at https://davidmilligan.github.io/ml-lua/index.html

I'm not asking for fish, here, just needed some advice about my plan, i.e. :
Have my LUA define some sort of event handler for keypress(KEY.ZOOMIN) and check
Code: [Select]
lv.enabled == true and lv.zoom == 10. If true => draw my target/crosshair on top of LV

Does that sound good ?

deufrai

  • New to the forum
  • *
  • Posts: 7
Re: CropMarks in zoomed Liveview ?
« Reply #6 on: June 27, 2018, 05:53:55 PM »
Any advice on this first shot will be much appreciated
See : https://github.com/deufrai/ML_lua_utils/blob/v0.1/lvzoomch.lua

a1ex

  • Administrator
  • Hero Member
  • *****
  • Posts: 12224
  • Maintenance mode
Re: CropMarks in zoomed Liveview ?
« Reply #7 on: June 27, 2018, 06:39:41 PM »
What happens here is:

- you are in x5 mode
- you press the Zoom In button
- your event.keypress handler gets invoked and displays the marker
- the key event is then passed to Canon firmware, which switches to x10
- I'd expect Canon code to redraw the display in the process, but luckily it doesn't (or maybe it's model-specific)

If you have redraw issues, you could use the seconds_clock event, called periodically every second. That would keep redrawing the marker, just in case something else erases it.

Otherwise, it's pretty good. You could extend the script to move the marker with the keys, since you already figured out how to handle them.

deufrai

  • New to the forum
  • *
  • Posts: 7
Re: CropMarks in zoomed Liveview ?
« Reply #8 on: June 27, 2018, 06:52:34 PM »
I'll test this longer to mimic my real life scenario (~ 10mn of uninterrupted zoomed LV without touching anything on the camera) to see if some other event redraws on top of the marker

If I go the seconds_clock way, I guess 'll have to move all the tests (are we in photo + liveview + 10x zoom) in the draw_target() function to avoid drawing at the wrong moment

And marker move is not needed. The whole idea is to move the mount so my reference real life objects (i.e. stars) line up with the drawn marker

Thanks again for your valuable input

deufrai

  • New to the forum
  • *
  • Posts: 7
[SOLVED] CropMarks in zoomed Liveview ?
« Reply #9 on: June 28, 2018, 05:29:52 PM »
OK, Final touch to the script is done

It will continue to live here : https://github.com/deufrai/ML_lua_utils

Thanks again