38#include "ramCanvas.hpp"
41typedef mjr::ramCanvas3c8b::colorType ct;
45 std::chrono::time_point<std::chrono::system_clock> startTime = std::chrono::system_clock::now();
46 const int WIDTH = 1920/2;
47 const int HEIGHT = 1920/2;
48 const int NUMITR = 500;
49 const double MAXZ = 4.0;
51 const int NUMFRM = 24*2;
52 const double ANGMIN = 0.0;
53 const double ANGMAX = std::numbers::pi*2;
54 const double RADIUS = 0.0001;
56# pragma omp parallel for schedule(static,1)
57 for(
int frame=0; frame<NUMFRM; frame++) {
59 std::cout <<
"Frame: " << frame << std::endl;
60 double angle = frame*(ANGMAX-ANGMIN)/NUMFRM+ANGMIN;
62 const std::complex<double> c(0.566700, 0.00000);
63 const std::complex<double> p(-0.50000+RADIUS*std::cos(angle), 0.00000);
64 mjr::ramCanvas3c8b theRamCanvas(WIDTH, HEIGHT, -0.75, -0.5, 0.13, 0.32);
66 for(
int y=0;y<theRamCanvas.getNumPixY();y++) {
67 for(
int x=0;x<theRamCanvas.getNumPixX();x++) {
68 std::complex<double> z1(theRamCanvas.int2realY(y), theRamCanvas.int2realX(x));
69 std::complex<double> z2(0.0, 0.0);
71 while((std::norm(z1)<MAXZ) && (count<=NUMITR)) {
72 std::complex<double> z = z1*z1+c+p*z2;
78 theRamCanvas.drawPoint(x, y, ct::csCCfractal0RYBCW::c(
static_cast<ct::csIntType
>(count*10)));
81 theRamCanvas.writeTIFFfile(
"phoenixM_" + mjr::math::str::fmt_int(frame, 2,
'0') +
".tiff");
83 std::cout <<
"FRAME(" << frame <<
"): " <<
"DONE" << std::endl;
86 std::chrono::duration<double> runTime = std::chrono::system_clock::now() - startTime;
87 std::cout <<
"Total Runtime " << runTime.count() <<
" sec" << std::endl;
int main(int argc, char *argv[])