12 to 24 fps (FPS override Problem)

Started by Magiclanterner, April 14, 2015, 05:35:18 PM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

Magiclanterner

Hi everyone
I apologize in advance if I did not express myself well because I am french.

With my Canon EOS M I can shoot in RAW 1280x720 continuously but I wish I could shoot in 1792x1008 more than two seconds so I spent the whole night on the forum and I saw that it was possible to film 12 fps and recreate the missing frames with Twixtor .
So I immediately tried activating the FPS override function and selecting 12 fps and optimized for exact fps.

But I have two problems :
-My exposure is good (f/11; 1/250 shutter; and ISO 160) and when when I enable FPS override feature the exposure change : It's completely overexposed, even if I change the shutter speed the exposure is the same and the histogram don't change.
-The second problem is that when I chose optimizeed for exact fps I have a black bar on the right side of my video while that does not appear in the low light mode.

Thank you in advance
Magiclanterner

DeafEyeJedi

5D3.113 | 5D3.123 | EOSM.203 | 7D.203 | 70D.112 | 100D.101 | EOSM2.* | 50D.109

a1ex

Quote from: Magiclanterner on April 14, 2015, 05:35:18 PM
-The second problem is that when I chose optimizeed for exact fps I have a black bar on the right side of my video while that does not appear in the low light mode.

This one is a bug. Looking in the code history, Coutts ported it from Tragic Lantern without trying it, and FPS_TIMER_A_MIN/FPS_TIMER_B_MIN are completely bogus. I actually wonder why it works...

To fix it, set FPS_TIMER_A_MIN and FPS_TIMER_B_MIN to a very low value, then, for each video mode, find the lowest timer value which still gives a good image without artifacts (by trial and error, starting from default FPS, fine-tune one timer manually from ML menu). The good news is that those timers are independent (timer A gives the time to read one line, and timer B gives the time for the entire frame - see comments in rolling_shutter_print). Watch out for the vertical black bar on the right side (visible especially in RAW). Usually, the minimum timer value is a few units below the default value.

Note that video modes on EOS-M are different when recording and when not, unlike all other cameras.

vertigopix

Sorry, want to help but i can't get it...

QuoteTo fix it, set FPS_TIMER_A_MIN and FPS_TIMER_B_MIN to a very low value, then, for each video mode, find the lowest timer value which still gives a good image without artifacts (by trial and error, starting from default FPS, fine-tune one timer manually from ML menu). The good news is that those timers are independent (timer A gives the time to read one line, and timer B gives the time for the entire frame - see comments in rolling_shutter_print). Watch out for the vertical black bar on the right side (visible especially in RAW). Usually, the minimum timer value is a few units below the default value.

Note that video modes on EOS-M are different when recording and when not, unlike all other cameras.

1. Cleared all ML settings. (to be clean)
2. Canon Movie mode, 1920x1080p25, Manual.
3. Enabled FPS Override in ML : 30 (from 30), exact FPS
4. Started recording H.264
5. Opened ML menu while recording and started to play with FPS timer A and FPS timer B

But no change or artifacts noticed on the LV image.

What i'm doing wrong ?

a1ex

Did you notice any change on Actual FPS in menu?

If yes, just keep decreasing timer value. At some point, one of those should happen:
- Actual FPS no longer changing (that means, FPS_TIMER_*_MIN can be defined to a lower value)
- image artifacts appear (in this case, write down the timer value)

vertigopix

Yes.

Quote- Actual FPS no longer changing (that means, FPS_TIMER_*_MIN can be defined to a lower value)

FPS timer A : 520 (FT-12)
FPS timer B : 1970 (FT-81)


vertigopix

Have tried to reproduce this :

QuoteBut I have two problems :
-My exposure is good (f/11; 1/250 shutter; and ISO 160) and when when I enable FPS override feature the exposure change : It's completely overexposed, even if I change the shutter speed the exposure is the same and the histogram don't change.

For me everything is working, i can change the aperture or shutter and the histogram is changing accordingly. (i have expo. Override enabled)

vertigopix

And the black bar (only appearing in crop mode) on the right disappear with a value of FPS timer A 534 (FT+4)

a1ex

Quote from: vertigopix on April 28, 2015, 12:35:18 PM
FPS timer A : 520 (FT-12)
FPS timer B : 1970 (FT-81)

Those are safe values, or the values where artifacts start to appear?

Can you repeat the process for all resolution and FPS modes from Canon menu? Also include photo mode and 5x zoom mode (just once; zoom is the same in all video modes).

vertigopix

Safe values.

1920x1080p24 : A 520, B 1970
1280x720p50 : A 520, B 1970
640x480p25 : A 520, B 1970
Photo Mode : can't see, no image in background of the ML menu...
Zoom mode : can't see, no image in background of the ML menu... (but do you mean Crop Mode ? In that case A safe value is 534)

vertigopix

But just a question :

I have noticed that i can't go lower than 520 and 1970. The value doesn't change in the display. (But the FT value is still changing)
Is it an "hard limit" in the ML code ?

a1ex

FPS_TIMER_A_MIN and FPS_TIMER_B_MIN are the hard limits you are trying to find. Lower values are unsafe, but you need to find how low you can go, so first define it to something like 100. Even with those bogus values, if you start at default FPS, ML should pick default timer values, which are safe. From there, you try to push them until the image breaks.

With the bogus hard limits, there are modes that work just fine, and modes that do not work at all. The safest option would be to never allow overcranking, but then the exact FPS option may not be able to find an exact solution (since it usually overcranks one timer a bit, but "relaxes" the other). So, the best way is to allow a tiny bit of overcranking, but we need to find out how far we can go, and then go back on the safe side a bit.

Current values appear to be tweaked for one particular video mode only (probably 30fps). See https://docs.google.com/spreadsheet/ccc?key=0AgQ2MOkAZTFHdFFIcFp1d0R5TzVPTVJXOEVyUndteGc#gid=3 for default timer values.

Examples of why the current values are bogus:
- at 25/50 fps, default timer A is 640. Cranking it to 520 sounds a bit too much to me, unless you use NEW_FPS_METHOD.
- at 24fps, default timer B is 2527. Cranking it to 1970 also sounds a bit too much.
- EOS M applies some FPS settings only when you record H.264 (unlike all other cameras), and current hard limit definitions do not consider this.

To see behind ML menu, normally you need to press the LiveView button or the Zoom In button. Do you have any of those on M?

If not, tag the menu entries you want to edit with LiveView visible, with this:

                .edit_mode = EM_MANY_VALUES_LV,


Values at 50 fps can't be equal to those at 25. Those are probably in standby mode, where EOS M uses 30 fps, no matter what Canon settings you have.

There are also 30fps and 60fps modes.

Crop mode and 5x zoom are not the same thing. You posted some dumps a while ago, so you already know these modes.

vertigopix

Quote- EOS M applies some FPS settings only when you record H.264 (unlike all other cameras), and current hard limit definitions do not consider this.

Have tested while recording H.264

QuoteTo see behind ML menu, normally you need to press the LiveView button or the Zoom In button. Do you have any of those on M?

No LV (Mirrorless) and the Zoom In is on touch screen, if i activate it (5x) and press REC the LV get back to no zoom.

QuoteCrop mode and 5x zoom are not the same thing. You posted some dumps a while ago, so you already know these modes.

;)

From this evening to monday i go to Croatia.  8) So i will try when i return... If i return !
BUT... I want to film with my M in RAW... Is it risky ? (i just want to use FPS override to get 25)

DeafEyeJedi

@vertigopix:

Not really. Definitely give it a shot with the M. Try avoid using high ISO's (unless you don't mind dealing with pink dot removal in post) other than that it is a great toy for trips!  8)
5D3.113 | 5D3.123 | EOSM.203 | 7D.203 | 70D.112 | 100D.101 | EOSM2.* | 50D.109

nikfreak

Quote from: a1ex on April 28, 2015, 01:58:28 PM
FPS_TIMER_A_MIN and FPS_TIMER_B_MIN are the hard limits you are trying to find. Lower values are unsafe, but you need to find how low you can go, so first define it to something like 100. Even with those bogus values, if you start at default FPS, ML should pick default timer values, which are safe. From there, you try to push them until the image breaks.

setting timers like instructed and recompiling crashes 70D even though ML is picking default timer values with continuous crashlog writing to sdcard (crashxx.log). all crashlogs contain:
Quote
ASSERT: !IS_ERROR( TryPostEvent( this->hTaskClass, this, EV_RESET_PSAVE_INTERRUPT_EVF, NULL, 0 ) )
at ./Evf/EvfState.c:401, task ?
lv:1 mode:2


Magic Lantern version : Nightly.2015Apr28.70D111A
Mercurial changeset   : 1ace8a558a3a+ (70D-merge) tip
Built on 2015-04-28 19:34:03 UTC by ml@ml-pc.
Free Memory  : 231K + 1935K

I took a look at the state diagrams but looks like I could need some helping hands. How could fps-override crash the cam even if CONFIG_FPS_UPDATE_FROM_EVF_STATE is undefined:
http://a1ex.bitbucket.io/ML/states/70D-alt/sm17.htm
[size=8pt]70D.112 & 100D.101[/size]

Licaon_Kter

I get the same limits.
Do I need to lower them in code and recompile or what?

a1ex

Yes, you need to lower them in the code in order to perform the tests.

Licaon_Kter

Edited /src/fps-engio.c and lowerd A from 520 to 420 and B from 1970 to 1870
#elif defined(CONFIG_EOSM)
    #define TG_FREQ_BASE 32000000
    #define FPS_TIMER_A_MIN 420
    #undef FPS_TIMER_B_MIN
    #define FPS_TIMER_B_MIN MIN(fps_timer_b_orig, 1870)


Now this will get me to: https://imgur.com/a/HfZh0
Screenshot 1: lowest A I can go before visible artifacts is 512
Screenshot 2: For A under 520 the image gets shifted to the left ( about 11 pixels at 512 ), you can see the small black vertical band on the right side of the screen.
Screenshot 3: Going for A under 512 will yield corruption, trying different values for a while will make the display stay corrupted a bit even when backing up to 512.

Only playing with A yields corruption, fiddling with B will just shift the "Actual framerate" but I did not get corruption in my little time testing it, when the value is high ( say 5000 for 12fps out of 30 ) it gets boring to test it :P

The B timer has different values for different FPSs, how is this related to 1870/1970 set up in ML?

a1ex

OK, so for timer A, 520 appears to be a good choice for the video mode you tested.

For B, you'll get corruption only if you lower it (higher FPS), so there's little point in testing higher values.

After that, create a table with all video modes and write down the safe timer values for each one.

Licaon_Kter

I passed through all the modes in the previous test too, A as 520 still holds out ok.

Now, for B I can't really get my head around it: (base?) values jump around when changing desired FPS and if I lower B then the actual FPS is raised making the whole point of having an exact FPS useless, say I can get 1920x1080@25720@50, desired fps 12 (exact), put A on 520, lower B to 14xx hence actual fps yields 48 (!?).

Looking at the OP:

Quote-My exposure is good (f/11; 1/250 shutter; and ISO 160) and when when I enable FPS override feature the exposure change : It's completely overexposed, even if I change the shutter speed the exposure is the same and the histogram don't change.
Looks like it's working here, but maybe I did not understand the issue, I got a good exposure in photo mode ( f/11, 1/30, ISO400 ), switched to video, matched it, then set fps override to 12, went to shutter range there and pulled it to 1/12..1/30, when't back to shutter and set it up to 1/30... and it's ok. BUT I'm not sure you can even go as high as 1/250 though, you should be able?

Quote-The second problem is that when I chose optimizeed for exact fps I have a black bar on the right side of my video while that does not appear in the low light mode.
I don't see any bars. ( except lowering A that is )


/LE: was 720 not 1080 sorry

a1ex

You don't have to get an exact FPS when doing the test.

Also, remember that, on EOS M, FPS on standby (when not recording) is not affected by Canon FPS settings, so you also need to do the tests while recording H.264 (not just in standby).

Licaon_Kter


a1ex

That means, you were able to record 48fps H.264 without artifacts?!

Licaon_Kter

in 720@50 ( https://i.imgur.com/vGmbdGq.png ) in PAL, I guess that's not a feature, you though 1920@48? Nope.


Also a heads up, see the picture above, switching to 720@60 in NTSC yields 20 ( from 30FPS) in the ML menu, both in StandBy _and_ during recording, while in 720@50 mode it's 30 standby and 50 during recording, strange.

maxEmpty

so what is needed to fix fps override just some changed timer check frequency values, or is it way more complicated. i'm just trying to wrap my head around what needs to be done that's all.
if at first you cant get L glass... Sell everything you own and get L glass.