• 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 georgeq · Jul 21, 2015 at 01:29 AM · 2dtexturemeshsprite

Texture type -> Advanced -> Mesh type: how it works?

I'm optimizing a 2D platformer game with a paralax scroll, I already optimized the scene, physics and scripts. On the PC it now runs close to 1000FPS, however on my Android phone I have trouble to keep the frame rate near 60FPS.

Because of the paralax scrolling, there's a lot of overdrawing (since I have 7 layers)... Accoring to what I've read so far, the main problem is that the alpha channel that makes parts of the sprite's rectangle transparent have to be rendered anyway, so in my case there is a lot of pixels that are overwriten up to 6 times. What they say is that the best way to avoid this is to replace the sprite with a mesh, that way you can cut away all the alpha stuff and grately reduce overdrawing...

I've also read from people that seem to be doing this on Unity 5 by setting the Texture type to Advanced and then Mesh type to Tight... and supposedly Unity will create a mesh from the sprite for you, but no clear example is given.

I already tried this but nothing seems to happen, if I replace the sprite render with a mesh filter I expect to see the newly created mesh on the "Select Mesh" window, but I just can see the standard mesh filters... so can anyone explain to me how this works???

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
Best Answer

Answer by Eric5h5 · Jul 21, 2015 at 02:33 AM

You don't replace the sprite renderer with anything, and you don't do anything other than set the mesh type to tight. That's it. There's no access to sprite meshes and nothing you have to do. The engine handles it for you. You can see the difference if you use shaded wireframe as the scene view rendering mode.

Comment
Add comment · Show 2 · 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 georgeq · Jul 21, 2015 at 02:50 AM 0
Share

Thanks, it was not very clear. Perfomance improved, but not as much as I expected.

avatar image yamagema · Oct 12, 2015 at 01:00 PM 0
Share

Said something wrong, sorry about that (Deleted the post to avoid confusion).

It indeed works fine, and can be seen with wireframe display turned on (Assu$$anonymous$$g you do use "Sprite Renderer" component).

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

If you’re new to Unity Answers, please check our User Guide to help you navigate through our website and refer to our FAQ for more information.

Before posting, make sure to check out our Knowledge Base for commonly asked Unity questions.

Check our Moderator Guidelines if you’re a new moderator and want to work together in an effort to improve Unity Answers and support our users.

Follow this Question

Answers Answers and Comments

25 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 avatar image avatar image avatar image avatar image avatar image avatar image avatar image

Related Questions

Anti aliasing with sprites 0 Answers

Sprite rendering texture as one solid color 1 Answer

sprite vs texture 1 Answer

How to make 3D colliders on sprites? 0 Answers

I want do my own mesh "quad", but not square, I want a 2D polygon to apply in a parallax scroll 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