textures – Unity – How to keep the sprites sharp and precise, even in rotation

None of the things I've tried produces a perfect pixel without rotation block, while allowing rotation without aliasing

Click here for the sample project, which also contains additional images.


Ideally, here is what it would look like

From Photoshop, not Unity.

  • Edges without defects, smooth corners and very small folding during rotation.

enter the description of the image here

Screenshot of the Github project:

Screen capture

Row 1

Without rotation: Perfect edges, pixelated corners

Turned: Pixelised everywhere


Row 2

Without rotation: Perfect edges, smooth corners.

Turned: Pixelated edges, smooth corners


Row 3

Without rotation: Blur everywhere.

Turned: Blur everywhere


Row 4

Without rotation: Not completely perfect edges, pixelated corners

Turned: Blur everywhere


Row 5 (MY BEST SOLUTION TO DATE)

Without rotation: Semi-blur everywhere.

Turned: Semi-blur everywhere


Texture for "borderless" texture:

No padding

Texture for "with padding" texture:

Padding


(Note: I am a total beginner shader)

I've created a fragment shader to draw the block.

It has AA (via smoothstep) built in, and strangles it while the block is rotated (so that there is no AA when it is not turned)

This has some problems:

  1. A shader (geometry) does not seem at all the correct solution to this problem, since I should do a shader for all the geometry that has this problem.

    • But maybe there is a shader that can apply AA to a texturedoes not do anything for vertical or horizontal edges (not rotated)?
  2. The corners of the block with disabled AA are pixelated

    • This does not seem too difficult to solve
    • I would probably want it to work the same way in row 2 (without rotation)
  3. You do not know how much AA to apply (when rotated) so that it is as clean as possible for a given DPI.

    • I thought that was why mip cards were useful because you had to choose the highest res texture. (Another reason why a texture-based solution seems better)

MSAA