Old 14th May 2003, 11:09   #1
Magic.X
Major Dude
 
Magic.X's Avatar
 
Join Date: Feb 2002
Location: Leipzig / Germany
Posts: 859
Question Framerate Limiter - Request to UnConeD

I know the Framerate Limiter idea is nothing new,but as i read that UnConeD has already written a FPS Detector ape, i thought that this could easily be transformed into an Framerate Limiter by inserting some delay code.

This would be kinda great as i have a lot of best at xx.x fps presets!


-=[The Ultimate VJ-Tool for AVS]=-

Hotlist 2.3 developement thread (old)
Magic.X is offline   Reply With Quote
Old 14th May 2003, 20:25   #2
mikm
Major Dude
 
mikm's Avatar
 
Join Date: May 2001
Location: somewhere else
Posts: 1,286
and what if the framerate is below xx.x? what then?

I think the biggest problem with this is that it might cause the framerate to be 'blocky'.

powered by C₈H₁₀N₄O₂
mikm is offline   Reply With Quote
Old 15th May 2003, 11:09   #3
Magic.X
Major Dude
 
Magic.X's Avatar
 
Join Date: Feb 2002
Location: Leipzig / Germany
Posts: 859
BLOCKY???

Don't know what you mean by this.

It could be done like this:

Check fps

If fps>xx.x increase %loop%
If fps<xx.x decrease %loop%
If fps=xx.x do nothing

do some hungry processes for %loop% times (could be a double inversion of the frame for example)

See if your pc is not able to even achieve xx.x fps the loop will be always 0.

Otherways the ape will always adjust it to the desired fps.

Quite simple, i'snt it? I'd do it myself, only prob is that i'm too busy with coding hotlist and my c++ knowledge is not the best.


-=[The Ultimate VJ-Tool for AVS]=-

Hotlist 2.3 developement thread (old)
Magic.X is offline   Reply With Quote
Old 15th May 2003, 13:29   #4
sidd
Major Dude
 
sidd's Avatar
 
Join Date: May 2003
Location: Australia
Posts: 1,353
obviously if the fps is already less than desired, you cant do much abuot it. but thats not the point. i think its a damn nice idea magicX
sidd is offline   Reply With Quote
Old 15th May 2003, 20:27   #5
mikm
Major Dude
 
mikm's Avatar
 
Join Date: May 2001
Location: somewhere else
Posts: 1,286
what I'm saying is that if you have a FPS slowing APE at the end, it would stop the processing for one frame. Thus, there would be 'delays' in the updates. (At least I think...not positive).

powered by C₈H₁₀N₄O₂
mikm is offline   Reply With Quote
Old 16th May 2003, 10:57   #6
Magic.X
Major Dude
 
Magic.X's Avatar
 
Join Date: Feb 2002
Location: Leipzig / Germany
Posts: 859
I cant imageine that it would cause delays ina an other way than desired. But that would have to be tested.


-=[The Ultimate VJ-Tool for AVS]=-

Hotlist 2.3 developement thread (old)
Magic.X is offline   Reply With Quote
Old 17th May 2003, 06:06   #7
sidd
Major Dude
 
sidd's Avatar
 
Join Date: May 2003
Location: Australia
Posts: 1,353
hang on, are you saying it will physically limit the fps, or just run code loops so that the preset is running slower.

the second one should have no problems at all, because it is just like puting in heaps of pointless effects to slow it down.
sidd is offline   Reply With Quote
Old 18th May 2003, 08:30   #8
shreyas_potnis
Major Dude
 
shreyas_potnis's Avatar
 
Join Date: Jan 2003
Location: Mumbai, India
Posts: 787
hang on...this one is quite an easy one, i can do it.
so, should i?

http://home.iitb.ac*****~shreyaspotnis
shreyas_potnis is offline   Reply With Quote
Old 18th May 2003, 11:26   #9
UnConeD
Whacked Moderator
 
UnConeD's Avatar
 
Join Date: Jun 2001
Posts: 2,104
code:

struct apeconfig {
int mFrameLimit;
};

class C_THISCLASS {
...
private:
int mLastTicks;
apeconfig config;
...
}

C_THISCLASS::C_THISCLASS {
mLastTicks = GetLastTicks();
}

C_THISCLASS::render(...) {
int vTicks = GetLastTicks();
int vDelay = 1000/config.mFrameLimit;
int vRenderTime = vTicks - mLastTicks;
if (vRenderTime < vDelay) {
Sleep(vDelay - vRenderTime);
}
mLastTicks = GetLastTicks();
}



That should do the trick, it measures the rendering time of everything except the APE itself and adjusts framerate accordingly. I don't feel like whipping up an APE project for it.

UnConeD is offline   Reply With Quote
Old 18th May 2003, 13:55   #10
shreyas_potnis
Major Dude
 
shreyas_potnis's Avatar
 
Join Date: Jan 2003
Location: Mumbai, India
Posts: 787
great, but should i make an ape for it?

http://home.iitb.ac*****~shreyaspotnis
shreyas_potnis is offline   Reply With Quote
Old 19th May 2003, 01:31   #11
UnConeD
Whacked Moderator
 
UnConeD's Avatar
 
Join Date: Jun 2001
Posts: 2,104
Dunno, I still don't see the use of this. If a preset goes too fast, increase the AVS size and be amazed at the miracles of 400x300 or 512x384...

UnConeD is offline   Reply With Quote
Old 19th May 2003, 02:18   #12
Raz
Forum King
 
Raz's Avatar
 
Join Date: Dec 2002
Location: Manchester
Posts: 6,470
Or 1024 x 768, i love teh new processor

Raz is offline   Reply With Quote
Old 19th May 2003, 02:29   #13
anubis2003
Forum King
 
anubis2003's Avatar
 
Join Date: Dec 2002
Location: middle of somewhere
Posts: 5,564
Send a message via AIM to anubis2003
Speaking of new processor, I may be getting a dual Intel Xeon 3.06Ghz computer with 4GB(max of 12) PC-2100 RAM this summer. I'll also have at least 500GB of harddrive space as well. It's going to be sweet.
anubis2003 is offline   Reply With Quote
Old 19th May 2003, 03:47   #14
uNDefineD
Senior Member
 
uNDefineD's Avatar
 
Join Date: Jan 2002
Location: Melbourne, Australia
Posts: 297
Send a message via ICQ to uNDefineD Send a message via AIM to uNDefineD
Quote:
Originally posted by anubis2003
Speaking of new processor, I may be getting a dual Intel Xeon 3.06Ghz computer with 4GB(max of 12) PC-2100 RAM this summer. I'll also have at least 500GB of harddrive space as well. It's going to be sweet.
Fuck me.

Seen the latest PowerMac yet? Dual 1.42GHz G4's with 2MB cache. *drool* (Not that I'm a Mac user or anything...)
uNDefineD is offline   Reply With Quote
Old 19th May 2003, 10:55   #15
Magic.X
Major Dude
 
Magic.X's Avatar
 
Join Date: Feb 2002
Location: Leipzig / Germany
Posts: 859
Ahem, back to the Topic.

Shreyas, go for it, will be great.

And UnConed, you can go to higher res of course as the ape should always keep the fps if possible, so it won't limit the resolution you can do with it.

But i recently watched old Presets i did on My Celeron 400 and now they ran on 63 fps and looked all messy unless i reduced the framerate to 20 again.

That should be the purpose of this APE, getting the same effect on each machine no matter which hardware is used.


-=[The Ultimate VJ-Tool for AVS]=-

Hotlist 2.3 developement thread (old)
Magic.X is offline   Reply With Quote
Old 20th May 2003, 15:17   #16
shreyas_potnis
Major Dude
 
shreyas_potnis's Avatar
 
Join Date: Jan 2003
Location: Mumbai, India
Posts: 787
ok, gimme some time because i am not that free these days

http://home.iitb.ac*****~shreyaspotnis
shreyas_potnis is offline   Reply With Quote
Old 22nd May 2003, 10:56   #17
Magic.X
Major Dude
 
Magic.X's Avatar
 
Join Date: Feb 2002
Location: Leipzig / Germany
Posts: 859
I know what you mean, i'm messing with nsis2 for hotlist2.2 since 4 days because i never have more than 1 houre per day for this stuff

Take your time, but get it done


-=[The Ultimate VJ-Tool for AVS]=-

Hotlist 2.3 developement thread (old)
Magic.X is offline   Reply With Quote
Old 23rd June 2003, 15:05   #18
Magic.X
Major Dude
 
Magic.X's Avatar
 
Join Date: Feb 2002
Location: Leipzig / Germany
Posts: 859
Erm Shreyas, any progress made?


-=[The Ultimate VJ-Tool for AVS]=-

Hotlist 2.3 developement thread (old)
Magic.X is offline   Reply With Quote
Old 23rd June 2003, 16:05   #19
[Ishan]
Major Dude
 
[Ishan]'s Avatar
 
Join Date: Mar 2003
Location: India
Posts: 1,156
Send a message via Yahoo to [Ishan]
Yes i'm waiting for it too


Amateur AVS'er. All over again.

Last AVS Pack :
Resurgence

[Ishan] is offline   Reply With Quote
Old 23rd June 2003, 17:55   #20
mikm
Major Dude
 
mikm's Avatar
 
Join Date: May 2001
Location: somewhere else
Posts: 1,286
/sigh. he will post it when it is ready. there is no need to revive dead posts

powered by C₈H₁₀N₄O₂
mikm is offline   Reply With Quote
Old 24th June 2003, 15:35   #21
shreyas_potnis
Major Dude
 
shreyas_potnis's Avatar
 
Join Date: Jan 2003
Location: Mumbai, India
Posts: 787
ehh, so wait a bit, lemme submit my pack. what is over is : couple of well, something is over. sort of buggy though. crashes winamp for no reason at all, will figure out soon

http://home.iitb.ac*****~shreyaspotnis
shreyas_potnis is offline   Reply With Quote
Old 25th June 2003, 09:12   #22
blazer1504
Senior Member
 
blazer1504's Avatar
 
Join Date: Dec 2001
Location: .fi
Posts: 155
naah naah

ooOOh, but I already have a fps limiter.. yup yup, it never gets over 64 fps with this :P You must be jealous as hell
blazer1504 is offline   Reply With Quote
Old 28th June 2003, 06:02   #23
Shock Value
Senior Member
 
Shock Value's Avatar
 
Join Date: Aug 2002
Location: USA
Posts: 158
Heh Blazer same with me. But try opening up Kazaa and clicking the theater tab. This causes the frame rate to be normal on my machine until I close Kazaa for some reason. Some other programs will do this as well, usually ones that have to do with multimedia type stuff. I don't know why this happens, though, or why the frame rate was stuck in the first place.
Shock Value is offline   Reply With Quote
Reply
Go Back   Winamp & Shoutcast Forums > Visualizations > AVS > AVS Wishlist

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Forum Jump