草庐IT

c++ - 在维基百科中使用哪种颜色渐变为曼德布罗着色?

在维基百科的Mandelbrotset页面上有非常漂亮的Mandelbrot集生成图像。我也刚刚实现了自己的Mandelbrot算法。鉴于n是用于计算每个像素的迭代次数,我将它们从黑色到绿色再到白色的颜色非常简单(使用C++和Qt5.0):QColormapping(Qt::white);if(n0.5){//Closetothemandelbrotsetthecolorchangesfromgreentowhitemapping.setRgbF(color,1.f,color);}else{//Farawayitchangesfromblacktogreenmapping.setRg