Author Topic: 12-bit (and 10-bit) RAW video development discussion  (Read 627911 times)

Levas

  • Contributor
  • Hero Member
  • *****
  • Posts: 1685
  • 6d - Nightly build user
Re: 12-bit (and 10-bit) RAW video development discussion
« Reply #850 on: December 23, 2016, 01:53:46 PM »
 :o
I tried the latest resolution values with this dma flag in edmac-memcpy.c

uint32_t dmaFlags = 0x60000000

And looks like we have working live view and NORMAL FRAMES on 6d 
 :D :D :D :D :D :D :D :D :D :D :D

I'll test some more, to be really sure it works  ;D


Levas

  • Contributor
  • Hero Member
  • *****
  • Posts: 1685
  • 6d - Nightly build user
Re: 12-bit (and 10-bit) RAW video development discussion
« Reply #851 on: December 23, 2016, 02:16:20 PM »
Yep, 10 bit recording works flawlessly on the 6d, with live view :D

Although with 12 bit recording something weird is still going on (as mentioned before in this topic).
with 12 bit recording MLV_dump finds a lot of cold pixels and the image has specles all over it.

nikfreak

  • Developer
  • Hero Member
  • *****
  • Posts: 1186
Re: 12-bit (and 10-bit) RAW video development discussion
« Reply #852 on: December 23, 2016, 02:26:31 PM »
congrats Levas. Was worth all your efforts and guess it feels great making yourself a xmas gift. Submitting a PR @bitbucket will make it perfect  :P
70D.112 & 100D.101

Danne

  • Developer
  • Hero Member
  • *****
  • Posts: 7141
Re: 12-bit (and 10-bit) RAW video development discussion
« Reply #853 on: December 23, 2016, 02:26:53 PM »
Wow. Beautiful work on the 6D everyone and Levas :).

Maybe needless to say but are you disabling cold pixel and vertical stripes settings in mlv_dump?
http://www.magiclantern.fm/forum/index.php?topic=5601.msg176263#msg176263

Levas

  • Contributor
  • Hero Member
  • *****
  • Posts: 1685
  • 6d - Nightly build user
Re: 12-bit (and 10-bit) RAW video development discussion
« Reply #854 on: December 23, 2016, 02:40:54 PM »
@Alex
uint32_t dmaFlags = 0x40000000
Works too, so before it didn't probably work because of the wrong resolution settings.

@Nikfreak
Submitting @bitbucket, what do you think I am, a developer  :P
And my coding skills aren't that good,in order to use the right dmaFlags my version, for sure, won't work for some other cams that worked before ;D

@Danne
You're right, disabling stripe fix and cold pixel fix gives good frames.
But I always thought the stripe fix was nessecarry  ?


eNnvi

  • New to the forum
  • *
  • Posts: 48
  • 700D
Re: 12-bit (and 10-bit) RAW video development discussion
« Reply #855 on: December 23, 2016, 02:46:17 PM »
Could you also try with edmac flags of 700D?

Levas

  • Contributor
  • Hero Member
  • *****
  • Posts: 1685
  • 6d - Nightly build user
Re: 12-bit (and 10-bit) RAW video development discussion
« Reply #856 on: December 23, 2016, 03:33:31 PM »
@eNnvi
I've tried the following dma flag as used for 700d
uint32_t dmaFlags = 0x20000000

And it causes the 'RAW DETECT ERROR' and when it will record it gives the scrambled frames.

So the only settings that were wrong in your build are the height value settings for the different video modes (width values were all good)
#ifdef CONFIG_6D
    *width  = zoom ? 2768 : mv720 ? 1920 : 1920;
    *height = zoom ? 988 : mv720 ?  662 : 1252;    /* find correct mv720 height -- must be exact! */   
    return 1;
#endif

And the dma flag setting, which must be either
uint32_t dmaFlags = 0x40000000 or uint32_t dmaFlags = 0x60000000

nikfreak

  • Developer
  • Hero Member
  • *****
  • Posts: 1186
Re: 12-bit (and 10-bit) RAW video development discussion
« Reply #857 on: December 23, 2016, 03:46:51 PM »
70D.112 & 100D.101

Levas

  • Contributor
  • Hero Member
  • *****
  • Posts: 1685
  • 6d - Nightly build user
Re: 12-bit (and 10-bit) RAW video development discussion
« Reply #858 on: December 23, 2016, 03:51:02 PM »
Yes confirmed, both values work

Levas

  • Contributor
  • Hero Member
  • *****
  • Posts: 1685
  • 6d - Nightly build user
Re: 12-bit (and 10-bit) RAW video development discussion
« Reply #859 on: December 23, 2016, 03:59:31 PM »
Is somebody willing to do a pull request for this for the 6d?

I can send the pieces of code that needs to be altered/added in a pm.

dfort

  • Developer
  • Hero Member
  • *****
  • Posts: 3751
Re: 12-bit (and 10-bit) RAW video development discussion
« Reply #860 on: December 23, 2016, 04:40:05 PM »
Is somebody willing to do a pull request for this for the 6d?

Sure, no problem. Let's get some developers reviewing the changes you and eNnvi made and post a test build for other 6D users.

@nikfreak -- do you have a branch in your repo that I can use to make test builds for the 70D and 100D?

Off topic -- Just a suggestion. It would be great to get those platforms merged and perhaps prune the branch for the 1100D if that platform is no longer supported.

[EDIT]
Back on topic -- so if CONFIG_EDMAC_RAW_SLURP was working on the 1100D at one time why was it removed? Seems like that camera could really use the 10bit/12bit treatment though at this point it doesn't work at all with raw video.
5D3.* 7D.206 700D.115 EOSM.203 EOSM2.103 M50.102

nikfreak

  • Developer
  • Hero Member
  • *****
  • Posts: 1186
Re: 12-bit (and 10-bit) RAW video development discussion
« Reply #861 on: December 23, 2016, 06:36:28 PM »
just updated the 100D PR.
70D PR should already contain all relevant info needed as far as I remember.

Wishing ya fun.
70D.112 & 100D.101

RenatoPhoto

  • Moderators
  • Hero Member
  • *****
  • Posts: 1509
  • 5DM3 / 7D
Re: 12-bit (and 10-bit) RAW video development discussion
« Reply #862 on: December 23, 2016, 07:49:24 PM »
You guys are amazing with the improvements upon the great foundations of Magic Lantern.
Thanks to all and congratulations on this new breakthrough!

I use the 1.23 firmware so finally I had a little time to test it with magiclantern-raw_video_10bit_12bit.2016Dec20.5D3123.zip (great work dfort)
WOW! WOW! WOW!
I tested the mlv_rec and raw_rec with the raw_twk.  Great accomplishments here dfort, g3gg0, and all contributors!

Video quality:  I cannot see any difference at iso 6400 or at iso 100.  All of them look superb on 10/12/14 bits.
Video size: Amazing 40% lighter dng frames going from 14 bits to 10 bits.  Pixel peeping the dngs at 300% show no difference between 10/12/14 bit!
Color and Exposure are identical.  Bumping exposure by 3ev on Photoshop does not bring up any differences on shadows.

Standard Max Recording Resolutions 5D3 with 64 GB Lexar 1066:
Origninal mlv_rec + spanning + Auto preview + sound at 1920x1080 30fps same with crop module: 17 sec max recording
Original mlv_rec + Auto preview + sound at 1920x1080 30fps with crop module: 17 sec max recording
Original raw_rec + Auto preview at 1920x1080 30fps same with crop module: 23 sec max recording

10/12/14 BIT TESTING
With magiclantern-raw_video_10bit_12bit.2016Dec20.5D3123
Note: I cannot find the card spaning on new mlv_rec

14 bit
mlv_rec + canon preview + sound at 1920x1080 30fps same with crop module: 16 seconds recording time
raw_rec + canon preview 23 sec at 1920x1080 30fps: 23 seconds recording time
raw_rec + canon preview 32 sec at 1920x1080 30fps at 5x croped: 35 seconds recording time!! dont know why the croped records faster.

12 bit
mlv_rec + Auto preview + sound at 1920x1080 30fps: continuous recording
mlv_rec + Auto preview + sound at 1920x1080 30fps at 5X cropped: continuous recording
Max continuous recording mlv_rec + Auto preview + sound at 1952x1098 or smaller at 30fps

raw_rec + canon preview 23 sec at 1920x1080 30fps: continuous recording
raw_rec + canon preview 32 sec at 1920x1080 30fps at 5x croped: continuous recording
Max continuous recording raw_rec Continuous recording with 2000x1126 30fps or smaller resolutions.

note: mlv_play crashes (play quits and camera has some error since the red led keeps blinking) on crop video larger than 1968x1108

10bit
Max continuous recording mlv_rec + Auto preview + sound at 2144x1206 or smaller resolutions at 30fps.
Max continuous recording raw_rec Continuous recording with 2208x1242 or smaller resolutions at 30fps.

Although I do not contribute to the forum due to time constrains I do come here all the time and look for all the updates on 5D3 1.23.  I use my 5D3 often and take lots of bird photos and RAW video.
I truly enjoy all of the amazing things you guys accomplish.  It is stunning!
THANK YOU!  THANK YOU!  THANK YOU!
Merry Christmas and happy new year to all!
http://www.pululahuahostal.com  |  EF 300 f/4, EF 100-400 L, EF 180 L, EF-S 10-22, Samyang 14mm, Sigma 28mm EX DG, Sigma 8mm 1:3.5 EX DG, EF 50mm 1:1.8 II, EF 1.4X II, Kenko C-AF 2X

eNnvi

  • New to the forum
  • *
  • Posts: 48
  • 700D
Re: 12-bit (and 10-bit) RAW video development discussion
« Reply #863 on: December 23, 2016, 07:55:26 PM »
pull request for 6D done.

now i'll try to work in 7D (i like the hard things ;) ). As i don't own one i have to ask if anybody want to help me (possibly having that camera :D )

dfort

  • Developer
  • Hero Member
  • *****
  • Posts: 3751
Re: 12-bit (and 10-bit) RAW video development discussion
« Reply #864 on: December 23, 2016, 08:07:17 PM »
Looks like @a1ex already merged the 6D pull request, that was fast.

There's also another change I didn't see coming. The 700D now has "#define PREFERRED_RAW_TYPE 0x10" while the 650D still has "#define PREFERRED_RAW_TYPE 78" commented out. They both used to be commented out. What's the reason for that?
5D3.* 7D.206 700D.115 EOSM.203 EOSM2.103 M50.102

a1ex

  • Administrator
  • Hero Member
  • *****
  • Posts: 12564
Re: 12-bit (and 10-bit) RAW video development discussion
« Reply #865 on: December 23, 2016, 08:11:56 PM »
Back on topic -- so if CONFIG_EDMAC_RAW_SLURP was working on the 1100D at one time why was it removed?

It wasn't removed. There are some missing bits from the raw branch (such as skip offsets), so the branch wasn't merged. Start reading from here; some of those bits are already there and just need to be put together in a commit.

dfort

  • Developer
  • Hero Member
  • *****
  • Posts: 3751
Re: 12-bit (and 10-bit) RAW video development discussion
« Reply #866 on: December 23, 2016, 08:45:11 PM »
Thanks for the tips. Danne has access to an 1100D so we might team up and work on it, though it isn't a high priority for either of us.

Just noticed the 1100D build was broken for about one week, and nobody reported the error.
Is there anybody still using this camera, or should I discontinue this port?

So it wasn't intentional?@dmilligan also has one but it looks like he isn't using it much these days - and there's a math problem:

The 1100D nightly build was intentionally disabled because a1ex noticed some incorrect values for FPS override timers. I've never cared enough to try and fix it (the Maths involved hurt my head :P ), I just compile it with the old incorrect values.

Getting the 1100D working isn't my goal, I'm just trying to get a better understanding of ML and looking at CONFIG_EDMAC_RAW_SLURP on that camera opened this can of worms. In any case, years ago I did some beta testing and the company sent me their lowest end system. Why not their most powerful? Because they wanted to make sure their minimal configuration was still valid or if they should discontinue support for it.
5D3.* 7D.206 700D.115 EOSM.203 EOSM2.103 M50.102

dfort

  • Developer
  • Hero Member
  • *****
  • Posts: 3751
Re: 12-bit (and 10-bit) RAW video development discussion
« Reply #867 on: December 23, 2016, 08:59:54 PM »
6D added to the test builds:

https://bitbucket.org/daniel_fort/magic-lantern/downloads

Make sure to load the raw_twk module if you want in camera playback of 10/12 bit files.
5D3.* 7D.206 700D.115 EOSM.203 EOSM2.103 M50.102

dfort

  • Developer
  • Hero Member
  • *****
  • Posts: 3751
Re: 12-bit (and 10-bit) RAW video development discussion
« Reply #868 on: December 24, 2016, 12:40:39 AM »
just updated the 100D PR.
70D PR should already contain all relevant info needed as far as I remember.

Thanks. 100D was pretty much ready. Merged the 70D_merge_fw112 branch with raw_video_10bit_12bit.

Test builds for 100D and 70D posted.

https://bitbucket.org/daniel_fort/magic-lantern/downloads
5D3.* 7D.206 700D.115 EOSM.203 EOSM2.103 M50.102

dmilligan

  • Developer
  • Hero Member
  • *****
  • Posts: 3218
  • 60Da / 1100D / EOSM
Re: 12-bit (and 10-bit) RAW video development discussion
« Reply #869 on: December 24, 2016, 01:20:47 AM »
So it wasn't intentional?
1100D has been broken multiple times in the past, sometimes on purpose, sometimes on accident. It is currently broken on purpose. The 1100D was probably the easiest platform to break on accident because of its unusual combination of CONFIG options enabled (so not being careful about #ifdefs would be more likely to result in code that won't compile without being noticed, for example 1100D could do QR raw but not LV raw, but there's a lot of shared code between the two).

andy kh

  • Hero Member
  • *****
  • Posts: 535
Re: 12-bit (and 10-bit) RAW video development discussion
« Reply #870 on: December 24, 2016, 02:19:27 AM »
[quote Merged the 70D_merge_fw112 branch with raw_video_10bit_12bit.

Test builds for 100D and 70D posted.

https://bitbucket.org/daniel_fort/magic-lantern/downloads
[/quote]

i wil be able to test 70D tonight after reaching home. Thank q dfort. I have been waiting for so long
5D Mark III - 70D

ShootMeAlready

  • Senior
  • ****
  • Posts: 264
Re: 12-bit (and 10-bit) RAW video development discussion
« Reply #871 on: December 24, 2016, 09:04:52 AM »
70D tried a quick test.

1832@ 2.35 apsect, 24fps 10bit, could record for over 1 minute (probably continuous), the movie review but it never builds the movie because it hangs/bricks requiring battery pull and two resets to get right.
1832@ 2.35 aspect, 30fps 10bit, could record for 18s, but same hang/brick.
1832@ 2.35 aspect, 24fps 12bit, could record for 28s, but same hang/brick. 
1846@ 2.35 aspect, 60fps 12bit, 3X mode on, could record for 9s, but same hang/brick.
1920@ 2.35 aspect, 24 fps 10bit, 5X zoom, could record for over 1 minute (probably continuous), two second in got a "hack error" but it kept on recording until I hit stop rec.,  but same hang/brick occurs. Not sure with hack error to trust the record time.
2220 @2.35 aspect, 24 fps 10bit, 5Xzoom,  hack error at 0 sec kept recording over 1 minute, but when I switched to photo mode it showed 51 sec record, so I cant trust either number.

It did produce MLV files, but Mystic could not convert any MLV to DNG.  This same program worked with my 600D 10/12 bit MLV files.
Will try mlv_dump on the files once I have more time. 
T3i+ML & 70D.112+ML, Tokina 11-16 2.8, Sigma 18-35 1.8, 50-150 II 2.8, 50 1.4, Canon 28 1.8, 35 2, 85 1.8 "Shoot Wide and Prosper"

Oswald

  • Freshman
  • **
  • Posts: 67
  • 7D & Eos M & 100D.100B
Re: 12-bit (and 10-bit) RAW video development discussion
« Reply #872 on: December 24, 2016, 09:54:03 AM »
Live view still freezes with 100d. I just tested it. I downloaded the @dfort build.  :)
7D, EOS-M & 100D.100b ΒΆ  Sigma 18-35mm, Canon 50mm F1.8, 22 STM, 8-48mm f1.0, 18-55 EF-M STM

nikfreak

  • Developer
  • Hero Member
  • *****
  • Posts: 1186
Re: 12-bit (and 10-bit) RAW video development discussion
« Reply #873 on: December 24, 2016, 11:40:12 AM »
dfort probably didn't enable edmac_raw_slurp before compiling for 100d. Just a guess as I didn't try myself.
70D.112 & 100D.101

dariSSight

  • Member
  • ***
  • Posts: 163
Re: 12-bit (and 10-bit) RAW video development discussion
« Reply #874 on: December 24, 2016, 01:19:51 PM »
@dfort and @reddeercity for your help to make 5D Mark II even better, which build is the best so far Dec1, Dec12, or Dec18  I never got Dec9? I had some corruption with Dec18 but I'm going to do some more test, also will there be a update build from @dfort for 5DMarkIi soon?
Canon 5D Mark II