Search Unity

Question Squares do not render perfectly square

Discussion in '2D' started by JorritWegman, Jan 1, 2023.

  1. JorritWegman

    JorritWegman

    Joined:
    Jan 6, 2020
    Posts:
    2
    First of all: Happy new year! May you make fantastic games!

    I'm sorry if this is a stupid question. I started learning Unity yesterday. I have googled a lot, but could not find the answer to my problem.



    I am trying to render the default square sprite at scale 1,1,1. As you can see all the squares have different sizes and non of them are actually square, even though they all have the same scale. How can I solve this?

    This is my main camera:


    Kind Regards
     
  2. JorritWegman

    JorritWegman

    Joined:
    Jan 6, 2020
    Posts:
    2
    Hi, I still have not found a solution to this problem.
     
  3. karliss_coldwild

    karliss_coldwild

    Joined:
    Oct 1, 2020
    Posts:
    602
    You have zoomed in quite a bit. If you weren't zoomed in the difference would be only one pixel. There isn't much computer can do if you haven't done the math carefully and ask to draw something at size/position which doesn't precisely align to pixels. Getting good pixel perfect results requires some effort. Unity has tools to help with that they can't do everything.

    Another thing to consider is whether your art style actually requires pixel perfect results. Can't tell what style you are going for since there isn't much in the screenshot. For non pixel perfect style, there are different techniques to make stuff like this less abvious.