Product Chat / Educate me about image rendering in Game Guru... please

Author
Message
m2design
GameGuru TGC Backer
14
Years of Service
User Offline
Joined: 25th Mar 2010
Location:
Posted: 27th Nov 2016 01:19
Is it my imagination or is it real, it seems every time while in the test mode I move in any manner, every entity in my map is going through a recalculation to reflect my movement even though a large share of them are not visible to me? If this is the procedure, then stands to reason it would have a large impact on FPS count. If this is what happens I can assume that is the reason for the strange fluctuations I get in any of my maps that include terrain that at most times hide the majority of the entities. I know the terrain is not transparent but it may as well be.
Windows 10,64 bit|AMD FX-6200 Six-core-3.80 Ghz |CPU PASSMARK 6,142 |Memory 10GB |NVIDIA GEFORCE GTX 660 SC |GPU PASSMARK 4,114
DVader
20
Years of Service
User Offline
Joined: 28th Jan 2004
Location:
Posted: 27th Nov 2016 13:29 Edited at: 27th Nov 2016 13:40
Well yes. No other way to do it, you have to cycle through all objects and check if they need to be updated or not.

Of course they aren't causing a rendering cost unless on screen, just the cost of the loop to cycle through them. This is why we need culling of objects with terrain as well as other objects, alongside a billboard system for distant objects and batching objects together so they reduce the object count down etc. Terrain as far as I can tell does not occlude any objects at all, just objects with other objects at the moment.

For GG to have speed comparable to any open world game out there it would need to be able to segment the map up into chunks and load the map on the fly as you move between them. That way GG would only be cycling through the objects currently in memory and only worry about things within view distance (it's chunk/grid and those around it). I've never saw a TGC product that allows you to load things while doing anything though, you always have to wait while items load. Having a system like this would not only allow for huge maps, but probably would significantly speed up initial load times as the entire map would not have to be loaded in one go.

I think most of this is on the voting board in some fashion or another. Just well hidden in a long list ;p

Edit - I'll add that Skyrim for instance, not only streams it's objects from a database as you run around the main map, it also loads up when you enter cities so that it can load a version with more detail. Then, when in a city it also makes you load each interior individually so it can again load in more items for each house and of course remove any unseen objects as well. I've seen players complain about this, but really it's the best way to keep performance up. Even the Skyrim engine would crawl if every object, every cup and vase for the world had to be loaded up in one go.

You could emulate this in GG with lots of maps to load between, but GG's slow load times would probably be a bit much to take in comparison.


SPECS: Q6600 CPU. Nvidia 660GTX. 8 Gig Memory. Win 7.
m2design
GameGuru TGC Backer
14
Years of Service
User Offline
Joined: 25th Mar 2010
Location:
Posted: 27th Nov 2016 16:29
@DVader
Thanks for taking the time to explain.
What brought the issue of speed to my attention was the fact that while testing my map I would run into areas where the draw calls would jump way up.
These areas are where I know there are a great number of entities far away from my location but several layers behind raised terrain hills out of my cone of vision. Turn a little from this spot, draw calls are 100 turn back they jump to almost 1000. It seemed to me draw calls behind terrain were causing Strange FPS fluctuations. It is what it is I guess.

Again, thanks for the time,
Windows 10,64 bit|AMD FX-6200 Six-core-3.80 Ghz |CPU PASSMARK 6,142 |Memory 10GB |NVIDIA GEFORCE GTX 660 SC |GPU PASSMARK 4,114
3com
10
Years of Service
User Offline
Joined: 18th May 2014
Location: Catalonia
Posted: 27th Nov 2016 17:42
When you run test map, if player walk thru the trees, if you walk looking to the sky, you gain fps (stop calculations?), but it you look to the trees, fps drops drastically.

I thik the best way is GG taking care only about the items in the scene.
I believe GG has map divided into areas, and player just can be in 1 area at time, so just load the items placed in that area, and take care about them,
If player interact with some item than cause changes in an unseen item, so the script handling this item beahaviour should state it to the ebgine, so engine go to this men aadreess, where this data sit, and update it.
It should be like a theather system, The curtains goes down and everything changes, the curtains goes up, and voila, a new scene, and nobody is thinking about the stuff behind the scenes.

3com
Laptop: Lenovo - Intel(R) Celeron(R) CPU 1005M @ 1.90GHz

OS: Windows 10 (64) - Ram: 4 gb - Hd: 283 gb - Video card: Intel(R) HD Graphics

PM
smallg
Community Leader
18
Years of Service
User Offline
Joined: 8th Dec 2005
Location:
Posted: 27th Nov 2016 18:23
if you plan your map well you can script your own version of occlusion that will hide objects that are not nearby, doing it by zone markers will allow you to only make it for certain parts of the game too (when you know terrain is blocking etc).
this should greatly increase FPS.
lua guide for GG
https://steamcommunity.com/sharedfiles/filedetails/?id=398177770
windows 10
i5 @4ghz, 8gb ram, AMD R9 200 series , directx 11
m2design
GameGuru TGC Backer
14
Years of Service
User Offline
Joined: 25th Mar 2010
Location:
Posted: 27th Nov 2016 19:10
@smallg
Sometime when you have the inclination would you explain how this might be done. It sounds like a concept one might use, except for the fact that I am not clear on how this is implemented. How does one handle scripting for zone markers? I'm afraid this question alone exposes my lack of knowledge in some important areas of Game Guru. I have been spending time making pretty pictures without realizing the impact of my efforts. It has been fun but...
Windows 10,64 bit|AMD FX-6200 Six-core-3.80 Ghz |CPU PASSMARK 6,142 |Memory 10GB |NVIDIA GEFORCE GTX 660 SC |GPU PASSMARK 4,114
Pirate Myke
Forum Support
14
Years of Service
User Offline
Joined: 31st May 2010
Location: El Dorado, California
Posted: 28th Nov 2016 02:43
DVader made this script for distribution you may find useful.

https://forum.game-guru.com/thread/213347
Intel(R) Core(TM)2 Quad CPU Q6600 @ 2.40GHz, 2400 Mhz, 4 Core(s), 4 Logical Processor(s), 8gb RAM, Nvidia gtx660, Windows 7 Pro 64bit, Screen resolution 1680 x 1050.

DVader
20
Years of Service
User Offline
Joined: 28th Jan 2004
Location:
Posted: 29th Nov 2016 14:36 Edited at: 29th Nov 2016 14:54
Beat me to it Pirate Mike I did make some serious speed gains with that script. Not sure how effective it is now with occlusion built in, but it may be even faster than it was. I'll dig it out and see how it runs now.

Edit - Tried a couple and as I suspected speed is back down, not much difference between enabling it or not now. I used to get 30+fps on the tree scene, now it's down to about 16. So either I messed the script up at a later stage, or GG has changed to the degree where it no longer increases speed. It could be the default settings have reset, I didn't really test beyond checking it was enabled and running the occlusion script.

You could use the same sort of idea, but with more select areas I imagine rather than occluding every object on the map. It may work faster that way as you only have to hide the objects once and show them when you leave the area or zone.


SPECS: Q6600 CPU. Nvidia 660GTX. 8 Gig Memory. Win 7.
m2design
GameGuru TGC Backer
14
Years of Service
User Offline
Joined: 25th Mar 2010
Location:
Posted: 29th Nov 2016 16:13

@DVader

I did download the lua files and tried them with my current map which contains 638 entities (custom buildings and stock trees).
I have studied the files and understand the intent, but after several attempts, tinkering with variables, I found no significant fps improvement.

I think Game Guru may of made several occlusion revisions that have affected the results. Changing the distance I can see when the entities are turned on and off but the fps seems to reflect minimal impact.

Although the test maps you provided show otherwise...
Windows 10,64 bit|AMD FX-6200 Six-core-3.80 Ghz |CPU PASSMARK 6,142 |Memory 10GB |NVIDIA GEFORCE GTX 660 SC |GPU PASSMARK 4,114

Login to post a reply

Server time is: 2024-09-29 01:19:49
Your offset time is: 2024-09-29 01:19:49