Jump to content
  • Advertisement
Sign in to follow this  
bujcat

FPS question

This topic is 4870 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

I have a game which have some simple animation(movement). Is a ping pong 3D game. The FPS is about at 77. I have only simple objects (10 rectangle, one sphere, one circle). I have created the objects using vertex buffers. Isn't the FPS to low? Complicated games(sophisticated graphics) which I have seen go at maximum 230FPS.

Share this post


Link to post
Share on other sites
Advertisement
Well, you cannot say so. It depends on a computer you're using and how you write your code.
My computer shows fullscreen graphics maximum on 60 fps (I think that's because of the screen), while windowed mode works ok.

Share this post


Link to post
Share on other sites
I'm sure there are many reasons for your low FPS. But try first
to turn off vsync when creating the DirectX device. Like this:

D3DPRESENT_PARAMETERS params;
:

// vsync is off
params.PresentationInterval = D3DPRESENT_INTERVAL_IMMEDIATE;
:

The "params" goes into the "CreateDevice" call:
CreateDevice(D3DADAPTER_DEFAULT, D3DDEVTYPE_HAL, ....);

Share this post


Link to post
Share on other sites
Yes, it could cause "slicing" artifacts to appear. This is when your display is half way through refreshing and the picture changes, leaving a your screen with half of one frame and half of another. Don't worry about it though, it's barely noticeable because it's only there for a few milliseconds.

Share this post


Link to post
Share on other sites
Quote:
Original post by bujcat
Do you know and some others solutions for improving the FPS?


You have to realize the difference between improving the FPS, and improving the time actually spent to render frames... having Vertical-Sync means you will at best have a static FPS locked to the refreshrate of the monitor... HOWEVER, it doesn't mean your application is running slow as you could actually without Vertical-Sync be running at 450 FPS.

And no, there is no other way, either you let the FPS fly on and don't use vertical-sync, or you use vertical-sync and let it be limited to the refreshrate... ideally, there is nothing bad to say about vertical-sync... you spend only the time you need rendering, no tearing... HOWEVER, vertical-sync can in certain scenarios cap your FPS to half if unlucky, or make the game feel less responsive.

And for a pong game, one should perhaps use vertical-sync as it could otherwise really hurt your eyes watching that little ball go flipper.

Share this post


Link to post
Share on other sites
I have saw a benchmark application wich have runned an demo at about 230 FPS on my computer but without flickering. I understand that they are using specially methods for this.

Thanks for your help.

Share this post


Link to post
Share on other sites
Quote:
Original post by bujcat
I have a game which have some simple animation(movement). Is a ping pong 3D game. The FPS is about at 77. I have only simple objects (10 rectangle, one sphere, one circle). I have created the objects using vertex buffers.
Isn't the FPS to low?


The only reasons I can think of for such low framerates with those requirements (other than using the REF device) is either a very slow graphics card or you have the DirectX debug runtimes enabled.

Go to the control panel and select the DirectX icon. In the dialog that opens, select the "Direct3D" tab. In the section "Debug\Retail D3D Runtime" see if the "Use Debug Version of Direct3D" is selected. if it is then select "Use Retail version of Direct3D" and see if your frame rates improve.

Even when developing a DirectX apps, I usually have the retail runtimes enabled unless I need to track down a bug, and in that case I enable the debug runtimes.

HTH,
Cambo_frog


Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!