Hey everyone, I’m working on a small canvas platformer and trying to keep the pixel art crisp while the camera follows the player, but as soon as movement gets smooth the tiles and sprites start looking blurry and kind of shimmer between frames.
Should I be rounding camera positions, rounding sprite positions, or handling the scale differently if I want smooth motion without the pixel-art jitter?
@BayMax yup, the blur is from drawing at fractional positions. imageSmoothingEnabled = false only disables filtering — it does not stop cameraX from landing on half pixels.
Keep the smooth camera math, but snap the final draw coords:
Yeah, DPR can definitely do it too. If the canvas CSS size and its backing resolution do not match, the browser resamples the image and pixel art goes soft, especially once the camera starts moving.