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
0
Question by VoidChimera · Feb 07, 2015 at 10:00 AM · renderingdrawcalls

Question about draw calls and sprites

I'm trying to do some optimization for my mobile (Android) game, when I found that for some reason i'm getting absurd amounts of draw calls. I have an setup where objects move around the screen, leaving an trail of 'particle' gameobjects behind them (I prefer the control of the particles being gameobjects, don't judge :P ) Anyway, normally this wasn't an major sticking point, and had no real impact on performance during times like shown below:

alt text

For some reason however, as soon as I added an second particle to the player's shots, nearly every particle from those shots increases the number of draw calls! (If I only enable either player particles or enemy particles, then the number of them has almost no affect on the number of draw calls) alt text

My instinct tells me it's something with the alpha blending and that having to deal with multiple sprites complicates things quite an bit, I could be completely wrong though. Anyone more experienced have insight on what's causing this, or what I can do to prevent it?

Edit: After an bit more research, I'm fairly convinced it's because all of the player particles and all of the enemy particles are batched together, so they're very efficient alone, but adding an second type of particle creates alpha interactions that make the rendering much more complex. Anyone know what I should do about this? (Apart from just less particles, obviously :P)

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
0

Answer by giulio-pierucci · Feb 07, 2015 at 11:05 AM

There are some limit of dynamic batching (do you use it in this case?), but none is about blending.

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

Maybe is possible that you change material properties (i.e. material.color) on instancing? On runtime, renderer materials are linked to a single material or a material instance?

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

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

3 People are following this question.

avatar image avatar image avatar image

Related Questions

Dynamic Batching not working even adhering to all rules 3 Answers

In terms of GPU performance, what's the difference between a model made in Blender and a model made entirely out of Unity game objects? 2 Answers

Single pass outline shader 1 Answer

Fastest way to hide objects during render calls and still have them update 0 Answers

Is it possible to render *with a single draw call*, say, 100 gameObjects, all using the same material but each with a different texture ? 1 Answer


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