Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

Dark GDK / 64 FPS even with dbSyncOff

Author
Message
Modis
18
Years of Service
User Offline
Joined: 17th Apr 2006
Location:
Posted: 25th Apr 2006 01:11
I'm working on a 3d tile based game, the maps are random so there is no BSP or single mesh load. I load 8 objects, hide them and instance from them to create a random 25x25 grid room. At most when it is all over there is 500 objects in memory.

When the map displays only a 12x12 grid is drawn around the players position. All other objects are hidden. The camera is set to a 45deg FOV and 1/300 distance.

When I run the game with a moving player and a camera in chase mode I get 64 frames a sec with sync on. If I turn sync off I still get 64 frames a sec. If I turn on shadows the frame rate drops almost 50%. If I use db intersect(objid,x,y,z,x,y,z) I can lose another half my frame rate, taking it down to 16 fps at times.

This is all on a AMD +3800 x2 with 3 gigs ram and a 7800oc card running on xp64.

Anotehr odd thing, with sync on my cps runs at 52 to 55% while holding the FPS rate as discribed above. If sync is off the cpu is down to 2 to 5% usage and the frame rate hold to the same.

I can't realy account for this behavior.

I use plygon intersect detection, but at most the tiles have 20 ploys a peace, they are very basic walls/corners etc. An I am simply doing LOS type checking, not collision testing.

Does intersect testing not ignore hidden items?

Other notes, the shadows look terrible and also display on the back side of walls and stretch arcoss the full view distance. There seems to be a scaling issue with the shadows also. I down size my player by 80% to scale him to the world objects but when I put the player at 0,0,0 there is a giant shadow standing there and distorting the full screen view.

I'm still trying to work through it but with no real manual as to how the functions in the sdk work it has become more a chore then a pleasure to work with.

Is there anymore docs to be had them the help file which has basic 1 to 2 liners in it to discribe the function usage?

Modis
Zeal
22
Years of Service
User Offline
Joined: 10th Oct 2002
Location: Colorado Springs, CO
Posted: 25th Apr 2006 21:23
Im not sure if this is the same issue, but I have had trouble (in pro and sdk) where my fps get 'capped' at 60ish. Maybe its on my end, drivers or whatnot, but its COMPLETELY random. Sometimes its capped, then ill compile again, and my fps shoot to 300+ (sometimes a reboot or mucking with media player helps).

Perhaps this is whats happening to you?

(cant answer your other questions, never used interesect object)

All you need is zeal
RUCCUS
19
Years of Service
User Offline
Joined: 11th Dec 2004
Location: Canada
Posted: 25th Apr 2006 22:37
I cant solve your lag issues but to clear something up, intersect object checks for intersection with all objects, hidden or not. You're best bet on cancelling the objects out is to use an array with all of the objects to be checked. Then using the on screen commands to check if the objects are in view, if so add them to the array, if not remove them.

@Zeal: The "capping" problem is most likely due to one of your other applications being run (WMP might do it) thats stting the framerate to 60. Some apps only set the framerate to 60 for their program, but others dont, so one of your other programs thats running might be the culprate.

- RUC'

re faze
20
Years of Service
User Offline
Joined: 24th Sep 2004
Location: The shores of hell.
Posted: 26th Apr 2006 02:01
also , make sure that all instances of the program have exited.

Modis
18
Years of Service
User Offline
Joined: 17th Apr 2006
Location:
Posted: 26th Apr 2006 05:23
RUCCUS

When you use float dbIntersectObject ( int iObject, float fX, float fY, float fZ, float fToX, float fToY, float fToZ ) does it pass through all the loaded object and test each one for an intersection?

If it does that and I am using it in a for loop already of the surrounding 6x6 square then each pass casues it to loop through all objects each time.

The following function is what I was using to test intersection for a LOS culling system. Please take a look and make any suggestions or point out flaws you see.



I would realy like to understand why it would check hidden object also, and if that is the case a nice bool switch to ignore hidden in test would realy be nice.

Also thanks all for you input, looking into any other aps regulating FPS

Modis
Modis
18
Years of Service
User Offline
Joined: 17th Apr 2006
Location:
Posted: 26th Apr 2006 05:27
Oh! One other question, how fast is dbInstanceObject, can I instance objects fast enough that I only need the 6x6 grid around my playing in memory each time he moves past into a new tile?

I think I'll check into these tonight and see how it acts.

Modis
Sephnroth
22
Years of Service
User Offline
Joined: 10th Oct 2002
Location: United Kingdom
Posted: 29th Apr 2006 03:43
instance is pretty fast, I use it in my rpg engine shisaku (which I havnt touched in too long! having too much fun deving for the gp2x X_X) and i get around 60fps - the engine does ALOT though. hundreads of objects, visibility checking, lots of polys, monsters, lots going on.

If you always get around 60 fps no matter what is going on I must ask the question - are you running full screen? Its not other applications that cap your frame rate - when you are full screen (dbp's "exclusive" mode iirc) you are capped to the vsync rate. this is generally around 60fps but I confess in my currently less than able state (just got back from party..) I cant remember what effects that (I guess refresh rate in hz? x_X) but its not effecting your games performance. Throw it into a window and you'll get an uncapped frame rate. Is this the issue?

OSX Using Happy Dude
21
Years of Service
User Offline
Joined: 21st Aug 2003
Location: At home
Posted: 29th Apr 2006 14:02
Its possible the refresh rate is capped in your graphics driver options.

Modis
18
Years of Service
User Offline
Joined: 17th Apr 2006
Location:
Posted: 1st May 2006 04:19
Sephnroth,

Nope that 60 fps is in a 400x400 window, What is the oddest is when I turn syncoff and the cpu usage goes down to 2% but the fps remains the same.

Can you share with me your version of LOS testing? Would be interesting to compare it to mine and see what if defferent.

Modis

Login to post a reply

Server time is: 2024-11-19 06:28:23
Your offset time is: 2024-11-19 06:28:23