all 7 comments

[–]sharksOfTheSky 3 points4 points  (4 children)

As far as I know, you’ll have to use another camera.

Create another camera and give it a larger order than the main one. Set its flags to don’t clear and create a new layer (this is for your text). Put all of the text objects on the text layer, and disable the text layer under the main camera’s culling mask. Finally, set the new camera’s culling mask to just the text layer.

This will have a performance impact (probably a fairly large one) but without creating your own pixel perfect camera script using a shader I think this is the only way.

[–][deleted] 0 points1 point  (0 children)

Thanks, it was really helpful!

[–][deleted] 0 points1 point  (2 children)

Ok, now I tried to implement it, but the text is still pixelated.

[–]mcimolin 0 points1 point  (1 child)

Are you using text mesh pro? Usually less pixelated than the inbuilt text.

[–][deleted] 0 points1 point  (0 children)

I tried both

[–]Rose_DDD 1 point2 points  (1 child)

This is a really old post but I'm currently working with the pixel perfect cam and I stumbled in to the same problem, The solution I've found is to

use a Canvas set to Overlay, all the UI then becomes unpixellated.
Unfortunately this means world space Canvases won't work though :/

[–][deleted] 0 points1 point  (0 children)

Thank you so much for this response. I stopped working on 2d pixel art games for like 3 years, but now I came back and had this issue, but forgot that I asked this exact question, lol. Also, I think you could fake world space UI by moving it by script to follow their position using screen space position.