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 dansav · Feb 24, 2013 at 11:03 PM · importpngedgesjagged

Jagged Edges Around Imported png Texture on Cube Game Object

I'm making a button using a cube that I put a png picture on. I parent the cube to the camera, and have it about a distance of 1 in the z direction from the camera. However, the image appears to have jagged lines around the edges. I've set the import settings to Format "Truecolor" and the Wrap Mode to "Clamp," as has been recommended by people on the forum. I'm still experiencing the poor image quality problem though, even after experimenting with different sizes ranging from 64x64 to 200x200

The image that I'm using was made in illustrator using the "Save for Web and Devices" option. The graphic seems to have the jagged edge problem in unity whether I keep a stroke of 1 on it or not. The format is a png.

This pic is a screenshot from illustrator:

alt text

This is what it looks like in unity:

alt text

jumprightlarge.png (2.0 kB)
screen shot 2013-02-24 at 2.58.04 pm.png (10.9 kB)
Comment
Add comment · Show 9
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 robertbu · Feb 24, 2013 at 11:40 PM 0
Share

Does it look "right" in Photoshop? What Import settings are you using for the texture in Unity?

avatar image asafsitner · Feb 24, 2013 at 11:49 PM 0
Share

You might want to play around with different filter modes. I had a similar issue that was solved by switching from point to bilinear filtering.

As a side note:
You want to keep all your textures at power of 2 resolution.

avatar image dansav · Feb 25, 2013 at 01:10 AM 0
Share

It seems to look "right" in Photoshop. The import settings are: Texture Type: "Texture" Wrap $$anonymous$$ode: "Clamp" Filer $$anonymous$$ode: "Bilinear" $$anonymous$$ax size: "128" Format: "Truecolor"

Changing the Filter $$anonymous$$ode doesn't seem to help. This texture also is a power of 2 resolution (it's 64x64)

avatar image nsxdavid · Feb 25, 2013 at 02:15 AM 0
Share

Well you are taking a 186x188 image and shrinking to 64x64... so that's both a loss of resolution and some distortion. Then if you render it larger than that in screen-space in unity... fat bits... aka jaggies... results. Increase the resolution of the image, say 128x128 or 256x256 in the source and deep it at that in the export. Then be $$anonymous$$dful of what resolution you render at in the engine.

I noticed after posting this that you say you did your original in illustrator, a vector application. Check what the export is (not a screen shot) to make sure that's looking right before even worrying about Unity.

avatar image dansav · Feb 25, 2013 at 02:56 AM 0
Share

Thanks nsxdavid for bringing to my attention that the actual file is more relevant than the screenshot.

In the post, I just replaced the screenshot with the actual illustrator png export, which is 64x64. So the illustrator png is actually not any larger than the unity cube that it's on.

Any other things that might solve the jagged edge problem, and increase the quality of the image in unity?

Show more comments

0 Replies

· Add your reply
  • Sort: 

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

12 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

Related Questions

Jagged Edges Around imported png on cube game object 1 Answer

Imported png doesn't keep colors 2 Answers

PNG Sprite scaling issues 1 Answer

Texture Import - PNG 8bits ? 1 Answer

Unity 5 crash on asset import with android 3 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