202 {
204
205
206
207
208 fl::u8 t192 = scale8_video(temperature, 191);
209
210
211
212 fl::u8 heatramp = t192 & 0x3F;
213 heatramp <<= 2;
214
215
216 if (t192 & 0x80) {
217
218 heatcolor.r = 255;
219 heatcolor.g = 255;
220 heatcolor.b = heatramp;
221
222 } else if (t192 & 0x40) {
223
224 heatcolor.r = 255;
225 heatcolor.g = heatramp;
226 heatcolor.b = 0;
227
228 } else {
229
230 heatcolor.r = heatramp;
231 heatcolor.g = 0;
232 heatcolor.b = 0;
233 }
234
235 return heatcolor;
236}
Representation of an 8-bit RGB pixel (Red, Green, Blue)