Soldak Home   Drox Operative   Din's Curse   Depths of Peril   Zombasite  

Go Back   Soldak Entertainment Forums > Din's Curse > Din's Curse bugs
Register FAQ Members List Calendar Search Today's Posts Mark Forums Read

Reply
 
Thread Tools Display Modes
  #1  
Old 01-04-2012, 11:09 AM
Bluddy Bluddy is offline
Legend
 
Join Date: Jan 2011
Posts: 1,795
Default DW levels performance

Shadow, I've noticed that (at least on OSX) performance in levels that use dungeons from demon war is particularly bad. I've also noticed that DW seems to have a lot more high-res textures. Is it possible that mipmapping is needed to reduce the load of high textures?

Thinking about it some more still leaves me confused about why the performance is sluggish in these levels. Textures are each only saved once in the GPU memory, right? And they're pre-loaded? So I don't see why high-res textures would have such an impact.

Last edited by Bluddy : 01-04-2012 at 12:25 PM.
Reply With Quote
  #2  
Old 01-05-2012, 10:59 AM
Shadow's Avatar
Shadow Shadow is offline
Super Moderator
 
Join Date: Jun 2007
Location: Dallas, TX
Posts: 8,269
Default

The game does use mip-mapping. How the textures are loaded into the GPU is up to the graphics drivers, but yes there is only 1 copy of each texture and in general they should probably get loaded into the gpu and stay there since we don't use very much memory.
__________________
Steven Peeler
Designer/programmer
Depths of Peril, Kivi's Underworld, Din's Curse, Drox Operative, & Zombasite
Reply With Quote
  #3  
Old 01-05-2012, 11:35 AM
Bluddy Bluddy is offline
Legend
 
Join Date: Jan 2011
Posts: 1,795
Default

I've previously seen the biggest FPS drops from a. the active spawn system and b. the DW levels which are somehow different.

However, I just did a test, and the biggest drop really is a result of perspective view. We're talking about a 20-30 FPS drop, and that's on a 2Ghz Core i7 Macbook Pro. That's the difference between a minimum FPS of 45 which still seems smooth and is consistent with the performance of Kivi, and a minimum FPS of 10-15 when on an actively spawning DW level.

I don't think there should be such a big drop for perspective view -- there's definitely something wrong there. Things that come to mind are that perhaps the game is doing too many floating point view calculations per frame, or maybe it's rendering too much stuff ie more than what is visible, or there could just be some other bug in the perspective view code.

EDIT: Interestingly, DoP isn't as strongly affected by perspective view. There's a loss of around 10-12FPS. With perspective view you get around 29FPS and without it you get closer to 40. Even with perspective view though, DoP doesn't have the FPS problems that DC does. There's got to be some additional issue in DC that causes that -- perhaps the NPC simulation, though DoP has the covenants so you'd think it wouldn't be that different.

Also note that these FPS figures are for windowed mode in which I like to play most games including DC, Kivi and DoP. This uses the Intel integrated graphics as opposed to the Radeon GPU. Playing fullscreen seems to add another 30 FPS or so. But the huge disparity in DC between perspective and isometric mode is still there and it's still around 30 FPS which is way too much. Also, my windowed mode with its inferior GPU is probably a better representation of what the average player has.

2nd Edit: Actually, this seems like it's only an OSX issue. My old windows machine lost 0.5 FPS (!) switching from isometric to perspective. Whatever it is, it's specific to the Mac build. Perhaps it's a lack of optimization of floating point math... not sure, but the huge performance hit seems exclusive to the mac.

Last edited by Bluddy : 01-05-2012 at 01:07 PM.
Reply With Quote
  #4  
Old 01-05-2012, 01:24 PM
Castruccio's Avatar
Castruccio Castruccio is offline
Elite
 
Join Date: Oct 2010
Posts: 469
Default

I also lose a very noticeable amount of fps on perspective mode in full screen on DC. I am running a 2.53 GHZ i5 on Windows 7 with a 1GB Radeon 5650.

In other words, I don't think the issue is limited to OSX.
Reply With Quote
  #5  
Old 01-05-2012, 03:42 PM
Bluddy Bluddy is offline
Legend
 
Join Date: Jan 2011
Posts: 1,795
Default

Quote:
Originally Posted by Castruccio View Post
I also lose a very noticeable amount of fps on perspective mode in full screen on DC. I am running a 2.53 GHZ i5 on Windows 7 with a 1GB Radeon 5650.

In other words, I don't think the issue is limited to OSX.
Hmm.. Interesting. I wonder why I didn't see the problem on my old WinXP Celeron 1.3Ghz + Radeon laptop. Maybe it's somehow a CPU core issue -- that laptop has only a single core. How much FPS loss do you get when switching to perspective mode?
Reply With Quote
  #6  
Old 01-05-2012, 05:54 PM
Castruccio's Avatar
Castruccio Castruccio is offline
Elite
 
Join Date: Oct 2010
Posts: 469
Default

In town I get between 31-36 in perspective mode, vs, 41-46 in non-perspective mode. No weather on at the time of measurement.
Reply With Quote
  #7  
Old 01-05-2012, 09:58 PM
Castruccio's Avatar
Castruccio Castruccio is offline
Elite
 
Join Date: Oct 2010
Posts: 469
Default

In nonperspective I am getting between 57-60fps in dungeons.
Reply With Quote
  #8  
Old 01-06-2012, 10:36 AM
Shadow's Avatar
Shadow Shadow is offline
Super Moderator
 
Join Date: Jun 2007
Location: Dallas, TX
Posts: 8,269
Default

The fps difference with perspective should really depend on where you are because it ultimately lets you see more of the playing area. So it should be more of a drawing more stuff issue than any extra math in the perspective code.
__________________
Steven Peeler
Designer/programmer
Depths of Peril, Kivi's Underworld, Din's Curse, Drox Operative, & Zombasite
Reply With Quote
  #9  
Old 01-06-2012, 10:52 AM
Bluddy Bluddy is offline
Legend
 
Join Date: Jan 2011
Posts: 1,795
Default

Quote:
Originally Posted by Shadow View Post
The fps difference with perspective should really depend on where you are because it ultimately lets you see more of the playing area. So it should be more of a drawing more stuff issue than any extra math in the perspective code.
So maybe it's an issue of not enough stuff being removed (culled?) from the perspective view.

To test what you're saying, I went to the edge of a map that's not spawning, zoomed in all the way in perspective mode, and was able to get to 90 fps. All that was being rendered was a small map corner with the PC, a level gate, and some ground and map edge crystals. I then switched to ortho projection and zoomed out all the way. I was able to attain a minimum of 107 fps when zoomed all the way out. If I zoomed in slightly, to a point showing no less than perspective projection at full zoom, I was able to reach 130 fps.

So there is a very big difference between perspective and ortho projections. If it concerns the amount being rendered, then perspective projection seems to be rendering more than it should be.
Reply With Quote
  #10  
Old 01-11-2012, 10:45 PM
Bluddy Bluddy is offline
Legend
 
Join Date: Jan 2011
Posts: 1,795
Default

I just performed a small test for the heck of it, and the result was very surprising.

The attached file is a save game which under OSX quickly gets bogged down. Move around and fight for more than a minute and the fps will drop from 60 to 30, and then gradually to 14 and 8 fps. I believe the dungeon happens to be a DW dungeon, though I didn't check. I just know from experience that the DW dungeons perform much worse.

I installed DC on my mac using Wine, and amazingly enough I get a constant 60 fps (with vsync enabled) no matter what I do! Wine performs far better than the OSX executable! Clearly there's something wrong with the OSX executable. Perhaps it's related to CPU affinity, and perhaps it's a bad library, but something is wrong. It's also possible that this is a Lion issue.

UPDATE: I tried replacing the ogg and vorbis frameworks bundled with OSX DC with updated versions, and there's no improvement. I recommend for anyone who uses OSX to run DC under Wine for now.

Last edited by Bluddy : 04-03-2012 at 10:45 PM.
Reply With Quote
Reply


Thread Tools
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

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump


All times are GMT -4. The time now is 09:18 AM.


Powered by vBulletin® Version 3.6.7
Copyright ©2000 - 2017, Jelsoft Enterprises Ltd.
Copyright 2007 - 2016 Soldak Entertainment, Inc.