39#include "ramCanvas.hpp"
42typedef mjr::ramCanvas3c8b::colorType ct;
46 std::chrono::time_point<std::chrono::system_clock> startTime = std::chrono::system_clock::now();
47 const int IMGSIZ = 7680/4;
48 const int MAXITR = 1024;
49 const double MAXZSQ = 4.0;
50 mjr::ramCanvas3c8b theRamCanvas(IMGSIZ, IMGSIZ, -2.2, 0.8, -1.5, 1.5);
52#pragma omp parallel for schedule(static,1)
53 for(
int y=0;y<theRamCanvas.getNumPixY();y++) {
54 for(
int x=0;x<theRamCanvas.getNumPixX();x++) {
55 std::complex<double> c = theRamCanvas.int2real(x, y);
56 std::complex<double> z(0.0, 0.0);
59 while((std::norm(z)<MAXZSQ) && (count<=MAXITR)) {
62 if (std::norm(z) < minAbs)
63 minAbs = std::norm(z);
66 theRamCanvas.drawPoint(x, y,
decltype(theRamCanvas)::colorType::csCColdeFireRamp::c(
static_cast<decltype(theRamCanvas)::csIntType
>(count*30)));
68 theRamCanvas.drawPoint(x, y,
decltype(theRamCanvas)::colorType::csCCwicC::c(
static_cast<decltype(theRamCanvas)::csFltType
>(minAbs*50)));
71 theRamCanvas.writeTIFFfile(
"mandelbrot_minOrbit.tiff");
72 std::chrono::duration<double> runTime = std::chrono::system_clock::now() - startTime;
73 std::cout <<
"Total Runtime " << runTime.count() <<
" sec" << std::endl;
int main(int argc, char *argv[])