pixled-lib  1.0
pixled/animation/linear_unit_wave.cpp

A pixled::animation::LinearUnitWave usage example.

basic_linear_unit_wave.gif rainbow_linear_unit_wave.gif

Unit Wave"

Unit Wave"

Unit Wave"

Unit Wave"

#include "pixled.h"
#include "pixled/gif_output.h"
// Required for the * operator to work
using namespace pixled;
int main(int argc, char** argv) {
pixled::LedPanel panel(16, 16, pixled::LEFT_RIGHT_RIGHT_LEFT_FROM_BOTTOM);
pixled::GifOutput out(256, pixled::FIT_WIDTH, 20, panel);
{
pixled::rgb wave (
pixled::Cast<uint8_t>(
),
(uint8_t) 0,
(uint8_t) 0
);
pixled::Runtime runtime(panel, out, wave);
// Writes 20 frames to gif file
out.write(runtime, 20, "basic_linear_unit_wave.gif");
}
{
pixled::hsb wave (
1.0,
);
pixled::Runtime runtime(panel, out, wave);
// Writes 20 frames to gif file
out.write(runtime, 20, "rainbow_linear_unit_wave.gif");
}
}
Definition: runtime.h:28
Definition: animation.h:50
Definition: animation.h:88
Definition: chroma.h:25
Definition: chroma.h:46
Definition: geometry.h:163
Definition: mapping.h:150
Definition: animation.cpp:3