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
2
Question by KiprasNav · Feb 24, 2014 at 05:24 PM · 2dspriterenderingspriterenderer

Very weird pixel displacement with point filter mode

I'm making a 2D game and getting the camera to render sharp pixel art is really hard. I can't use bilinear filter mode because everything gets blurry, but when I use point filter mode some parts of the image are displayed incorrectly.

The edges look strange

The edges in the middle, the edges in the bottoms, the edges on the hammer are all looking very weird. The image itself is prefectly sharp. The hammer is basically a brown rectangle conencted to a gray rectangle.

Also, I have set max texture size to the size of the spritesheet, format to truecolor, camera size to screenHeight / pixelsPerUnit / 2. I have no idea how to fix this.

EDIT: Another image. The top one is how it renders, the bottom one is how it should look.

alt text

This is another map. I've scaled it up so it would be possible to see the flaws clearly. So the edges of the roads blends, the hammer gets some new pixels, and there's one line between the green and the black, a thin blue line - that's the camera's background (clear). Is Unity even capable of producing pixel sharp results? Because I feel that Unity might only truly work in perspective mode. Or maybe that's just my project that's messing up completely.

notworking2.png (112.9 kB)
notworking.png (45.9 kB)
Comment
Add comment · Show 1
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 Owen-Reynolds · Feb 24, 2014 at 09:14 PM 0
Share

Those little glitches look like standard "Point filtering" artifacts. I've seen the same thing plenty in non-Unity images. Always happens when actual screen pixels and image pixels don't match correctly.

I'd guess, if you go through and "measure" everything, that there's a math mistake -- the hammer plane really is too big, etc... .

2 Replies

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

Answer by KiprasNav · Feb 25, 2014 at 01:50 PM

Since somebody might experience a similar problem I thought I should tell how I fixed it. Create a new material with the shader sprites/default, then enable pixel snap.

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

Answer by zee_ola05 · Feb 24, 2014 at 06:32 PM

At the import setting, instead of Compressed, use 16bits format. If that doesn't work, use Truecolor.

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 KiprasNav · Feb 24, 2014 at 07:08 PM 0
Share

I already tried that. Also, the little orange square in the center of the screen has a border going around the whole sprite, while in the picture you can only see borders on three sides.

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

21 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

Related Questions

2D Sprite Graphics Glitching, Skewing, Flickering, Crazy, Haywire 1 Answer

SpriteRenderer change order in layer in edit mod via script 1 Answer

renderer.enabled doesn't work but coloring does 1 Answer

Sprite Flipping on Camera Move - 2D 0 Answers

Can't create a 2D sprite with Sprite.Create when creating texture in code 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