RSS Feed

Comments RSS

Python – very graphic! cont.

I must say, this has been a great experience trying out some graphical programming in Python. I looked at two different graphics packages for this exercise, Tk and PyGame. While Tk is very good for many graphical interfaces, particularly GUI, it did not provide what I needed most – the ability to do pixel by pixel plotting. Tk, does provide a “way” of doing it using the PhotoImage class, but it was rather cumbersome and felt like a workaround. So, I explored PyGame. It is a mature third party Python library specifically designed for graphical game design. It had exactly what I needed and was very straight forward. I simply wanted to create a display screen area and plot colored pixels to it corresponding to Mandelbrot Set. PyGame gave me exactly what I needed. Here is a series of pictures of the Mandelbrot Set. First, the full set. Second, an image zooming in on a region in the set. Third, zooming in even further. The fascinating thing about the Mandelbrot Set, and all fractal objects, is the the more you zoom in, the more detail you see – not less.

The Mandelbrot Set

Zooming in on the Mandelbrot set #1

Zooming in on the Mandelbrot Set #2

One Response to “Python – very graphic! cont.”