private void evaluateCell()

in functions/CDDSenseHatJava/src/main/java/com/amazonaws/greengrass/cddsensehat/leds/animation/Fire.java [118:126]


    private void evaluateCell(SenseHatLED[][] temp, int y, int x) {
        int count = ((senseHatLEDs[y][x - 1] == red) ? 1 : 0) +
                ((senseHatLEDs[y][x + 1] == red) ? 1 : 0) +
                ((senseHatLEDs[y + 1][x - 1] == red) ? 1 : 0) +
                ((senseHatLEDs[y + 1][x] == red) ? 1 : 0) +
                ((senseHatLEDs[y + 1][x + 1] == red) ? 1 : 0);

        setIfCountHighEnough(temp, x, y, count);
    }