550D/T2i raw video recording port official thread

Started by dlrpgmsvc, May 22, 2013, 12:11:45 PM

Previous topic - Next topic

0 Members and 3 Guests are viewing this topic.

mk11174

Quote from: JoshuOne on June 05, 2013, 10:48:39 AM
Greetings
Mk111174, you stated yesterday that the 500d is getting 1280x400+ at 24fps, is this in raw?  How?  I have been trying to find a thread on the 500d raw and have been unsuccessful, please turn me in right direction.  Thanks and please don't be angry if there was somewhere else to post this.  Thank you.
Are you saying you need a bin for your 500D? I would be glad to share.
500D/T1i  550D/T2i  600D/T3i  700D/T5i

CharlieA56

Canon 6D, Canon 60D, Canon T2i & Canon T1i

dlrpgmsvc

exmem.c - line around 147 -
hsuite = shoot_malloc_suite (max_size + backup_size - 8 * 1024 * 1024)
in this manner, the old version, we obtain 68Mb of shoot memory, good to serve as buffer for raw video (more memory, more resolution)
-----------------------------------------------------------------------------------------
hsuite = shoot_malloc_suite (max_size + backup_size - 1024 * 1024)
in this manner, the new and current version, we obtain 75Mb of shoot memory
-----------------------------------------------------------------------------------------
Our goal is to raise this shoot memory as high as possible, but the maximum I managed to obtain is :
hsuite = shoot_malloc_suite (max_size + backup_size)
in this manner, we can have 76Mb of shoot memory
Then, following this way... if you try  even a :
hsuite = shoot_malloc_suite (max_size + backup_size + 1024 * 1024)
the result is 0 of shoot memory !
-----------------------------------------------------------------------------------------

I have hitted a wall here...  :'(

From a technical point of view, this thread is quite dead ! C'mon guys ! If you are trying something, no matter what are the results, share them with me so we can publish the efforts of all in order to progress !  ;)
If you think it's impossible, you have lost beforehand

1%

What is the error 70 you got.. you can patch it at boot time with a cache hack (maybe after too if you're lucky).

You can also try to boot with asserts disabled for the time being and see if it works.

a1ex

Before patching errors, make sure you fully understand what you are doing. If you brick the camera, you get to keep both pieces. If you brick other user's cameras, they will blame ML.

Quotepatching asserts is like putting a tube on your open wound so you don't see yourself bleeding to death anymore
(but you're still bleeding to death)

1%

Yep... even with no assert might boot to black LV. Sraw may not work here... or may not free any memory.

We need to understand SRM_ChangeMemoryManagementforXXX and figure out how to free memory afterwards.


dlrpgmsvc

- Modifying the "backup_size" (by upsizing or downsizing it), doesn't sort any effect at all.
- Changing the probe size from 4 to 2 and then to 1 (just to dig out more memory chunks), doesn't sort any effect at all.
- Forcing "size" to zero into the shoot_malloc allocation function, just to force it to allocate the maximum size, takes the camera to stack overflows and freezes that need to pull out the battery: no luck...
If you think it's impossible, you have lost beforehand

JoshuOne

Greetings, I would be very grateful for  a bin that allows raw video on my 500d. Thanks so much for the offer.

mk11174

500D/T1i  550D/T2i  600D/T3i  700D/T5i

xaint

Quote from: dlrpgmsvc on June 06, 2013, 12:59:11 AM
- Modifying the "backup_size" (by upsizing or downsizing it), doesn't sort any effect at all.
- Changing the probe size from 4 to 2 and then to 1 (just to dig out more memory chunks), doesn't sort any effect at all.
- Forcing "size" to zero into the shoot_malloc allocation function, just to force it to allocate the maximum size, takes the camera to stack overflows and freezes that need to pull out the battery: no luck...


I think we can gain a few more extra frames (on 550D at least), if we are a little bit more permissive with the current waste recycling mechanism:

/* try to recycle the waste */
    if (waste >= 8*1024*1024 + 8192)
    {
        buffers[buffer_count].ptr = (void*)(((intptr_t)(fullsize_buffers[0] + buf_size) + 4095) & ~4095);
        buffers[buffer_count].size = waste - 8192;
        buffers[buffer_count].used = 0;
        buffer_count++;
        total += waste;
    }


Let's say we can use those chunks from the remaining, which are larger than 8Mb. Because on the 550D we have ~75Mb shoot_malloc, and with the two ~31Mb contiguous buffers only,we left unused around 10Mb.

And I think it's better if the buffers are in ascending order (start writing ASAP):
/* Sort Buffers */
    static struct buff temp[10];
    for (int i = 0; i < buffer_count; i++)
        for(int j = 0; j < buffer_count- i - 1; j++)
           if(buffers[j].size > buffers[j + 1].size)
           {
                temp[j] = buffers[j];
                buffers[j] = buffers[j + 1];
                buffers[j + 1] = temp[j];
           }


(It seems it's no longer in the unified?)


Some test results here, on 550D with SanDisk ExtremePro 16GB, at 1280x426 @ 24fps without HaCKeD mode:






Buffers                 FramesSeconds
2x31Mb68<3
2x31Mb + 9Mb26511
9Mb + 2x31Mb27411.4

My version is probably not up to date, so take this into account!
And I don't know how it may affect the other models btw, need reviews...

dlrpgmsvc: Just to make you happy  :D ;D

a1ex please confirm these!

Forgive me if I wrote stupid things :D and apologize for my english :D

a1ex

Possible. 8MB buffers are slowing down stuff on high-end cameras though.

Did you try this tool? https://bitbucket.org/hudson/magic-lantern/src/tip/modules/raw_rec/speedsim.py

JoshuOne

Thanks so much, mk111174. When I go to load the modules I get an error:
tcc: error: undefined symbol 'FIO_SeekFile"
[E] failed to link modules

This is as close as I have come to being able to use the RAW Video, so I am very grateful and excited, if someone could help me get past this error, I would really appreciate it. Thanks again, mk11174!

1%

Yea, might be opposite on 550D, sort how you need to. Mainly its for 32m buffers vs like 29m.. not 9m. I tried sorting both ways too.

mk11174

Quote from: JoshuOne on June 06, 2013, 05:58:28 AM
Thanks so much, mk111174. When I go to load the modules I get an error:
tcc: error: undefined symbol 'FIO_SeekFile"
[E] failed to link modules

This is as close as I have come to being able to use the RAW Video, so I am very grateful and excited, if someone could help me get past this error, I would really appreciate it. Thanks again, mk11174!
OOh sorry, need to add the seek file address I forgot it was not added to unified yet. I will rebuild for you.

http://www.mediafire.com/download/sdjy758pczkp62c/500D_Raw_ML_FIX.zip
500D/T1i  550D/T2i  600D/T3i  700D/T5i

dlrpgmsvc

@xaint: Many thanks! What is the source file dealing with waste mechanism ? And the one dealing with buffers sorting? At what line number is to insert the sorting code, now not present in the unified? I think we can add a #ifdef 550d for all this things and for my 1mb squeezing in exmem.c , what do you think?
If you think it's impossible, you have lost beforehand

a1ex

Sorting might help with very small buffers when you have to write 100-200 frames or so (e.g. a particular write speed may work better with a particular buffer order), but will not help at all for continuous recording. Use my python script and run some simulations.

You can't ifdef in raw_rec, and 1MB squeeze at the cost of maybe not working at all... I wouldn't recommend.

JoshuOne

Thanks so much, mk11174. I will let you all know how it goes on the old 500d!!!

xaint

Quote from: a1ex on June 06, 2013, 08:39:29 AM
Sorting might help with very small buffers when you have to write 100-200 frames or so (e.g. a particular write speed may work better with a particular buffer order), but will not help at all for continuous recording. Use my python script and run some simulations.

You can't ifdef in raw_rec, and 1MB squeeze at the cost of maybe not working at all... I wouldn't recommend.

Yeah I know this isn't ,,The Solution" for continuous recording, it only delays the ,,buffer overflow", but it is at least a few seconds plus recording time.

Until we figure out how to get more memory (if it is possible at all on 550D), this is something at least. :)

I didn't try that speedsym script, but I will!

dlrpgmsvc: about 1mb squeezing in exmem.c: I agree with a1ex: 1MB squeeze at the cost of maybe not working at all... I wouldn't recommend.

Chagalj

Guys, is there any location where all the builds for 550d are located? Ive searched around for it but it seems that it isnt located anywhere on separate topic. Is it possible to update the first post in this thread with latest builds?

dlrpgmsvc

Quote from: Chagalj on June 06, 2013, 04:05:07 PM
Guys, is there any location where all the builds for 550d are located? Ive searched around for it but it seems that it isnt located anywhere on separate topic. Is it possible to update the first post in this thread with latest builds?

Sure ! If mk11174 give me his permission, I will publish the links to his builds about 550D on the first post ! Good idea ! Thanks !
If you think it's impossible, you have lost beforehand

mk11174

Quote from: dlrpgmsvc on June 06, 2013, 07:32:57 PM
Sure ! If mk11174 give me his permission, I will publish the links to his builds about 550D on the first post ! Good idea ! Thanks !
Do It! LOL  ;)
500D/T1i  550D/T2i  600D/T3i  700D/T5i

dlrpgmsvc

If you think it's impossible, you have lost beforehand

MaKsOZ


dlrpgmsvc

Am I the only fool here that discovered HDR RAW VIDEO is already enabled and operative, and it also works on 550D ?  8)
If you think it's impossible, you have lost beforehand

mk11174

Another build with the help of Xaint getting us a bit more memory for recording, I am getting much more frames before skipping now with 1280x432x24p 193 frames to be exact, was only getting 86 before his hack.

This also includes Alex's latest bitbuckit update, gives us more resolution choices looks like and a mem hack but doesnt seem to help our cam at all.

http://www.mediafire.com/download/09bl5v3ovzca5c7/ML_Raw_MemFix.zip

This includes Filemanager as will, you can find in the Debug menu.
500D/T1i  550D/T2i  600D/T3i  700D/T5i