Jump to content

Performance and other things


Alienhead
 Share

Recommended Posts

I find myself concerned as of late with some performance issues I've stumbled across. I'm hoping for some information I may not have heard about thus far.  OKay, here's the situation - To better test this I created a complete blank project that consists of - 1 terrain 256x256,  32x32 color texture for the terrain. I have NO PHYSICS working whatsoever, I have set the light quality to its lowest setting. In other words pretty much a bare bones scene. The towers in the scene are less than 300 polys each. 

When I get 2 or more animated models on the screen I start getting some serious jerky camera motion and  the overall smoothness flies out the window.  The model consists of 1293 Polys, 19 bones and 2 animation sequences with 21 frames per sequence ( very light and minimal for an animated model ), further more I took the animated shadow shader off and I have all my marterials set for Non-Picking. 

I'm running a AMD Ryzen 9 5900X, and a GTX 1080 geforce.  The system runs nearly anything on the market ( so hardware isnt a concern ).

In the video below I demo the results.

 

And thats just with a few models on the screen.   Is this normal?   I'm looking to have many many more of these guys on a map at once, this is the reason I kept all the assets very very low.   The funny thing is I can load the scene up with 2million polys and for the most part everything stays smooth. It just when I introduce animation to the scene that problems start to occur. 

 

I have also tried different models thinking my animation or bone setup may have had something to do with it, but no such luck. 

I'm only happy when I'm coding, I'm only coding when I'm happy.

Link to comment
Share on other sites

Problem solved, I've been hunting this for days now.. In case anyone else is running this setup - I suggest not.  The cause was Tab-Nine intellisense engine combined with Lua debugger ( SubDebug ) running in Sublime 4.   The reason it was so hard to find; the debugger stayed running as a service even when I shutdown Sublime, so I didnt look any further with sublime since I had shut it down. :)

 

 

 

  • Haha 1
  • Upvote 1

I'm only happy when I'm coding, I'm only coding when I'm happy.

Link to comment
Share on other sites

I may of jumped the gun,   while killing the debugger did help,  I still have noticed that 10 or more animated models causes a huge jerkiness in the overall performance of the app.   The test was ran on a blank map, 433 poly model with only 13 bones, no physics involved and I shut down the lighting.   I'm starting to lean toward the idea that the desktop refresh rate the the virtual  window aren't syncing. 

I'm only happy when I'm coding, I'm only coding when I'm happy.

Link to comment
Share on other sites

That's just it, I have ZERO physics working in this simulation,  I'm building a top down tower-defense game and it requires no collisions. Just waypoint pathfinding.  Also testing the simulation out on another PC, I noticed my camerapicks to map objects were way off, do I need to adjust entity picks from camera based on resolutions ? 

 

 

I'm only happy when I'm coding, I'm only coding when I'm happy.

Link to comment
Share on other sites

I think the models are probably using the model geometry for collisions and the player collision against that is very slow. Generating a convex hull or convex decomposition shape for them would make it lot faster.

My job is to make tools you love, with the features you want, and performance you can't live without.

Link to comment
Share on other sites

2 hours ago, Josh said:

I think the models are probably using the model geometry for collisions and the player collision against that is very slow. Generating a convex hull or convex decomposition shape for them would make it lot faster.

Surely not faster than faster than having no physics body to begin with ?.    I have no player collision controller/body as the camera just floats in the air, its a town down tower defense style. 

I'm only happy when I'm coding, I'm only coding when I'm happy.

Link to comment
Share on other sites

That blog post doesn't mention animations or skinning, which is probably the issue. I never could run more than a couple of characters in Leadwerks.

You should probably try stopping all animations or deleting all the bones in your scene to check if it's because of animations.

Link to comment
Share on other sites

Okay, I've compiled a video - this video has a-LOT of animation stuff going on, birds, ants, butterflies, fish, mobs, players, wind .. its very animation heavy.  What I did was remove the normal mob model I was using, which was 792 polys with 23 bones, and replaced it with a 200 poly 8 bone model just for testing.. I got 50 mobs running in the scene towards the end.  It seems my frame rates were steady.  Could this be the prior mob having 20+ bones in it ?

Ahh hell, guess it would help if I upload the correct video ..  one sec...

Edited by Alienhead

I'm only happy when I'm coding, I'm only coding when I'm happy.

Link to comment
Share on other sites

Your project looks cool and I want to help but I can't debug it just by watching it. We need at least the model file to load up ourselves and look ta.

I won't be working all weekend long but I can examine it Monday, or maybe  someone on the forum might find something.

My job is to make tools you love, with the features you want, and performance you can't live without.

Link to comment
Share on other sites

I'll upload some media when I get back home, but I think I finally figured it out. I dumped the navmesh system and took the mobs off their character rigs and went with a straight forward waypoint node ( aStar type pathfinding ) and the frame rates picked WAY WAY up.  I've kept the navmesh system in tact for player pets to follow and occasional boss spawns that chase the player around the map, but for the 100's of minions I released from character rigs and it's really improved the frame rates, its playable now on my good coding rig and even on a mid-range testing rig I got..

 

Thanks !

I'm only happy when I'm coding, I'm only coding when I'm happy.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

 Share

×
×
  • Create New...