• 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
2
Question by dibonaj · Jul 19, 2011 at 07:38 PM · renderingperformanceoptimizationbatchingdrawcalls

Drawcalls or Batched, which is more important to performace?

Hello once again everyone. Busy day for me here on Unity Answers. Anyway, I have a question about performance. I have been running my game with the statistics window open and I noticed that is has a draw calls field and a batched field. Both of my numbers are high and could and should be lowered, but my question is when it comes to performance, which one should I pay more attention to? The draw calls or the batched field? And if it is batched, how do I go about lowering it?

Just for reference:

At the fastest part of my game I have 151 draw calls and 14 batched At the slowest part of my game I have ~4000 draw calls and ~9000 batched

This certainly leads me to believe that batched is the number I want to pay attention to, as even in the slow parts my FPS rises as my batched decreases.

Comment
Add comment
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

1 Reply

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

Answer by Peter G · Jul 19, 2011 at 07:47 PM

Batched is a good thing. Batched is the number of objects that Unity combined into a single draw call. The higher that number, the more draw calls you are saving. The reason you are getting a slower frame rate is because 4000 draw calls is rather high. You want a lower draw calls and to raise the batching.

Comment
Add comment · Show 11 · 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 dibonaj · Jul 19, 2011 at 07:50 PM 0
Share

I'm still looking around for the best way to do that. I was reading up on batching and was wondering if since none of my objects in the game move, aside from the main camera, would it be beneficial to me to check the static box on them all?

avatar image dibonaj · Jul 19, 2011 at 08:29 PM 0
Share

Every "How do I reduce draw calls" thread I have found talks about combining meshes, but it seems Unity already does that now. So if that is the case, where is a good place to go to learn more ways to reduce draw calls or simply increase performance?

avatar image SisterKy · Jul 19, 2011 at 09:15 PM 0
Share

I'd be interested in that, too. but please open a new question for this. Greetz, $$anonymous$$y.

avatar image Peter G · Jul 20, 2011 at 01:53 AM 1
Share

If an object doesn't move then ALWAYS mark it static. Static batching is more efficient that dynamic batching.

  • Static batching occurs with all static objects that share the same material. Unity creates vertex array for all of them and they get drawn with one call.

  • Dynamic batching occurs with objects under 300 verts and they are batched together every frame. So it isn't nearly as beneficial as the static version, but it is still faster than adding an extra draw call.

The only other real good way to reduce the number of objects the camera has to draw. This can be done through creating fewer objects or by using Occlusion Culling. A well designed scene blocks out other parts of the scene. This lets you not draw the parts further back.

avatar image SisterKy · Jul 20, 2011 at 11:52 AM 0
Share

Wait a moment... I know how to mark a variable or a function as static... but how do I mark an Object as static? Greetz, $$anonymous$$y.

Show more comments

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.

Welcome to Unity Answers

The best place to ask and answer questions about development with Unity.

To help users navigate the site we have posted a site navigation guide.

If you are a new user to Unity Answers, check out our FAQ for more information.

Make sure to check out our Knowledge Base for commonly asked Unity questions.

If you are a moderator, see our Moderator Guidelines page.

We are making improvements to UA, see the list of changes.



Follow this Question

Answers Answers and Comments

7 People are following this question.

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

Related Questions

Is there any way I can statically batch procedurally generated objects? 0 Answers

,Drawing 100 000+ cubes 1 Answer

Why did my render time increase after lowering the vertex count? 2 Answers

Where do I find static batching statistics? 1 Answer

[Closed] Manually Batching GUI Texture Objects? 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