static void Main()
{
using(Form1 frm = new Form1())
{
frm.Show();
frm.InitGraphics();
while(frm._running)
{
frm.Render();
Application.DoEvents();
}
}
}
[SOLVED] soo sloow
Is there a way to sort of tell windows that my DX app will have a higher priority than other apps? I'm experiencing framerates of 40 fps when doing nothing else than clearing the device!!! And the framerate also depends a lot on other programs running in the background. Is this normal?
I'm using this main in managed directx:
Is there a better way to do it?
Thanks in advance
[Edited by - thehan on August 5, 2005 1:45:45 AM]
That's the same for me. Well, there's nothing to do but to use
d3dpp.PresentationInterval = D3DPRESENT_INTERVAL_ONE;
It's set to D3DPRESENT_INTERVAL_DEFAULT by default in DirectX 9 SDK.
d3dpp.PresentationInterval = D3DPRESENT_INTERVAL_ONE;
It's set to D3DPRESENT_INTERVAL_DEFAULT by default in DirectX 9 SDK.
Quote:Original post by Zack08
That's the same for me. Well, there's nothing to do but to use
d3dpp.PresentationInterval = D3DPRESENT_INTERVAL_ONE;
It's set to D3DPRESENT_INTERVAL_DEFAULT by default in DirectX 9 SDK.
Wait, isn't immediate faster?
Quote:
Wait, isn't immediate faster?
Yes use:
d3dpp.PresentationInterval = D3DPRESENT_INTERVAL_IMMEDIATE
if you want full framerate and not locked to vsync.
Yeah, sorry. For my part I just need it to be locked to vsync, since I'm locking the framerate :\
What kind of hardware are you running? If the FPS is varying with your background task usage, you probably have a slower CPU or not enough RAM. Can you also show us the code you use to initialise the device and render? I am assuing this is a windowed app? Have you tried going full screen?
Thanks for your replies.
Sr_Guapo:
I'm running a P4 2,8GHz CPU and a GeforceFX card. It shouldn't be any problems. Currently I'm running windowed mode, is that slower? I will try to use fullscreen... well it does make a difference in the meaning it doesn't vary in speed.
Well I tried to set immediate, and wow!!!, my program runs about 10000 times faster now! Thanks!!!
Sr_Guapo:
I'm running a P4 2,8GHz CPU and a GeforceFX card. It shouldn't be any problems. Currently I'm running windowed mode, is that slower? I will try to use fullscreen... well it does make a difference in the meaning it doesn't vary in speed.
Well I tried to set immediate, and wow!!!, my program runs about 10000 times faster now! Thanks!!!
This topic is closed to new replies.
Advertisement
Popular Topics
Advertisement