massive slowdown - help!
Blitz3D Forums/Blitz3D Programming/massive slowdown - help!
| ||
I've just started working on something new and I've run into a problem. Download this to see: www.3darteest.com/test.zip Use WASDRF to control the camera. What's happening is that as you rotate the camera and zoom in/out the demo experiences massive slowdowns after a little bit. For me it only takes a couple seconds but I have a relatively old computer so on newer systems it may take longer. Given the nature of the problem I at first assumed I am accidentally creating instances of something every frame but I combed through the code (and there isn't much; like I said, I just started working on this) and couldn't find anything like that. Do other people experience slowdown when running the demo I posted? If so, any ideas what the problem is? |
| ||
Just ran it, no slowdown here specs: AMD XP2600, 1 Gig Ram, Geforce4 Ti4200, Windows XP [EDIT] when i turn on waitforvertblank i get slowdown, id do it like this: ;main game loop While Not KeyHit(1) ;counter for time between frames currentframetime=MilliSecs() frametime=currentframetime-lastframetime avgframetime=(avgframetime*4.0 + Float(frametime))/5.0 frametime=avgframetime lastframetime=currentframetime ;update the game and draw the next frame UpdateGame() ; If waitForVerticalBlank=1 VWait <-- take this line out Flip(waitForVerticalBlank) Wend |
| ||
Among the possibilities I am considering is that the slowdown is simply my hardware. I'm going to restart my computer and test the demo. In the meantime though I want to make sure there is nothing wrong with my code; experience tells me that 9 times out of 10 any problems are due to errors in the code. |
| ||
Seems OK on my computer. It ran at 58fps and did not slow at all. Code looks OK, too. Is it just this code that runs slow ? |
| ||
IMO its this line: If waitForVerticalBlank=1 VWait thats the problem, just remove it and replace the Flip() that is below it with: Flip(waitForVerticalBlank) |
| ||
"Is it just this code that runs slow?" Yeah. I've been running other stuff all day with no problems, but this has been bogged down since the first time I ran it and the code is barely doing anything. It's so weird. |
| ||
what are your computer specs? |
| ||
450MHz PIII with 128MB RAM and an ATI Rage Fury Pro running Win2000 I'm still getting the slowdown/lag even after shutting my computer off for the night. I'm starting to get suspicious that I picked up some spyware which is eating up my CPU. |
| ||
hey joe, try this http://download.com.com/3000-2144-10045910.html |
| ||
I get constant 83 FPS. 850MHz Athlon, 128MB RAM, GeForce 256, Win98SE |
| ||
It'll happen when an object is closely zoomed into the camera. As it does it on my machine as well. The fill rate is full. I've not managed to solve this problem yet either. |
| ||
Actually it happens even when I am zoomed way out. From paying attention to changes in the framerate I've determined that the slowdown happens when I look at the scene from specific angles, in particular straight down. Must be something to do with the architecture of my 3D hardware which prefers rendering from certain angles. |