View Full Version : 3.0 news
Bidoche
20th June 2003, 21:19
- Got some work done on the Clip class hierarchy for easier subclassing
- Wrote a Cache class for 3.0 (not a filter but a member to use to implement caches), it uses a reversed cache hints approach : it asks back its clients for the cache method they want.
- Started rewriting the basic edit filters (Trim... )
bilu
21st June 2003, 01:31
Originally posted by sh0dan
startcmd="Call("+chr(34)+"cmd"+chr(34)+", "+chr(34)
endcmd=chr(34)+")"
FrameEvaluate("eval(startcmd+string(current_frame)+endcmd)")
#scriptclip("subtitle(startcmd+string(current_frame)+endcmd)")
The scriptclip is purely for illustration.
Sorry for not replying earlier, I only tested it now.
Both CALL and Import() work very well this way.
Thanks a lot ;) Let's see now how this can be useful.
Bilu
Bidoche
7th July 2003, 18:47
Again committed my last code, this time everything (not the old 2.5 source files) should compile ok, provided you have both stlport and boost installed.
The central classes (VideoFrame, VideoInfo, BufferWindow, VideoFrameBuffer) should now have reached a relatively stable state.
So people interested may look into it without fearing my wrecking havoc into them again :p
It is now possible (or almost possible) to convert filters code for 3.0
@sh0dan : I will need you to fill some code (like the BufferWindow::Blend we talked long time ago)
I have started too to make some parser related classes, like VarTable Statement, Expression and derived.
Bidoche
30th July 2003, 18:35
I was working on memory management recently and in order to increase the env MemoryMax accuracy I introduced the following methods :
//in ScriptEnvironment
void FireMemoryUsedOverMax(); //takes appropriate mesures to reduce memory usage (essentially ask cache to drop cached frames)
void SetMemoryMax(size_type _max); //set memory max, can trigger FireMemoryUsedOverMax
void MemoryUsedIncreased(size_type size); //increase memoryUsed and FireMemoryUsedOverMax if over max
void MemoryUsedReleased(size_type size); //decrease memoryUsed
//memory allocation/deallocation methods
//correctly update memory usage by the env
//usage is expected for frames like size, (relatively) small size can skip it
void * malloc(size_type size);
void free(void * ptr);
static void FireNotEnoughMemory(); //try to recover some memory
I'd like some input on how the two fire methods should affect the memory maxs. If they don't, in some case the events could be fired consistently without never improving the situation.
Example: a filter allocates 15M for himself when Max at 10.
Then each frame creation will fire MemoryOverMax which will make the env flush the caches. Utterly stupid if there is mem available.
Bidoche
1st August 2003, 13:08
From memory management I went to cache issues.
I finally completed a Cache helper class to use by clips to implement caches.
It uses a reverse cache hints mechanism, asking back clients for cache hints. This way enforces that hints are always supplied.
@sh0dan
I'd like you to tell me if the hints behavior is the one you expected.
The code is massively commented so it should be understandable.
vBulletin® v3.8.11, Copyright ©2000-2026, vBulletin Solutions Inc.