From 59a987f7e62f9b0270c2ba83383a75eb77d77fe8 Mon Sep 17 00:00:00 2001 From: Fabian Schlenz Date: Wed, 5 Jun 2019 06:28:36 +0200 Subject: [PATCH] FireEffect does look a bit better, but still not right. --- src/effect_fire.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/effect_fire.cpp b/src/effect_fire.cpp index d58f382..8ff840f 100644 --- a/src/effect_fire.cpp +++ b/src/effect_fire.cpp @@ -38,11 +38,11 @@ void FireEffect::propagate() { int index = y*LED_WIDTH + x; uint8_t below_index = (y-1)*LED_WIDTH + x; if (x==0) { - this->data[index] = scale8(this->data[below_index], 170) + scale8(this->data[below_index+1], 85); + this->data[index] = scale8(this->data[below_index], 128) + scale8(this->data[below_index+1], 64); } else if (x==LED_WIDTH-1) { - this->data[index] = scale8(this->data[below_index], 170) + scale8(this->data[below_index-1], 85); + this->data[index] = scale8(this->data[below_index], 128) + scale8(this->data[below_index-1], 64); } else { - this->data[index] = scale8(this->data[below_index], 128) + scale8(this->data[below_index-1], 64) + scale8(this->data[below_index+1], 64); + this->data[index] = scale8(this->data[below_index], 128) + scale8(this->data[below_index-1], 32) + scale8(this->data[below_index+1], 32); } } }