Bug fix to camera_center

This commit is contained in:
Grant Sanderson 2018-11-29 17:29:12 -08:00
parent b1334dd72f
commit 585a4ff864

View file

@ -300,7 +300,7 @@ class Camera(object):
ctx.set_matrix(cairo.Matrix( ctx.set_matrix(cairo.Matrix(
fdiv(pw, fw), 0, fdiv(pw, fw), 0,
0, -fdiv(ph, fh), 0, -fdiv(ph, fh),
(pw / 2) + fc[0] * fdiv(pw, fw), (pw / 2) - fc[0] * fdiv(pw, fw),
(ph / 2) + fc[1] * fdiv(ph, fh), (ph / 2) + fc[1] * fdiv(ph, fh),
)) ))
self.cache_cairo_context(pixel_array, ctx) self.cache_cairo_context(pixel_array, ctx)