Please login or register.

Login with username, password and session length
Advanced search  

News:

For WME related articles and tutorials visit WME Resource Center.

Pages: 1 2 [All]

Author Topic: perfomance issues  (Read 10600 times)

0 Members and 1 Guest are viewing this topic.

SoundGuy

  • Regular poster
  • ***
  • Karma: 0
  • Offline Offline
  • Posts: 196
    • View Profile
perfomance issues
« on: September 17, 2009, 04:31:58 AM »

Hey,

I hope you all know we released Pizza Morgana about a month ago.
today one of the reviewers from Adventure-treff complained about bad performance once there is more than one actor on screen, and i'm trying to figure out how to help him get the game performing correctly.
some details,
each of our characters has 3000-5000 polys, with the contour model and we have another closeup model for closeup, but its the same model for now.
when all 3 actors are in the scene it's 20,000 polys to render. on my poor laptop, with geforce 7400 i get 16FPS in debug mode,  a little more in release.
i know we have some batching problems with the watcher (he is made up from 4 object and 4 textures, we'll correct that on the next version) which might cause slowness, BUT this guy is complaining about performance issues to the extent that the game is unplayable even with only jackie and abbie (about 12,000 polys when both are on screen in Jackie's house)

his hardware is :
Athlon XP 3000+, Geforce 7600 with 256 MB, 2 GB RAM.
desktop, decdicated graphics card, latest nvidia drivers, DXdiag says everything is ok. he ran "mental repairs inc" and it worked ok for him.


any ideas?
Logged

Mnemonic

  • WME developer
  • Administrator
  • Addicted to WME forum
  • *
  • Karma: 41
  • Offline Offline
  • Gender: Male
  • Posts: 5683
    • View Profile
    • Dead:Code Site
Re: perfomance issues
« Reply #1 on: September 17, 2009, 07:41:33 AM »

I don't remember, are you using D3D9 with T&L enabled in your game?
What windows version are they using?
Logged
Yes, I do have a twitter account
Please don't send me technical questions in private messages, use the forum. ::wave

SoundGuy

  • Regular poster
  • ***
  • Karma: 0
  • Offline Offline
  • Posts: 196
    • View Profile
Re: perfomance issues
« Reply #2 on: September 17, 2009, 12:10:05 PM »

the setting in the project manager are:
use direct3d9 : no
hardware t&l : use when available.
Logged

Mnemonic

  • WME developer
  • Administrator
  • Addicted to WME forum
  • *
  • Karma: 41
  • Offline Offline
  • Gender: Male
  • Posts: 5683
    • View Profile
    • Dead:Code Site
Re: perfomance issues
« Reply #3 on: September 17, 2009, 12:24:30 PM »

You may want to consider using DX9. I noticed in Vista, DX8 with hardware T&L enabled runs actually slower than without it. Kind of unexpected. It worked okay in WinXP.
Logged
Yes, I do have a twitter account
Please don't send me technical questions in private messages, use the forum. ::wave

SoundGuy

  • Regular poster
  • ***
  • Karma: 0
  • Offline Offline
  • Posts: 196
    • View Profile
Re: perfomance issues
« Reply #4 on: September 17, 2009, 01:42:36 PM »

i'll try that. thanks
Logged

SoundGuy

  • Regular poster
  • ***
  • Karma: 0
  • Offline Offline
  • Posts: 196
    • View Profile
Re: perfomance issues
« Reply #5 on: September 21, 2009, 10:33:09 AM »

he actually has  windows xp with service pack 3 installed.
any other ideas?

maybe he got some incompatible dx8 version? is there a way to check?
Logged

Mnemonic

  • WME developer
  • Administrator
  • Addicted to WME forum
  • *
  • Karma: 41
  • Offline Offline
  • Gender: Male
  • Posts: 5683
    • View Profile
    • Dead:Code Site
Re: perfomance issues
« Reply #6 on: September 21, 2009, 05:22:53 PM »

Well I tested the game on my computer, with debug mode enabled. It runs at 70 FPS (the remote scene in the forest), and if I press escape and display the main menu, the framerate jumps to 250. From that I'd assume your bottleneck aren't models, but scripts.
Logged
Yes, I do have a twitter account
Please don't send me technical questions in private messages, use the forum. ::wave

SoundGuy

  • Regular poster
  • ***
  • Karma: 0
  • Offline Offline
  • Posts: 196
    • View Profile
Re: perfomance issues
« Reply #7 on: September 22, 2009, 03:47:03 PM »

I think the reason it jumps to 250 in the menu is because it doesn't render the models, because the menu is system exclusive, or am i wrong?
if its the scripts, do i have any way to performance profile it ?
Logged

Mnemonic

  • WME developer
  • Administrator
  • Addicted to WME forum
  • *
  • Karma: 41
  • Offline Offline
  • Gender: Male
  • Posts: 5683
    • View Profile
    • Dead:Code Site
Re: perfomance issues
« Reply #8 on: September 22, 2009, 03:49:42 PM »

You are wrong. The models are still rendered (the scene is still being drawn under the menu), but the game scripts are frozen.
There's no script profiler as of now.
Logged
Yes, I do have a twitter account
Please don't send me technical questions in private messages, use the forum. ::wave

SoundGuy

  • Regular poster
  • ***
  • Karma: 0
  • Offline Offline
  • Posts: 196
    • View Profile
Re: perfomance issues
« Reply #9 on: September 22, 2009, 03:54:52 PM »

i just ran Episode 2 in debug with several watchers on the screen
when the game is running i get 14FPS
when paused its 42FPS.
i got:
Running Scripts 113: (R:2 w:0 p:111)

can you think of ANY way for me to figure out which is (are) the problematic script (s?)

i don't have any "busy waiting" loops and all those that have for...sleep ones have relatively high number (part for the game deamon that i think has Sleep (20);
Logged

SoundGuy

  • Regular poster
  • ***
  • Karma: 0
  • Offline Offline
  • Posts: 196
    • View Profile
Re: perfomance issues
« Reply #10 on: September 22, 2009, 04:00:26 PM »

Episode 1:
Running scripts: 96 (R:5 w:1 p:86)

when paused
Running scripts: 102 (R:9 w:1 p:92)
Logged

Mnemonic

  • WME developer
  • Administrator
  • Addicted to WME forum
  • *
  • Karma: 41
  • Offline Offline
  • Gender: Male
  • Posts: 5683
    • View Profile
    • Dead:Code Site
Re: perfomance issues
« Reply #11 on: September 23, 2009, 10:22:11 AM »

can you think of ANY way for me to figure out which is (are) the problematic script (s?)
That would be those few always running scripts (R:(unning) and W:(aiting)). The P:(persistent) scripts don't affect performance. Not significantly at least.
Logged
Yes, I do have a twitter account
Please don't send me technical questions in private messages, use the forum. ::wave

SoundGuy

  • Regular poster
  • ***
  • Karma: 0
  • Offline Offline
  • Posts: 196
    • View Profile
Re: perfomance issues
« Reply #12 on: September 23, 2009, 01:47:46 PM »

any idea how to find out which ones are the R: ones ?
maybe i can use my compiled version of WME in debug mode and place some breakpoint ?
Logged

SoundGuy

  • Regular poster
  • ***
  • Karma: 0
  • Offline Offline
  • Posts: 196
    • View Profile
Re: perfomance issues
« Reply #13 on: September 23, 2009, 01:48:51 PM »

i vaguely remember there was some "dump" variable or something that would also dump running scripts, will that help?
i forgot the commands name
Logged

Mnemonic

  • WME developer
  • Administrator
  • Addicted to WME forum
  • *
  • Karma: 41
  • Offline Offline
  • Gender: Male
  • Posts: 5683
    • View Profile
    • Dead:Code Site
Re: perfomance issues
« Reply #14 on: September 23, 2009, 01:53:50 PM »

The R: ones are typically the ones similar to game_loop.script. Those containing an endless loop and doing stuff all the time. If you want to dig into the code, that would be CScEngine::Tick(). Also in the debug console the running scripts are the ones with green icon.
Logged
Yes, I do have a twitter account
Please don't send me technical questions in private messages, use the forum. ::wave

SoundGuy

  • Regular poster
  • ***
  • Karma: 0
  • Offline Offline
  • Posts: 196
    • View Profile
Re: perfomance issues
« Reply #15 on: September 23, 2009, 02:02:40 PM »

thanks. i'll see what i can find.
Logged

Mnemonic

  • WME developer
  • Administrator
  • Addicted to WME forum
  • *
  • Karma: 41
  • Offline Offline
  • Gender: Male
  • Posts: 5683
    • View Profile
    • Dead:Code Site
Re: perfomance issues
« Reply #16 on: September 23, 2009, 02:03:33 PM »

And no, there's no dump for scripts. You probably mean the texture stats.
Logged
Yes, I do have a twitter account
Please don't send me technical questions in private messages, use the forum. ::wave

Mnemonic

  • WME developer
  • Administrator
  • Addicted to WME forum
  • *
  • Karma: 41
  • Offline Offline
  • Gender: Male
  • Posts: 5683
    • View Profile
    • Dead:Code Site
Re: perfomance issues
« Reply #17 on: September 23, 2009, 02:04:25 PM »

But I agree some kind of simple script profiler would be a nice feature to have.
Logged
Yes, I do have a twitter account
Please don't send me technical questions in private messages, use the forum. ::wave

SoundGuy

  • Regular poster
  • ***
  • Karma: 0
  • Offline Offline
  • Posts: 196
    • View Profile
Re: perfomance issues
« Reply #18 on: September 23, 2009, 02:53:26 PM »

please add to the feature request list for WME 2 ;)
Logged

SoundGuy

  • Regular poster
  • ***
  • Karma: 0
  • Offline Offline
  • Posts: 196
    • View Profile
Re: perfomance issues
« Reply #19 on: September 26, 2009, 05:33:09 AM »

i just looked at the scripts in the debugged, NONE are green. There are two who are in a wait state, and those are the deamons, one for hints with Sleep (100)
and the game_Deamon.script with Sleep(20)
Logged

SoundGuy

  • Regular poster
  • ***
  • Karma: 0
  • Offline Offline
  • Posts: 196
    • View Profile
Re: perfomance issues
« Reply #20 on: September 26, 2009, 05:44:54 AM »

i just added some debug lines to see if it is the game_daemon, and no.

       Game.Msg("End " + Game.WindowsTime + " total " + (Game.WindowsTime  - this.StartTime)); 
   
   Sleep(20);
   this.StartTime = Game.WindowsTime;
   Game.Msg("Start " +Game.WindowsTime);

i get totals of 0-1 (sometimes 2)
for some reason the time displays is a huge negtive one, but that's probably before the INT has passed its half and its 2 complement
Logged

SoundGuy

  • Regular poster
  • ***
  • Karma: 0
  • Offline Offline
  • Posts: 196
    • View Profile
Re: perfomance issues
« Reply #21 on: September 28, 2009, 11:57:33 PM »

mnemonic, any ideas how to find out the the running scripts,if nothing is green in the debugger?
Logged

odnorf

  • w00t?
  • Global Moderator
  • Addicted to WME forum
  • *
  • Karma: 7
  • Offline Offline
  • Gender: Male
  • Posts: 1456
  • Lamp dog!
    • View Profile
Re: perfomance issues
« Reply #22 on: September 29, 2009, 08:37:36 AM »

Check wme 1.9beta. I'm sure you'll find the 2 new methods for gathering script execution time statistics very useful.
Logged
fl*p
Pages: 1 2 [All]
 

Page created in 0.126 seconds with 20 queries.