Fractal Friday 2019.12.27

It’s the last Fractal Friday of the year, time for some recursive magic!  This week we’re exploring the Mandelbrot set, using two features of the Mathaesthetics prototype software: deep color mapping, and a new helpful zoom feature. Here’s where we start: In this image, there’s a color mapping with 10 different colors at various levels … Read moreFractal Friday 2019.12.27

Dev notebook: an enum alternative to GKState / GKStateMachine

I worked on my first GameplayKit project earlier this year and there were things I liked about the lightweight, general state-machine model provided by the GKState and GKStateMachine classes. However I also found a few odd patterns in these classes: their implementation without using enumeration values for states, the inelegant (StateClass).class.self syntax model required by … Read moreDev notebook: an enum alternative to GKState / GKStateMachine

Fractal Friday 2019.12.20

The fractal renderer used to draw this week’s graphics has a new feature – rendering in ‘edge’ mode. Rather than filling the value regions with different colors, edge-mode detects the change in output values and draws a line at the boundary between them. Here’s the classic Mandelbrot set rendered this way: Here’s a simple black-and-white … Read moreFractal Friday 2019.12.20

Scalar fields for gradients and other graphic patterns

The Mathaesthetics flagship app will support a number of modes of mathematical image creation. I spent most of yesterday working on and improving the scalar field renderer. In a scalar field, a function f(x, y) produces a value for each point. This scalar value is then mapped to a color gradient. I’m exploring both different … Read moreScalar fields for gradients and other graphic patterns

Fractal Friday 2019.12.13

It’s Friday already! This week I’ve been jamming on this application UI development, including a brand-new feature to support fractals: the color mapping control: For fractal rendering the integers below each color correspond to the output value (escape iterations) to which the color is assigned. The linear-gradient mapping mode means that colors between these values … Read moreFractal Friday 2019.12.13

Dev notebook: Converting scale & position of circular NSSlider for degrees

The standard Cocoa control NSSlider comes in a circular variety that resembles a rotating knob with an indicator point. Among the ideal applications for such a control is representing a circular angle. In the application I’m developing I wanted to use this to control the angle of the brush image used for drawing. I began … Read moreDev notebook: Converting scale & position of circular NSSlider for degrees

Painting with Trigonometry

I’m excited to share today’s image generated from the application under development: It’s a pretty organic background-pattern sort of texture, but it highlights a few cool things about the app, which is focused on creating beautiful images with mathematical techniques. First, the brush strokes! All of these strokes are ‘points’ drawn with an extra-wide calligraphy … Read morePainting with Trigonometry

Fractal Friday 2019.12.06

The Mathaesthetics software has made some cool advances this week, and we’re celebrating with our first Fractal Friday video! These images depict a Julia set of degree 3 (function z^3 + C), with the C value 0.4+0.7i, 50 iterations maximum, and the escape value slowly changing with each image. The first image has escape value … Read moreFractal Friday 2019.12.06

Flavors of static: random distributions and noise

It’s day one of noise generation in our flagship product! There are many ways to generate visual noise; our first algorithm is a simple static pixel generator. For these examples I’m generating a random integer from 0 to 255 and using that value to calculate a color on the gradient between two colors (here, blue … Read moreFlavors of static: random distributions and noise

Dev notebook: brush-like drawing in Swift, without CGPattern

I’m spending a lot of time in Cocoa drawing and Core Graphics lately, working in Swift. The API around the Core Graphics CGPattern object in Swift is a little challenging – it requires C callbacks and unsafe pointers for basic pattern-creation and drawing functionality. It also doesn’t work exactly as I’d like it to; I … Read moreDev notebook: brush-like drawing in Swift, without CGPattern