11 {
12 auto *e = ctx.mEngine.get();
13 e->get_ready();
14
15 e->timings.master_speed = 0.02;
16 e->timings.ratio[0] = 0.0025;
17 e->timings.ratio[1] = 0.0027;
18 e->timings.ratio[2] = 0.0031;
19 e->timings.ratio[3] = 0.0033;
20 e->timings.ratio[4] = 0.0036;
21 e->timings.ratio[5] = 0.0039;
22
23 e->calculate_oscillators(e->timings);
24
25 for (
int x = 0;
x < e->num_x;
x++) {
26 for (
int y = 0;
y < e->num_y;
y++) {
27 e->animation.dist = e->distance[
x][
y];
28 e->animation.angle = 5 * e->polar_theta[
x][
y] +
29 5 * e->move.noise_angle[0] +
30 e->animation.dist * 0.1;
31 e->animation.z = 5;
32 e->animation.scale_x = 0.05;
33 e->animation.scale_y = 0.05;
34 e->animation.offset_z = 50 * e->move.linear[0];
35 e->animation.offset_x = 50 * e->move.noise_angle[0];
36 e->animation.offset_y = 50 * e->move.noise_angle[1];
37 float show1 = e->render_value(e->animation);
38
39 e->animation.angle = 6 * e->polar_theta[
x][
y] +
40 5 * e->move.noise_angle[1] +
41 e->animation.dist * 0.15;
42 e->animation.z = 5;
43 e->animation.scale_x = 0.05;
44 e->animation.scale_y = 0.05;
45 e->animation.offset_z = 50 * e->move.linear[1];
46 e->animation.offset_x = 50 * e->move.noise_angle[1];
47 e->animation.offset_y = 50 * e->move.noise_angle[2];
48 float show2 = e->render_value(e->animation);
49
50 e->animation.angle = 5;
51 e->animation.z = 5;
52 e->animation.scale_x = 0.10;
53 e->animation.scale_y = 0.10;
54 e->animation.offset_z = 10 * e->move.linear[2];
55 e->animation.offset_x = 10 * e->move.noise_angle[2];
56 e->animation.offset_y = 10 * e->move.noise_angle[3];
57 float show3 = e->render_value(e->animation);
58
59 e->animation.angle = 15;
60 e->animation.z = 15;
61 e->animation.scale_x = 0.10;
62 e->animation.scale_y = 0.10;
63 e->animation.offset_z = 10 * e->move.linear[3];
64 e->animation.offset_x = 10 * e->move.noise_angle[3];
65 e->animation.offset_y = 10 * e->move.noise_angle[4];
66 float show4 = e->render_value(e->animation);
67
68 e->animation.angle = 2;
69 e->animation.z = 15;
70 e->animation.scale_x = 0.15;
71 e->animation.scale_y = 0.15;
72 e->animation.offset_z = 10 * e->move.linear[4];
73 e->animation.offset_x = 10 * e->move.noise_angle[4];
74 e->animation.offset_y = 10 * e->move.noise_angle[5];
75 float show5 = e->render_value(e->animation);
76
77 e->pixel.red = show1 - show4;
78 e->pixel.green = show2 - show5;
79 e->pixel.blue = show3 - show2 + show1;
80
81 e->pixel = e->rgb_sanity_check(e->pixel);
82 e->setPixelColorInternal(
x,
y, e->pixel);
83 }
84 }
85}