This is the patch I am using in both Magic and Tragic module, nothing has changed since the first time we found out about the mem fix.
/* try to recycle the waste */
- if (waste >= 16*1024*1024 + 8192)
+ 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;
@@ -625,6 +625,17 @@
buffer_count++;
total += waste;
}
+
+/* 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) // > kisbuffer elöl
+ {
+ temp[j] = buffers[j];
+ buffers[j] = buffers[j + 1];
+ buffers[j + 1] = temp[j];
+ }
Tragic version is not from the main repo, that is from his own repo. So maybe something differ in the code that makes it work differ. Not sure.
I just use Magic version and it has not let me down yet, very happy with how it works considering our controller limitation, sometimes I get good frames, sometimes bad, I think it depends on the card condition at the time, seems to random to say it is in the code that causes it.
Maybe if you try without loading other modules to see if that makes a differ in performance, in this version I added the picview module too.
Go to the module menu and go to each module except Raw_Rec and press set on each and choose not to autoload them, then set the main autoload to on and restart camera so it only loads raw_rec.