From 6cc5e48c1e3b9ee9dd4437ff23459df562e82df7 Mon Sep 17 00:00:00 2001 From: Cosmin Apreutesei Date: Fri, 5 Feb 2016 11:50:55 +0200 Subject: [PATCH] update to affine2d changes of degress -> radians --- path2d_editor_demo.lua | 2 +- path2d_svgarc_demo.lua | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/path2d_editor_demo.lua b/path2d_editor_demo.lua index 6c02d7d..c31c040 100644 --- a/path2d_editor_demo.lua +++ b/path2d_editor_demo.lua @@ -155,7 +155,7 @@ local path = { 'rel_text', 0, 0, {size=70}, 'mittens', } -local mt = affine2d()--:translate(100, 0):rotate(10):scale(1, .7) +local mt = affine2d()--:translate(100, 0):rotate(math.rad(10)):scale(1, .7) local invmt = mt:inverse() local points, update = path_editor.control_points(path, mt) diff --git a/path2d_svgarc_demo.lua b/path2d_svgarc_demo.lua index b615c10..6a33a2c 100644 --- a/path2d_svgarc_demo.lua +++ b/path2d_svgarc_demo.lua @@ -39,7 +39,7 @@ function player:on_render(cr) end local world_center_x, world_center_y = 600, 300 - local mt = matrix():rotate_around(world_center_x, world_center_y, world_rotation) + local mt = matrix():rotate_around(world_center_x, world_center_y, math.rad(world_rotation)) local function draw(x1, y1, rx, ry, rotation, large, sweep, x2, y2, r, g, b, a) if not svgarc.valid(x1, y1, x2, y2, rx, ry) then return end