From 14ffdc41513adc11c56189f823cb00437e200668 Mon Sep 17 00:00:00 2001 From: Noel Berry Date: Thu, 27 Aug 2020 20:23:26 -0700 Subject: [PATCH] small readme cleanup --- README.md | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index 16bcaa2..d0edb23 100644 --- a/README.md +++ b/README.md @@ -28,7 +28,11 @@ void render() { Graphics::clear(Graphics::backbuffer, 0x00000000); - batch.push_matrix(Mat3x2::create_transform(Vec2(App::draw_width(), App::draw_height()) / 2, Vec2::zero, Vec2::one, Time::elapsed * Calc::TAU)); + Vec2 center = Vec2(App::draw_width(), App::draw_height()) / 2; + float rotation = Time::elapsed * Calc::TAU; + Mat3x2 transform = Mat3x2::create_transform(center, Vec2::zero, Vec2::one, rotation); + + batch.push_matrix(transform); batch.rect(Rect(-32, -32, 64, 64), 0xff0000); batch.pop_matrix();