(Here is a function program of flame. The main idea is to average the color values of the eight points at that time, namely, the upper, lower, left, right, upper, and lower, and then attenuate each frame to move the current pixel up. It is required to prepare a color palette, which is originally a color array, and reserve the flame color from yellow to black to indicate the different colors when the flame rises.
BlazeDemo\.settings\org.eclipse.jdt.core.prefs
BlazeDemo\bin\cn\vaga\blazedemo\BlazeDemo.class
BlazeDemo\bin\cn\vaga\blazedemo\BlazeView$BlazeThread.class
BlazeDemo\bin\cn\vaga\blazedemo\BlazeView.class
BlazeDemo\bin\cn\vaga\blazedemo\R$attr.class
BlazeDemo\bin\cn\vaga\blazedemo\R$drawable.class
BlazeDemo\bin\cn\vaga\blazedemo\R$layout.class
BlazeDemo\bin\cn\vaga\blazedemo\R$string.class
BlazeDemo\bin\cn\vaga\blazedemo\R.class
BlazeDemo\bin\cn\vaga\blazedemo\RandNums.class
BlazeDemo\bin\classes.dex
BlazeDemo\bin\resources.ap_
BlazeDemo\gen\cn\vaga\blazedemo\R.java
BlazeDemo\res\drawable-hdpi\icon.png
BlazeDemo\res\drawable-ldpi\bg.png
BlazeDemo\res\drawable-ldpi\icon.png
BlazeDemo\res\drawable-mdpi\icon.png
BlazeDemo\res\layout\main.xml
BlazeDemo\res\values\strings.xml
BlazeDemo\src\cn\vaga\blazedemo\BlazeDemo.java
BlazeDemo\src\cn\vaga\blazedemo\BlazeView.java
BlazeDemo\src\cn\vaga\blazedemo\RandNums.java
BlazeDemo\.classpath
BlazeDemo\.project
BlazeDemo\AndroidManifest.xml
BlazeDemo\default.properties)