Timeline for How to prevent blurry pixel art when the camera is following a character?
Current License: CC BY-SA 4.0
11 events
when toggle format | what | by | license | comment | |
---|---|---|---|---|---|
Sep 11, 2021 at 21:01 | history | bounty ended | Ryan Peschel | ||
Sep 11, 2021 at 21:01 | comment | added | Ryan Peschel | This didn't answer my question but the bounty is about to expire anyway so I'll just give it to you for trying | |
Sep 6, 2021 at 0:28 | comment | added | Ryan Peschel |
Thanks for the updated answer. I'm still not sure how to solve the problem though. And are you sure your edit is the problem? Because even when I set the followSharpness to a very low value such that the camera is very far behind the player, I still get the blurriness. So it's not like the blurriness is only occurring when the camera's position is very close to the player.
|
|
Sep 5, 2021 at 23:29 | history | edited | liggiorgio | CC BY-SA 4.0 |
added 160 characters in body
|
Sep 5, 2021 at 23:20 | comment | added | liggiorgio | I updated my answer with some additional considerations about this issue and the new information you provided. | |
Sep 5, 2021 at 23:17 | history | edited | liggiorgio | CC BY-SA 4.0 |
Expanded the answer with additional considerations
|
Sep 5, 2021 at 22:55 | comment | added | Ryan Peschel | Here's an image of the logs when using your lerping function and moving the player character left and right: i.imgur.com/T16ktuF.png The logs for the other case when I just assign the camera position to the player position are uninteresting because in that case both values are always identical. | |
Sep 5, 2021 at 22:51 | comment | added | liggiorgio | What about logging camera position over time too? Blurry visuals may imply different values between camera and player position, which can be verified with logs. | |
Sep 5, 2021 at 22:38 | comment | added | Ryan Peschel |
Also, I'm pretty sure (not entirely though) that floating-point locations are fine, because my default camera (this.x = player.x; this.y = player.y; ) works perfectly (no blur) and I'm console logging the player positions with that and they're all floating point.
|
|
Sep 5, 2021 at 22:28 | comment | added | Ryan Peschel |
Thanks for the attempt, but there's still the same blur issue even after replacing the old lerp function with this new one you provided. Any other ideas?
|
|
Sep 5, 2021 at 22:00 | history | answered | liggiorgio | CC BY-SA 4.0 |