fix warnings

This commit is contained in:
Marc Planard 2023-06-10 17:08:08 +02:00
parent 256599095f
commit 81de6728fc
2 changed files with 3 additions and 3 deletions

View File

@ -73,7 +73,7 @@ fn run_all() -> LJResult<()> {
let frame = get_next_frame(&config, &transformers,
&mut rs, order == Order::Black)?;
// For now, draw all the time
tracer.draw(frame, 10_000)?;
tracer.draw(frame, 40_000)?;
}
info!("Exiting, stoping device.");

View File

@ -23,8 +23,8 @@ impl Transformers for Rotate {
fn apply(&self, point_list: &[Point]) -> Vec<Point> {
point_list.iter()
.map(| pt | {
let dx = (pt.x - self.cx);
let dy = (pt.y - self.cy);
let dx = pt.x - self.cx;
let dy = pt.y - self.cy;
let cos = self.angle.cos();
let sin = self.angle.sin();
let x = (dx * cos - dy * sin) + self.cx;