34#include "ramCanvas.hpp"
37typedef mjr::ramCanvas3c8b::colorType ct;
41 std::chrono::time_point<std::chrono::system_clock> startTime = std::chrono::system_clock::now();
42 const int IMGSIZ = 7680;
43 const int MAXITR = 1024;
44 const double MAXZSQ = 1008.0;
45 mjr::ramCanvas3c8b theRamCanvas(IMGSIZ, IMGSIZ, -2.2, 0.8, -1.5, 1.5);
47# pragma omp parallel for schedule(static,1)
48 for(
int y=0;y<theRamCanvas.getNumPixY();y++) {
49 for(
int x=0;x<theRamCanvas.getNumPixX();x++) {
50 std::complex<double> c = theRamCanvas.int2real(x, y);
51 std::complex<double> z(0.0, 0.0);
52 double minX = theRamCanvas.getCanvasWidD();
53 double minY = theRamCanvas.getCanvasWidD();
55 while((std::norm(z)<MAXZSQ) && (count<=MAXITR)) {
57 if (std::abs(std::real(z)) < minX)
58 minX = std::abs(std::real(z));
59 if (std::abs(std::imag(z)) < minY)
60 minY = std::abs(std::imag(z));
64 theRamCanvas.drawPoint(x, y, ct::csCCfractalYB::c(
static_cast<ct::csIntType
>(std::log(1+std::min(minX, minY))*500)));
67 theRamCanvas.writeTIFFfile(
"mandelbrot_pickover.tiff");
68 std::chrono::duration<double> runTime = std::chrono::system_clock::now() - startTime;
69 std::cout <<
"Total Runtime " << runTime.count() <<
" sec" << std::endl;
int main(int argc, char *argv[])