From c577f2cbd49c2b93c67855310618f72998c0f172 Mon Sep 17 00:00:00 2001 From: David Thompson Date: Sat, 6 Dec 2014 11:17:41 -0500 Subject: render: sprite: Floor anchor coordinates to prevent fuzzy images. * sly/render/sprite.scm (make-sprite): Floor anchor vector. --- sly/render/sprite.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/sly/render/sprite.scm b/sly/render/sprite.scm index ace9373..9bd487a 100644 --- a/sly/render/sprite.scm +++ b/sly/render/sprite.scm @@ -53,8 +53,8 @@ size of the mesh is the size of TEXTURE, in pixels. Optionally, a custom SHADER can be specified." (let* ((anchor (anchor-texture texture anchor)) - (x1 (- (vx anchor))) - (y1 (- (vy anchor))) + (x1 (- (floor (vx anchor)))) + (y1 (- (floor (vy anchor)))) (x2 (+ x1 (texture-width texture))) (y2 (+ y1 (texture-height texture))) (s1 (texture-s1 texture)) -- cgit v1.2.3