Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

Newcomers DBPro Corner / Easier way to load Many objects without such a decrease in FPS?

Author
Message
Dreamon Star
17
Years of Service
User Offline
Joined: 24th Feb 2007
Location: The Frozen Wasteland
Posted: 3rd May 2007 08:19 Edited at: 3rd May 2007 08:23
Ok, here's the dilema, I use to try loading the level as 1 object, but found that it had an undesired effect. So, I loaded it into pieces, the stairwell, the rooms furniture as 1, and the roof, the walls, all separate. I know it's probably the dumbest way to do this, but it seemed to have the best appearance. But, here's the problem now... Obviously, my FPS have dropped so low, that it'll run at 11 FPS... and the level is FAR from finished, but obviously again, when not facing the bulk of the objects, it increases to 150...

I am sure that it's to do with it having such a high polycount, or trying to detect collision on all objects... but, am unsure how to fix this, i have decreased the camera range, but, only to a point that things just don't pop up without fair notice.... any ideas, thanx in advance!

P.S. OH, and one more thing... I was just wondering another dumb thing. It's about camera collision, i have the camera set so that you can zoom into first person, or 3rd, but, in third, the camera passes through walls, and is there a way to keep it from going through the walls? thanks again

www.soundclick.com/octoberscry ---> My Doom Metal Band
TDK
Retired Moderator
22
Years of Service
User Offline
Joined: 19th Nov 2002
Location: UK
Posted: 3rd May 2007 08:28
There are lots of tips in this thread which apply to both DBP as well as DBC:

http://forum.thegamecreators.com/?m=forum_view&t=32948&b=10

It sounds like you need a combination of hiding objects not in the cameras view as well as anything further away than a specified distance.

When inside buildings, you should also hide all outside objects too - in other words, load interiors separately.

TDK_Man

Dreamon Star
17
Years of Service
User Offline
Joined: 24th Feb 2007
Location: The Frozen Wasteland
Posted: 4th May 2007 02:06 Edited at: 4th May 2007 02:20
Thanks for that link, it helped a bit, but i was considering loading interiors and masking exteriors, but was not too sure for when inside there is windows which I was intending on making breakable, which would lead to the outside, and the windows are ghosts. I'll try something along those lines, but wouldn't just setting the camera range hide the unseen polys?

Since my entire world is made of blocks linked together, i'll try to just use a plain instead, should help i think... but, i think hiding polys that are not facing the player would work better, but am still a little unclear on how to do so, but haven't tried that yet either....

thanx again...

EDIT - WOW, i just put a plain instead of cubes for the base terrain, and already it increased my FPS by 5X, up to 56... but, this will still not be quite fast enough considering i haven't added 3 floors still, or characters, or even height in my terrain, which will be using sepparate objects.

www.soundclick.com/octoberscry ---> My Doom Metal Band
RUCCUS
19
Years of Service
User Offline
Joined: 11th Dec 2004
Location: Canada
Posted: 5th May 2007 03:15
Option A) Instead of an outside scene for your windows, just have a plain textured with an outside image positioned outside of your windows with it's lighting off so it looks more real..

Option B) Have an outside map, but make it very small through the use of a few trees, rocks, and other large landmarks that will block the view required by having a huge map.

Dreamon Star
17
Years of Service
User Offline
Joined: 24th Feb 2007
Location: The Frozen Wasteland
Posted: 6th May 2007 01:37 Edited at: 6th May 2007 20:04
well, my map isn't really too huge yet, it's just that i have loaded each part as an object, such as the wood framing for a wall (which seems silly, but because it is protuding outwards, and joining it creates an issue with the textures, because is sometimes adds more vertex's from what it seems, thus changing the appearance)

I tried adding a box on the interior of one building, so that when i use object collision it will hide all material which will not be seen at all, but it doesn't trigger properly, and may not trigger at all...

And since windows are breakable, you will be able to break it and jump outside onto a roof of an opposing building... so, i'm stumped.... it seems either way somethings gotta go...

Sad thing is i haven't even been able to start making too much of the landscape yet, just 3 buildings and a plain... lol...

Thanx though ruccus, i'm going to have to experiement around a bit, maybe i set the collision boxes wrong, or wrong objects hidden...


Ok, this is kinda what i have, very basic, but I have 2 boxes hidden, but for some odd reason none of this wants to really work out... Just so you know ahead, they go from 10 to 49, and so forth, not just one, i just shortened it for easier reading, and this is in a function, which is called every loop




Just out of curriousity.... would having so many small fine detailed objects on the screen which all have collision detection on them be the result of decreased FPS, and should i create a hidden collision box for each building instead so it only detects for collision on that box, instead of so many objects? or is it mostly because of visible polys? and what would be a decent amount of visible polys on the screen anyways? I don't know exactly how to know howmany polys are visible though... sorry for it being so long now hehe... thanks a TONNE

www.soundclick.com/octoberscry ---> My Doom Metal Band
RUCCUS
19
Years of Service
User Offline
Joined: 11th Dec 2004
Location: Canada
Posted: 7th May 2007 19:05
You definitely shouldn't be loading each thing seperately, thats what is causing you the lag. For every object loaded, dx has to store tonnes of information; position, rotation, visibility, shader settings (even if they're off), collision settings, lots more.

Cliff Mellangard 3DEGS
Developer
18
Years of Service
User Offline
Joined: 20th Feb 2006
Location: Sweden
Posted: 8th May 2007 00:45
have you tryed to instance the objects?
for every object keep an master object that you dont change simply that you hide.
as all the instanced objects you have of the master can you position rotate scale as you want.
you can sadly not alter the texture or ghosting separately on them.
as that have to be done on the master model.
it should boost your fps alot to use instanced objects instead.
cheers
Dreamon Star
17
Years of Service
User Offline
Joined: 24th Feb 2007
Location: The Frozen Wasteland
Posted: 8th May 2007 23:46
@Cliff -- No, i haven't tried to instance any objects because every single one is of different characteristics... nothing is the same... yet... until i get to the landscape, but, i definately will be considering that when i get into that area... this is mostly all indoor materials, like walls, statues, desks, paper, lamps, you name it...

@Ruccus -- Thanks for the info... but, how would i load such objects then, because when i join them all together, the texture gets lost, and sometimes it even looses parts, and deletes areas of the level, I use Gamespace to do all my creations.... it's easy to use but, i find that there is some issues with it... any ideas? or should i just "suck it up" and accept that the level should mostly be 1 object for the most part?

Thanx guys

www.soundclick.com/octoberscry ---> My Doom Metal Band
RUCCUS
19
Years of Service
User Offline
Joined: 11th Dec 2004
Location: Canada
Posted: 9th May 2007 02:24
That shouldnt be happening. With pretty much every modeller Ive used
(and ive used a tonne), when you combine objects, texture information isnt changed. I know gamespace is a well-known title, so Im pretty sure its not a problem on their part, are you positive you're combining them properly? Maybe your choosing some sort of "Convert to Single Mesh" option instead of just grouping them and exporting?

Dreamon Star
17
Years of Service
User Offline
Joined: 24th Feb 2007
Location: The Frozen Wasteland
Posted: 9th May 2007 04:03
well, i have no clue why it is doing such a thing, i found it odd... as far as if i'm joining them properly, i'm not too sure what you mean by that, wouldn't it just be the group object button, cause i can group some, but every once in a while somethings just don't want to group properly and it looks as though on the texture it puts a line through it usually on a diagnal \/ ... all i've been doing is click one main object and then just click on the other objects wished to join...

or could i also just select all objects and save all as one .x file without having to group them? or no? not that i use this method...

www.soundclick.com/octoberscry ---> My Doom Metal Band
RUCCUS
19
Years of Service
User Offline
Joined: 11th Dec 2004
Location: Canada
Posted: 10th May 2007 04:14
Why not try?

Usually selecting all objects and exporting without grouping works fine.

Dreamon Star
17
Years of Service
User Offline
Joined: 24th Feb 2007
Location: The Frozen Wasteland
Posted: 10th May 2007 04:18 Edited at: 10th May 2007 05:06
so, if i don't group or as said in Gamespace "Union object" it shouldn't have this problem, but export as 1 object? I kinda have just tried this but, with as much grouping as possible to reduce some unnecessary poly's... and there was for some reason... some textures not appearing... as if they didn't exist... i'll give it another shot though...

EDIT --- well tried that... and unfortunately everything was in the most messed up places, and could not be fixed or because some objects were in the complete wrong spots.... but, in a way i managed to cut it down to like 6 objects... for exterior only... and probably 10 for interior... not including moving objects which will need to be separate objects on thier own...

www.soundclick.com/octoberscry ---> My Doom Metal Band
www.soundclick.com/outercharm ----> Progressive Metal Stuff
<---GO NOW---> hehehe
RUCCUS
19
Years of Service
User Offline
Joined: 11th Dec 2004
Location: Canada
Posted: 10th May 2007 05:13 Edited at: 10th May 2007 05:13
:/ How does grouping effect unnecessary polies? It sounds like this Union object command is basically joining polies from every object and deleting polies that wont be seen after the join, which will definitely effect uv-data. There should just be a "group object" command.

Id seriously recommend trying out Wings 3D, I use it all the time for knocking up some quick models, dont let it being free fool you, its very powerful. And this grouping problem wont be there... just select all of the objects, right click, select combine, then file > export... done.

Dreamon Star
17
Years of Service
User Offline
Joined: 24th Feb 2007
Location: The Frozen Wasteland
Posted: 10th May 2007 05:22
hmmm, well, i'll give that a shot for sure... but, since i've made SO many objects in caligari already, it'll be hard, but i guess i can just export .x and then import into Wings right? Cause even with what i've got, it has sped it up a good amount, but, some issues remain with textures... annoying problems eh?

I'm concerned for when i load the interior... lol, should i still have the interior and exterior as 1 object then, or 2 separate, since i wish to have windows breakable... i know i brought it up before... but, that'll make the game that much more realistic, which is a big part of it, hopefully...

Thanks tonnes Ruc! You've been a great help so far...

www.soundclick.com/octoberscry ---> My Doom Metal Band
www.soundclick.com/outercharm ----> Progressive Metal Stuff
<---GO NOW---> hehehe
Dreamon Star
17
Years of Service
User Offline
Joined: 24th Feb 2007
Location: The Frozen Wasteland
Posted: 11th May 2007 02:53
Ok, I tried out Wings, and it looks like it did a good job in the program, but it keeps crashing DBP... dunno why... but, the .x files, seem to make it run slow, but fine... and the .x had indoor and outdoor all loaded at the same time... 3ds was just outdoor... the nice thing about wings was that i now know how many faces there are... though, would someone be able to give me an estimate of a reasonable amount of faces on a screen at any given time... cause my exterior is about 20,000... and interior is about 82,000... yeah, it's up there... or if there is any way to reduce this without reducing quality... thanx... and sorry for any hastle i've become...

www.soundclick.com/octoberscry ---> My Doom Metal Band
www.soundclick.com/outercharm ----> Progressive Metal Stuff
<---GO NOW---> hehehe
Dreamon Star
17
Years of Service
User Offline
Joined: 24th Feb 2007
Location: The Frozen Wasteland
Posted: 11th May 2007 20:09
Ok, I just found out that for some reason .3ds files just keep crashing the program no matter what... and that, for some reason i guess the files are too large, and crashes the program too... what's going on? thanx

www.soundclick.com/octoberscry ---> My Doom Metal Band
www.soundclick.com/outercharm ----> Progressive Metal Stuff
<---GO NOW---> hehehe

Login to post a reply

Server time is: 2024-11-25 17:30:12
Your offset time is: 2024-11-25 17:30:12