Wayback Machinekoobas.hobune.stream
May JUN Jul
Previous capture 12 Next capture
2021 2022 2023
1 capture
12 Jun 22 - 12 Jun 22
sparklines
Close Help
  • Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
  • Asset Store
  • Get Unity

UNITY ACCOUNT

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account
  • Blog
  • Forums
  • Answers
  • Evangelists
  • User Groups
  • Beta Program
  • Advisory Panel

Navigation

  • Home
  • Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
    • Blog
    • Forums
    • Answers
    • Evangelists
    • User Groups
    • Beta Program
    • Advisory Panel

Unity account

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account

Language

  • Chinese
  • Spanish
  • Japanese
  • Korean
  • Portuguese
  • Ask a question
  • Spaces
    • Default
    • Help Room
    • META
    • Moderators
    • Topics
    • Questions
    • Users
    • Badges
  • Home /
  • Help Room /
avatar image
0
Question by GregZ · Jan 06, 2017 at 10:11 AM · terrainperformanceoptimizationprocedural

How does many terrains on scene affect performance?

So, I made a tiny terrain with trees, which I saved as a prefab and want to replicate using script all across the scene (this is just a test for now, I might make a terrain generator using this method). The editor view started lagging a bit after I made a few duplicates:

alt text

alt text

The question is, how well can Unity handle multiple terrains? Is there a way to optimize those tree patches, or should I stop trying?

imagfwfwfe-3.jpg (401.2 kB)
imagefwfwf-2.jpg (341.8 kB)
Comment
Add comment · Show 2
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users
avatar image tanoshimi · Jan 06, 2017 at 10:12 AM 0
Share

What benefit are you trying to achieve from duplicating a tiny terrain lots of times rather than just having a single large terrain, which will allow Unity's inbuilt terrain LOD system to work better?

avatar image GregZ tanoshimi · Jan 06, 2017 at 10:23 AM 0
Share

It'll allow me to generate the map by just instantiating tiny pieces ins$$anonymous$$d of generating texture or trees or modifying height directly. Just easier that way.

1 Reply

· Add your reply
  • Sort: 
avatar image
1
Best Answer

Answer by Wolfdog · Jan 06, 2017 at 11:35 AM

Terrain in Unity isn't great for performance. This is clearly visible the larger the terrain gets. Splitting it up into smaller pieces is in fact the way some people have tried to improve performance. However, from what I can see, you will have an insanely large amount of these terrains. This might actually be worse than just one terrain piece, simply because of the number of them. This is similar to trying to render one model with 10,000 faces vs 10,000 models with one face each. The larger model is easier to render.

Increasing the terrain chunk size and simply having less of them should improve performance, and only rendering the terrain chunks visible by a camera should again improve performance significantly (occlusion culling).

If this is the way you want to do it, then you should take a look at methods which convert terrain to mesh, as mesh it easier on performance. There are scripts on the internet which can convert terrain objects to mesh, keeping trees and grass orientated. However, the terrain will lose some detail.

I can remember using TerrainObjExporter in the past, but I don't know whether it will work in real time, or only in the editor, so it might not be what you're looking for.

Comment
Add comment · Show 1 · Share
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users
avatar image GregZ · Jan 06, 2017 at 01:38 PM 0
Share

Ok thanks I think this idea was a bit crazy, I should just use one of the paid terrain generation tools from the asset store, ins$$anonymous$$d of reinventing the wheel.

Your answer

Hint: You can notify a user about this post by typing @username

Up to 2 attachments (including images) can be used with a maximum of 524.3 kB each and 1.0 MB total.

Follow this Question

Answers Answers and Comments

5 People are following this question.

avatar image avatar image avatar image avatar image avatar image

Related Questions

Best way to make a huge terrain for flight simulator? 1 Answer

Sprite optimization for animation 0 Answers

World Scale optimization for processing and rendering 1 Answer

Is Removing Ngons a Good Thing to do in Unity? 0 Answers

Sprite size much bigger than originally - how to resolve 0 Answers


Enterprise
Social Q&A

Social
Subscribe on YouTube social-youtube Follow on LinkedIn social-linkedin Follow on Twitter social-twitter Follow on Facebook social-facebook Follow on Instagram social-instagram

Footer

  • Purchase
    • Products
    • Subscription
    • Asset Store
    • Unity Gear
    • Resellers
  • Education
    • Students
    • Educators
    • Certification
    • Learn
    • Center of Excellence
  • Download
    • Unity
    • Beta Program
  • Unity Labs
    • Labs
    • Publications
  • Resources
    • Learn platform
    • Community
    • Documentation
    • Unity QA
    • FAQ
    • Services Status
    • Connect
  • About Unity
    • About Us
    • Blog
    • Events
    • Careers
    • Contact
    • Press
    • Partners
    • Affiliates
    • Security
Copyright © 2020 Unity Technologies
  • Legal
  • Privacy Policy
  • Cookies
  • Do Not Sell My Personal Information
  • Cookies Settings
"Unity", Unity logos, and other Unity trademarks are trademarks or registered trademarks of Unity Technologies or its affiliates in the U.S. and elsewhere (more info here). Other names or brands are trademarks of their respective owners.
  • Anonymous
  • Sign in
  • Create
  • Ask a question
  • Spaces
  • Default
  • Help Room
  • META
  • Moderators
  • Explore
  • Topics
  • Questions
  • Users
  • Badges