Wayback Machinekoobas.hobune.stream
May JUN Jul
Previous capture 13 Next capture
2021 2022 2023
1 capture
13 Jun 22 - 13 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 /
avatar image
1
Question by keinabel · Jul 01, 2013 at 10:48 AM · meshfpsperformancemodelcombine

Combine Objects/Meshes to reduce drawCalls

Hi there,

We recently added tons of new models to our game. The result are FPS drops down to 5-10. I guess the combination of lots of models, each consisting of tons of models/meshes themselves, causes this drops

Is there a way to combine them, so that there are fewer drawCalls?

Edit: Here is an Example of one of the new Objects. It obviously consists of too much objects itself. How can I combine them?

alt text

thank you

unbenannt.jpg (74.6 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 amphoterik · Jul 01, 2013 at 01:30 PM 1
Share

do they all need to be rendered at all times?

avatar image keinabel · Jul 01, 2013 at 02:07 PM 0
Share

let's say it like that. all these new models belong to one "unit". This unit does not have to be rendered all the time. But the moment it becomes visible, most of its components are visible, too.

2 Replies

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

Answer by TonyLi · Jul 01, 2013 at 02:21 PM

You can combine meshes: Mesh.CombineMeshes().

Or use a tool like Mesh Baker (or write your own) to combine meshes and make textures atlases if your models use multiple textures or materials. Lots of materials for a single model can really kill your framerate.

There are other good tips on the Modeling Characters for Optimal Performance page.

First be sure that there aren't any real problems, such as a script hanging up on a missing bone in your model or something like that.

Comment
Add comment · Show 4 · 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 keinabel · Jul 01, 2013 at 03:23 PM 0
Share

first of all, thank you. But can I simply combine different meshes? I always thought I can only combine similar meshes.

avatar image TonyLi · Jul 01, 2013 at 03:49 PM 1
Share

There are some restrictions -- for example, meshes that move relative to one another can't be combined. But in those cases you can do a lot to improve dynamic draw call batching, as described in the Draw Call Batching page. Since these are moving characters, you should focus on dynamic batching like @Em3rgency suggested, rather than static batching. Also, for dynamic batching:

  • Combine materials using texture atlases

  • Under 900 vertices (see the page)

  • No multipass shaders or realtime shadows on your characters

If your characters can't meet the requirements above, the Shadowgun presentation on optimizing for mobile has more good tips even if you're not targeting mobile specifically: http://blogs.unity3d.com/2012/03/23/shadowgun-optimizing-for-mobile-sample-level/

avatar image keinabel · Jul 03, 2013 at 12:48 PM 0
Share

static batching helped me to improve the performance from ~7 to 14fps. But when you look at my recently uploaded screenshot, you will see there are lots of objects. how do I combine them? Because I don't know which I can actually combine and which not.

avatar image TonyLi · Jul 03, 2013 at 01:15 PM 0
Share

In that case, are you using a texture atlas and one material? (Or maybe two, if you need a separate material for transparent windshields.)

How much are lights impacting your frame rate? Lights and shadows can really do a number on it. Lightmap, use light probes, and consider changing from dynamic shadows to something simpler but faster.

avatar image
-1

Answer by Em3rgency · Jul 01, 2013 at 11:33 AM

http://docs.unity3d.com/Documentation/Manual/DrawCallBatching.html

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 keinabel · Jul 01, 2013 at 12:34 PM 0
Share

the problem is, that the batching works for objects that are alike. this is not the case for most of the objects.

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

18 People are following this question.

avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image

Related Questions

FPS character, full body or just arms? 2 Answers

Android performance problem on model joints(Rig). 1 Answer

Many meshes with different color performance 1 Answer

What's the best way to optimise thousands of instances of the same mesh? 2 Answers

Occlusion culling and mesh combining possible and working? 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