34#include "ramCanvas.hpp"
37double ranges[6][4] = { { -2.700, 2.100, -2.100, 2.100 },
38 { -2.100, -1.700, -0.300, 0.300 },
39 { -1.540, -1.330, -0.175, 0.175 },
40 { 0.250, 0.700, -1.000, 1.000 },
41 { 0.250, 0.600, 0.700, 1.000 },
42 { -0.720, -0.695, 0.385, 0.410 } };
45typedef mjr::ramCanvas3c8b::colorType ct;
46typedef ct::csIntType cit;
50 std::chrono::time_point<std::chrono::system_clock> startTime = std::chrono::system_clock::now();
51 const int NUMITR = 2000;
52 const int CSIZE = 3840;
55 mjr::ramCanvas3c8b::coordFltType a, b, zx, zy;
56 mjr::ramCanvas3c8b theRamCanvas(CSIZE, CSIZE);
57 for(
int i=0; i<6; i++) {
58 theRamCanvas.newRealCoords(ranges[i][0], ranges[i][1], ranges[i][2], ranges[i][3]);
59 theRamCanvas.clrCanvasToBlack();
60 for(
int y=0;y<theRamCanvas.getNumPixY();y++) {
62 std::cout <<
" CASE: " << i <<
" LINE: " << y <<
"/" << CSIZE << std::endl;
63 for(
int x=0;x<theRamCanvas.getNumPixX();x++) {
64 for(a=theRamCanvas.int2realX(x),b=theRamCanvas.int2realY(y),zx=zy=0.0,count=0;
65 (zx*zx+zy*zy<100000)&&(count<=NUMITR);
66 count++,zx=zx*zx-zy*zy+a,zy=2*zx*zy+b) ;
68 theRamCanvas.drawPoint(x, y, ct::csCColdeFireRamp::c(mjr::math::ivl::wrapCC(
static_cast<cit
>(count*20), 767)));
71 theRamCanvas.writeTIFFfile(
"tippets" + std::to_string(i) +
".tiff");
73 std::chrono::duration<double> runTime = std::chrono::system_clock::now() - startTime;
74 std::cout <<
"Total Runtime " << runTime.count() <<
" sec" << std::endl;
int main(int argc, char *argv[])