40#include "ramCanvas.hpp"
43typedef mjr::ramCanvas3c8b::colorType ct;
47 std::chrono::time_point<std::chrono::system_clock> startTime = std::chrono::system_clock::now();
48 const int NUMITR = 1024;
49 const double MAXZ = 4.0;
50 const int NUMFRM = 24*16;
51 const int IMXSIZ = 7680/8;
52 const int IMYSIZ = 7680/8;
53 const double ANGMIN = 0.0;
54 const double ANGMAX = std::numbers::pi*2;
56 for(
int frame=0; frame<NUMFRM; frame++) {
57 mjr::ramCanvas3c8b theRamCanvas(IMXSIZ, IMYSIZ, -2.2, 2.2, -2.2, 2.2);
58 std::cout <<
"Frame: " << frame << std::endl;
59 double angle = frame*(ANGMAX-ANGMIN)/NUMFRM+ANGMIN;
60 std::complex<double> c = std::complex<double>(std::cos(angle), std::sin(angle)) * 0.35 - std::complex<double>(0.0, -1.0);
61 for(
int y=0;y<theRamCanvas.getNumPixY();y++) {
62 for(
int x=0;x<theRamCanvas.getNumPixX();x++) {
63 std::complex<double> z = theRamCanvas.int2real(x, y);
65 while((std::norm(z)<MAXZ) && (count<=NUMITR)) {
70 theRamCanvas.drawPoint(x, y, ct::csCColdeFireRamp::c(
static_cast<ct::csIntType
>(count*20)));
73 theRamCanvas.writeTIFFfile(
"juliaM_" + mjr::math::str::fmt_int(frame, 3,
'0') +
".tiff");
75 std::chrono::duration<double> runTime = std::chrono::system_clock::now() - startTime;
76 std::cout <<
"Total Runtime " << runTime.count() <<
" sec" << std::endl;
int main(int argc, char *argv[])