Author Topic: Crop mode recording (crop_rec.mo) (1:1, RAW/H.264, 25/30/50/60 fps)  (Read 224491 times)

D_Odell

  • Member
  • ***
  • Posts: 187
Re: Crop mode recording (crop_rec.mo) (1:1, RAW/H.264, 25/30/50/60 fps)
« Reply #300 on: February 11, 2017, 07:08:33 PM »
Ooooh. Thanks. By the way, how do you guys shoot in crop mode if your moving the camera around its gotta be super hard to frame your subject with so little of the actual image is seen in the camera's LCD screen? Is there a way to shoot in crop mode in camera but the video output to an external monitor would look regular, i.e. non-cropped?
For serious work, it only works with static shots, since there is right now no way to see 1:1 over 1080p in 3x3 crop mode. The super news and high fives would be when 3x3 crop works with higher resolutions like 24xx horizontal. Until the future, use a tripod if shooting crop, or zoom view.

5D3 (OLPF removed) :: 1.1.3 :: Canon FD L Serie

anto

  • New to the forum
  • *
  • Posts: 39
Re: Crop mode recording (crop_rec.mo) (1:1, RAW/H.264, 25/30/50/60 fps)
« Reply #301 on: February 11, 2017, 08:41:58 PM »


The super news and high fives would be when 3x3 crop works with higher resolutions like 24xx horizontal. Until the future, use a tripod if shooting crop, or zoom view.

It'll possible?
With somethings like 3x2 Bunning I think...


Inviato dal mio HTC One utilizzando Tapatalk


NikeFreak

  • Freshman
  • **
  • Posts: 59
Re: Crop mode recording (crop_rec.mo) (1:1, RAW/H.264, 25/30/50/60 fps)
« Reply #302 on: February 17, 2017, 11:44:42 AM »
for 6d and 650d has such a module?
6D ML + Sigma 24-70mm F2.8 + Canon 70-200mm F2.8L IS II + Canon 50mm F1.8 STM + Zenitar 16mm F2.8 + Canon SpeedLite 430EX II
650D ML + Canon 18-135mm F3.5-5.6 STM + Helios 44-2 58mm F2.0
500D ML + Canon 55-250mm F4-5.6 IS II + Canon 18-55 mm F3.5-5.6 IS

Quentin

  • Member
  • ***
  • Posts: 150
Re: Crop mode recording (crop_rec.mo) (1:1, RAW/H.264, 25/30/50/60 fps)
« Reply #303 on: March 06, 2017, 08:40:07 PM »
Today I shot several takes of 1920x490, 60FPS, 2.35 Aspect Ratio.
Ordinary shots were fine.
Some shots I used 3x Crop, the Aspect Ratio was different. A circle looks like an egg
I could see in the monitor the problem and I didnt examine what was recorded.
If I knew, I would swap a lens in order to zoom.

a1ex

  • Administrator
  • Hero Member
  • *****
  • Posts: 12564
Re: Crop mode recording (crop_rec.mo) (1:1, RAW/H.264, 25/30/50/60 fps)
« Reply #304 on: March 07, 2017, 04:52:00 PM »
Yes, Canon preview in 50/60fps modes that record square pixels (including the 3x crop mode) is squashed, as mentioned in the first post. The video recorded in raw should be fine (check with e.g. mlv_play).

Quentin

  • Member
  • ***
  • Posts: 150
Re: Crop mode recording (crop_rec.mo) (1:1, RAW/H.264, 25/30/50/60 fps)
« Reply #305 on: March 07, 2017, 05:53:59 PM »
Unfortunately the video recorded was not right.
BTW, I used 10 bit recording mode.

a1ex

  • Administrator
  • Hero Member
  • *****
  • Posts: 12564
Re: Crop mode recording (crop_rec.mo) (1:1, RAW/H.264, 25/30/50/60 fps)
« Reply #306 on: March 07, 2017, 06:15:14 PM »
Sample clip and steps to reproduce?

Quentin

  • Member
  • ***
  • Posts: 150
Re: Crop mode recording (crop_rec.mo) (1:1, RAW/H.264, 25/30/50/60 fps)
« Reply #307 on: March 08, 2017, 05:43:26 AM »
I use magiclantern-crop3x.2017Jan13.5D3113.zip
I set my Camera to NTSC Video System, 1280x720, 60FPS
I set the recording mode to RAW 1920x490 and Aspect Ratio to 2.35:1
in order to get continuous 60FPS. (I know that I need to stretch the result vertically by 1.67 in order to get 2.35:1)
I set 10bits mode.

Recoding like this is normal. The monitoring and the recording is as expected. Stretching it by 1.67 vertically makes it as expected.
When I set the Crop Mode to 3x, the preview Aspect Ratio is stretched.
Stretching the Recording result by 1.67 makes it unusable.

I erased the MLV files.
I only have DNGs.
Here is the first frame if this helps
https://drive.google.com/open?id=0B-d8ARtc7xwWU3JCQTRRTHFFV1E

a1ex

  • Administrator
  • Hero Member
  • *****
  • Posts: 12564
Re: Crop mode recording (crop_rec.mo) (1:1, RAW/H.264, 25/30/50/60 fps)
« Reply #308 on: March 08, 2017, 07:25:18 AM »
The DNG looks OK to me. The slight "distortion" in the circles' aspect ratio is because of camera position.

(I know that I need to stretch the result vertically by 1.67 in order to get 2.35:1)

There's your problem.

You need to stretch in regular 720p raw mode (with crop_rec turned off), but you do not need to stretch in 3x crop or in 3x3 1x.

Refer to this post for a visual explanation: http://www.magiclantern.fm/forum/index.php?topic=17021.msg179168#msg179168

Quentin

  • Member
  • ***
  • Posts: 150
Re: Crop mode recording (crop_rec.mo) (1:1, RAW/H.264, 25/30/50/60 fps)
« Reply #309 on: March 08, 2017, 08:26:35 AM »
Apologies for the confusion.
My intention was constructive

a1ex

  • Administrator
  • Hero Member
  • *****
  • Posts: 12564
Re: Crop mode recording (crop_rec.mo) (1:1, RAW/H.264, 25/30/50/60 fps)
« Reply #310 on: March 21, 2017, 01:34:04 AM »
Proposal for making crop info available to other modules (please review):
[...]

Done, please review. Experimental builds + updated mlv_dump available.

Relevant commits: structure, mlv.h entry, mlv_dump info display.

Metadata examples:
Code: [Select]
Block: RAWC
  Offset: 0x000000e8
    Size: 32
    Time: 0.769000 ms
    raw_capture_info:
      sensor res      5760x3840
      sensor crop     1.00
      sampling        5x3 (bin 5 lines, bin 3 columns)
Code: [Select]
      sampling        1x1 (read every line, read every column)
      sampling        1x3 (read every line, bin 3 columns)
      sampling        3x3 (bin 3 lines, bin 3 columns)
      sampling        5x3 (bin 5 lines, bin 3 columns)
      sampling        3x3 (read 1 line, skip 2, bin 3 columns)
      sampling        5x3 (read 1 line, skip 4, bin 3 columns)

Why I'm recording detailed info about binning/skipping modes? Maybe, at some point, somebody may come up with a custom debayering or super-resolution or whatever algorithm fine-tuned for Canon's pixel binning patterns. Knowing the exact binning pattern would definitely help in this case.

This info is recorded even if you don't use the crop_rec module (so it should probably be ported to regular nightlies as well).

DeafEyeJedi

  • Hero Member
  • *****
  • Posts: 3411
  • 5D3 | M1 | 7D | 70D | SL1 | M2 | 50D
Re: Crop mode recording (crop_rec.mo) (1:1, RAW/H.264, 25/30/50/60 fps)
« Reply #311 on: March 21, 2017, 01:44:04 AM »
This is excellent news and thanks for a great proposal!
5D3.113 | 5D3.123 | EOSM.203 | 7D.203 | 70D.112 | 100D.101 | EOSM2.* | 50D.109

Kharak

  • Hero Member
  • *****
  • Posts: 1025
Re: Crop mode recording (crop_rec.mo) (1:1, RAW/H.264, 25/30/50/60 fps)
« Reply #312 on: March 21, 2017, 01:52:35 AM »
So I was just dreaming about this a couple days ago..

If this is what I think it is e.g. artificially imposing resolution on to the Pixel Binned image by guessing or processing with an accurate algorithm the "missing pixels" in the 3x3 image?

once you go raw you never go back

bouncyball

  • Contributor
  • Hero Member
  • *****
  • Posts: 850
Re: Crop mode recording (crop_rec.mo) (1:1, RAW/H.264, 25/30/50/60 fps)
« Reply #313 on: March 21, 2017, 08:56:04 AM »
At last!!! :D

Great news! Thanks a1ex!

BR
bb

Danne

  • Developer
  • Hero Member
  • *****
  • Posts: 7659
Re: Crop mode recording (crop_rec.mo) (1:1, RAW/H.264, 25/30/50/60 fps)
« Reply #314 on: March 22, 2017, 07:43:17 PM »
:). Lovely metadata. It,s been missed.
Here is mlv_dump compiled for mac
https://bitbucket.org/Dannephoto/magic-lantern/downloads/mlv_dump_RAWC.zip

Tested crop_rec on eosm.
Eyecandy.
Code: [Select]
Block: RAWC
  Offset: 0x000000e8
    Size: 32
    Time: 0.808000 ms
    raw_capture_info:
      sensor res      5184x3456
      sensor crop     1.62
      sampling        3x3 (read 1 line, skip 2, bin 3 columns)

Quentin

  • Member
  • ***
  • Posts: 150
Re: Crop mode recording (crop_rec.mo) (1:1, RAW/H.264, 25/30/50/60 fps)
« Reply #315 on: April 03, 2017, 05:46:44 AM »
R E S P E C T !!!
Currently I have a project to shoot and I cannot risk installing the experimental features.
I am anxious to ...
Thanks

mk11174

  • Contributor
  • Hero Member
  • *****
  • Posts: 809
Re: Crop mode recording (crop_rec.mo) (1:1, RAW/H.264, 25/30/50/60 fps)
« Reply #316 on: April 03, 2017, 07:07:46 PM »
I am working on 700D with adtg.gui tool and found after adjusting
ADTG[8000c] to 0x0 gives the tall x3 preview
Then adjusting
CMOS 5 to 0x10 from 0x20 fixes tall stretch to normal 3x preview
CMOS 7 from 0x800 to 0x809 fixes vertical adjust
ADTG2[8000] needs to be set to 0x5 while in this mode or you get weird artifacts.
Cant find a way to adjust horizontal though.

One thing I noticed, is while in this mode, its offset so much, that the pixel dots are only an issue on the far lower right side.

3x mode 1080P Canon


Normal mode 1080P Canon
500D/T1i  550D/T2i  600D/T3i  700D/T5i

a1ex

  • Administrator
  • Hero Member
  • *****
  • Posts: 12564
Re: Crop mode recording (crop_rec.mo) (1:1, RAW/H.264, 25/30/50/60 fps)
« Reply #317 on: April 03, 2017, 07:43:57 PM »
CMOS 5 to 0x10 from 0x20 fixes tall stretch to normal 3x preview
Cant find a way to adjust horizontal though.

On 5D3, the same register adjusts both.

mk11174

  • Contributor
  • Hero Member
  • *****
  • Posts: 809
Re: Crop mode recording (crop_rec.mo) (1:1, RAW/H.264, 25/30/50/60 fps)
« Reply #318 on: April 03, 2017, 08:10:47 PM »
Right, just had to keep going, just found it at 0x390 on CMOS 5, now looks great!

Update to values for 3x 1080p/720 mode
CMOS 5 0x20 to 0x390 changes width so not tall stretched and horizontal
works on crop_rec module just fine
Code: [Select]
    if (is_700D)
    {
        switch (crop_preset)
        {
            /* 1:1 (3x) */
            case CROP_PRESET_3X:
                /* start/stop scanning line, very large increments */
                /* note: these are two values, 6 bit each, trial and error */
                cmos_new[7] = (is_720p())
                ? PACK12(12,9)
                : PACK12(10,10);
                cmos_new[5] = 0x390;    /* read every column, centered crop */
                break;
            case CROP_PRESET_3x3_1X:
                /* start/stop scanning line, very large increments */
                cmos_new[7] = (is_720p())
                ? PACK12(6,60)
                : PACK12(0,0);
                break;
        }
    }
500D/T1i  550D/T2i  600D/T3i  700D/T5i

Davipe

  • New to the forum
  • *
  • Posts: 4
Re: Crop mode recording (crop_rec.mo) (1:1, RAW/H.264, 25/30/50/60 fps)
« Reply #319 on: April 21, 2017, 06:48:32 PM »
I was searching but do not found nothing about:

I need to rec with 3x crop on a 5D2 in h.264, is possible?

thanks!!!

MarcusD

  • New to the forum
  • *
  • Posts: 2
Crop mode recording. Frame and block size mismatch, Memory patch error
« Reply #320 on: June 08, 2017, 10:28:31 AM »
Somehow the footage shot in crop mode is not working for me. Everything is working correctly with the Canon Firmware Version: 1.2.3 Latest Build: 2017-06-04 version. But the magiclantern-crop_rec_4k.2017Jun03.5D3 version shows green noise when imported.

* If I try to play the footage inside 5D Mark III cam I get a message frame and block size mismatch 0x684C00 0x20 0x357A00

* The debug mode show a third red dot (first 2 are green). Code FF290F98, EA395076 crop_rec
additional information in screen below: crop_rec: video timers hook

* When exported to computer and opened withe MLrawviewer, the program crashes
* When exported to computer and opened with Raw2DNG, I see a noisy green pattern instead of the video

**I've have tried with 113 and 123 versions. Both have the same problem.
*** different CF cards
*** with and without CROP mode active
**** set to 12 and 14bit lossless compression

WHEN SET TO PLAIN 14 BIT (NOT LOSSLESS) IT WORKS. But sadly the bitrate is to high for recording 3K continously with this setting.

Settings in camera are correct as far as I know.
- RAW video active, set to 3072 and aspect ratio 2:35:1
- Compression 12-bit lossless (14bit same problem)
- Crop mode n3.5K 1:1 centered x5
- Canon menu is set to PAL, 24fps 1920 ALL-I  (tried with IPB, same problem)

So hopefully anybody knows how to fix this, or knows what I'm doing wrong here;)

Cheers,
Marcus




dmilligan

  • Developer
  • Hero Member
  • *****
  • Posts: 3218
  • 60Da / 1100D / EOSM
Re: Crop mode recording (crop_rec.mo) (1:1, RAW/H.264, 25/30/50/60 fps)
« Reply #321 on: June 08, 2017, 08:59:48 PM »
Problem is you need to use an MLV converter that supports the new lossless compression.

MarcusD

  • New to the forum
  • *
  • Posts: 2
Re: Crop mode recording (crop_rec.mo) (1:1, RAW/H.264, 25/30/50/60 fps)
« Reply #322 on: June 09, 2017, 05:49:46 PM »
Hi dmilligan.

I just figured that out today. Everything is working fine now. Can record 3K continious in 14bit lossless. Somehow I must have missed the part of converting with MLV dump and Rawflow.

RAW2DNG and MLrawviewer will not work with these new compression MLV files.

Thanks!

(Should I delete my post?)

etienne

  • New to the forum
  • *
  • Posts: 14
Re: Crop mode recording (crop_rec.mo) (1:1, RAW/H.264, 25/30/50/60 fps)
« Reply #323 on: July 20, 2017, 04:24:43 PM »
Hi all,

Is there a way to get 14bits losseless in one of the branches that support crop mode x3 & MLV sound in HD no need for higher resolution.

It seems that only the 4k Branch gets the lossless choices but this one as no MLV sound available... Am i wrong? Any other way?

budafilms

  • Hero Member
  • *****
  • Posts: 711
  • 5D Mark a1ex
Re: Crop mode recording (crop_rec.mo) (1:1, RAW/H.264, 25/30/50/60 fps)
« Reply #324 on: July 25, 2017, 08:02:40 AM »
Please, ML Team, add NO SOUND to the screen, to modules nightly or experimental, when the sound is not recording.
Lot of problems here, and headphones works even without MLV SOUND.