Search Unity

Implementing massive buildings in Unity?

Discussion in 'Editor & General Support' started by fleskil, Aug 22, 2019.

  1. fleskil

    fleskil

    Joined:
    Aug 16, 2019
    Posts:
    1
    Hello,

    Im working on a test project where im are going to implement 5 buildings that has been converted from IFC to FBX. The fbx file contains ALOT of gameobjects. I dont know how many nor how to count them. I have somewhere between 100 and 150 hours in Unity, but its a long time ago. Im barely managing to work on one building without making the editor very angry. Each FBX file is about 50MB.

    I need some general directions or hints on how to tackle this.

    some requirements:

    -needs to run in WebGL on a potato.
    - Cross section of stories in building.
    - if possible, somehow keep all the individual gameobjects so that the user can select it and get information. F.ex to see or mark when the last maintanance or replacement was done. (i was thinking it might increase performance to somehow make the building one single solid gameobject.)

    what ive done:
    -I have managed to set LOD groups with the asset Automatic LOD(pay 2 win, hehe).
    -Implement cross section on the whole building.(performance is horrible)

    Ideas:

    Reduce polygons/verts/something in Blender(?).
    Make it one gameobject?
    Reduce quality.
    Get me a external GPU.
    Post on forums.

    Any replies would be appreciated :)

    Screenshot:

    upload_2019-8-22_10-54-56.png
     
  2. kdgalla

    kdgalla

    Joined:
    Mar 15, 2013
    Posts:
    4,635
    How many game objects are we talkin' here? That screenshot doesn't look so bad.

    One other question: It looks like you have a lot of objects that are going to look exactly the same as each other, i.e. repeating wall chunks and such. In these cases, do the objects all share the same mesh asset, or are you duplicating the mesh for each object?
     
    Last edited: Aug 22, 2019
    Joe-Censored likes this.
  3. Antypodish

    Antypodish

    Joined:
    Apr 29, 2014
    Posts:
    10,770
    If you never change building's structure, you could optimize it by far, by making single or fewer modules of building, rather than each single element.
    You can have single facade for example, rather than piece of facade per floor. This way you will reduce poly count.

    LOD, polling objects, culling and material GPU instancing, can give you significant performance boost.
    However, if you want to keep as much modular as possible and we would talk about thousands of elements per building/floor, you may be interested to look into DOTS MegaCity demo.
     
  4. Vectorbox

    Vectorbox

    Joined:
    Jan 27, 2014
    Posts:
    232
    As you mention, Blender can be used to optimise meshes... 'Edit Mode / X Key / Limited Dissolve'

    It's always a good idea to make a copy of your FBX before editing. Also note than 'limited dissolve' may merge materials.