Scale select sprite without anti-aliasing


My game uses anti-aliasing for most sprites. To save atlas space (and file size) I’d like to stretch a square sprite larger, and retain pixel sharpness on just that one sprite. Is there a way to achieve pixel sharpness (anti-aliasing turned off) on a specific sprite?

This is the (predictable) result currently:



Technically yes but you’re either going to get an extra draw call or an extra atlas / material.

What are you stretching? You can use GUI 9patch for repeating things like this too.


I have a rectangular area I’d like to fill with a solid colour inside my game world. Maybe I’ll have to go down the route of using a tilemap instead?


Could this be an option, or is it likely to be too slow? All I want to do is to create a filled rectangle.


You can draw to a buffer once and then keep it static. You don’t have to do it every frame so it’s fine.


Set texture sampling mode to “nearest” instead of “linear” and disable mipmaps for that particular atlas?


Good idea! Could be an option if the TileMap (that I’m using currently) turns out to be too heavy.