public void SetColorsFromNewSmoozedColors(SmoozeType type) { DirectBitmap map = Map; if (map.CalculatedTypes.Contains(type)) { for (int x = 0; x < map.Width; x++) { for (int y = 0; y < map.Height; y++) { try { if (map.usedColorIndices[x, y] != null) { if (type == SmoozeType.Single || type == SmoozeType.Type3) { map.SetPixel(x, y, Map.usedColorIndices[x, y].color[(int)type]); } else if (map.usedColorIndices[x, y] != null) { map.SetPixel(x, y, Constants.smoozedColors1024[Map.usedColorIndices[x, y].index[(int)type] % Constants.smoozedColors1024.Count]); if (map.usedColorIndices[x, y] == null || map.usedColorIndices[x, y].index[(int)type] > Constants.smoozedColors1024.Count) { } } } } catch { } } } } }
public void GetImage(DirectBitmap m, SmoozeType type) { if (fractalPlotter == null) { return; } demoType = fractalPlotter.Clone(m); demoType.SmoozeType = type; demoType.Reset(); demoType.MaxIterations = 32; demoType.DoCalculation(); }
private void radioButtonCheckedChanged(Object sender, EventArgs e) { if (radioButtonSingle.Checked) { smoozeType = SmoozeType.Single; } if (radioButtonType1.Checked) { smoozeType = SmoozeType.Type1; } if (radioButtonType2.Checked) { smoozeType = SmoozeType.Type2; } if (radioButtonType3.Checked) { smoozeType = SmoozeType.Type3; } mandelbrotPlotInset.SmoozeType = smoozeType; combinedControlSettings2MandelBrot(); mandelbrotPlotInset.DoCalculation(); Refresh(); }