C4In progress
Code, creatively.
C4 is an open-source framework built to make creative coding easy for designers.1 I built it to put Core Animation's layers, animation and touch behind a few lines of code.
Project facts
- Role
- Creator and primary developer
- Years
- 2010 on; iOS from 20121
- Team
- Me, with Alejandro Isaza from 20143
- Built
- Objective-C, then Swift, on Core Animation and UIKit
- Learning
- A 25-chapter course and 200+ examples4
- Taught
- ACAD, OCAD, NYU ITP, TEI and Resonate5
- Licence
- MIT, on GitHub2
- Funding
- An ACAD fellowship and an AACTI grant6
Get to know C4.
The problem
The tools redrew everything, every frame.
Artists and designers made interactive work in Processing and openFrameworks. Both redrew the whole screen 30 or 60 times a second, whether anything changed or not, and projects, mine and others', overloaded. Neither had a native system for clicks, touches or gestures.

Processing's Storing Input example. Every frame, it paints the background and all 60 circles again.
-

Interfaces were the hard part.
At Ars Electronica Futurelab I worked between design and engineering, turning ideas into early software.
-

An experiment in motion typography.
It bridged the design and development teams at the Futurelab.
What I owned
What I did, and what others did.
-
The idea and the API.
I designed how C4 read and worked, from Cocoa for Artists on.
-
![The line [C4Shape ellipse:{x,y,w,h}]; in grey monospaced type, inside faint concentric circles.](../media/c4/ios-ellipse.png)
The Objective-C framework.
I wrote the iOS version on my own, from February 2012 through 2013.
-
WantedThe Swift version: C4's Swift source open in Xcode, or the GitHub history from the 2014 restart. 16:10, 1600 wide
The Swift version.
I rewrote it with Alejandro Isaza, who led the move. I made 828 of the 1,053 commits on GitHub.3
-
The course and the docs.
I wrote COSMOS and its app, the 2016 examples and tutorials, the installer and the Xcode theme.
-
The teaching.
I ran the workshops, taught the ACAD course and gave the talks.
-
WantedThe funding: a page of the ACAD fellowship or AACTI grant application. 4:5, 1200 wide
The funding.
I wrote the applications for the ACAD fellowship and the AACTI grant.
Where it came from
Every foundation under C4 was found while building TypeIs.
In Banff, in the Rockies, I built TypeIs, software for drawing with type. For it I moved to Objective-C and Core Text, and found that the Mac only redraws the parts of the screen that change. Core Animation sat underneath, and no creative-coding tool exposed it. In 2010 I rebuilt the ideas of Processing and openFrameworks on top of it, on the Mac, and called it Cocoa for Artists.1

Examples from Cocoa for Artists, the Mac version, 2011.
-

Drawing with type on a Cintiq.
The software before C4, in Objective-C and Core Text.
-

A print I made with the software.
The solution
Describe each change once. Core Animation plays it.
C4 had no draw loop. Each shape was a layer on screen. You changed its properties inside an animation block, and Core Animation played the change, redrawing only what moved. Touch, gestures, images and movies were objects that worked the same way.
The same sketch in C4. Each circle got one animation, and was removed when it finished.
override func setup() {
canvas.addPanGestureRecognizer { locations, center, translation, velocity, state in
ShapeLayer.disableActions = true
let circle = Circle(center: center, radius: 30)
self.canvas.add(circle)
ShapeLayer.disableActions = false
let a = ViewAnimation(duration: 1.0) {
circle.opacity = 0.0
circle.transform.scale(0.01, 0.01)
}
a.addCompletionObserver {
circle.removeFromSuperview()
}
a.curve = .Linear
a.animate()
}
}



Stars, polygons, arcs, curves and paths were all shapes, set up in one line each.
One ViewAnimation block animated a stroke's start and end, with repeats and reverses.
A pan gesture handed over every finger's location, ready to reshape a path.
Math functions came with the framework, drawn here as a curve.
A font and a string made a shape that could be filled, stroked and animated.
Underneath
Tough calls
We cut the Mac version that night.
A guy in a cowboy hat pulled out an iPhone in a bar in midwinter. My friend said even he had an iOS device. I started the iOS version in February 2012,1 and left 3D out: C4 worked only with Core Animation's 2D and pseudo-2D layers.
Shapes morphing on an iPad, 2012.
@implementation C4WorkSpace {
C4Shape *s1, *s2;
}
-(void)setup {
s1 = [C4Shape ellipse:CGRectMake(0, 0, 100, 100)];
[self.canvas addShape:s1];
}
-(void)touchesBegan {
s1.animationDuration = 2.0f;
s1.animationOptions = EASEOUT;
s1.backgroundColor = C4GREY;
s1.center = self.canvas.center;
}
@end
The decision to solely target a single, closed platform may seem like a limitation at first, but this hyper-focus on iDevices could prove to be a benefit, enabling C4 to do one thing and do it right.Harrison Weber, The Next Web, 20127
-
Text that highlights under a finger.
-
A dash pattern, animated.
-
![The line [C4Shape ellipse:{x,y,w,h}]; in grey monospaced type, inside faint concentric circles.](../media/c4/ios-ellipse.png)
One of the 10 apps I built for my 2014 Resonate talk.
Each one was a scene of dynamic type, animation and imagery.
The rewrite
Rewritten in Swift, then taught from start to finish.
In September 2014 Alejandro Isaza restarted the code as a blank Swift project, and led the move. I rewrote it with him. Swift's closures made the API smoother, and nothing was lost. C4 1.0 came out in July 2015.3 Then I wrote COSMOS, a 25-chapter course that designs, builds and publishes an app to the App Store, with 110 examples beside it.4

COSMOS's radial menu, separated into its layers. From chapter 15 of the course.
-

The course started from my sketch of the app.
-

C4's own Xcode colour theme.
Shown on C4's source, in light mode.
-

A diagram from chapter 16.
Rotating a line around its anchor point.
The impact
Tons of people learned on it.
I led many creative coding workshops over the years. I taught it in Calgary from 2010, at NYU's ITP, at TEI in Barcelona and at Resonate in Belgrade, and taught Programming for Artists with it at ACAD. Adam Tindale taught it at OCAD.5 Greg Debicki wrote 125 examples for it in 2013. I built installations and client apps with it.
-

Resonate, Belgrade, 2014.
I often gave lectures on artistic expression through software.
-

Halo, at Science World in Vancouver.
Alex Beim of Tangible Interaction built the controllers; I built the bridge that let C4's animations drive the lights.
-

CityBits.
C4 was its rendering engine.
-

M/O.
All of its graphics were drawn with C4.
The outcome
My artwork, then SAP, then Logic&Form, then Flow.
The work I made with C4 brought the SAP contracts, then my studio, then Flow. Flow began in 2015 as C4 Studio, an interface around C4's API, for designers who didn't want to program.
25
chapters in COSMOS, from the first sketch to the App Store.4
200+
examples, across the Objective-C and Swift versions.4
973
stars on GitHub, as of October 2026.2
C4 Studio, the tool that became Flow, in August 2017.
Logic&Form.
Building with C4 led to the design studio I opened, which made installations and apps.
The Canada Media Fund.
Its grant behind Flow was won on my C4 work.8
Flow.
We planned to build it on C4, then built a new animation framework on the same principles.
Automata.
In 2024 I dug it out, got it running, and made new work with it. The first Automata series came out of C4.
My take
Questions? Answers.
-
Is it still available?
Yes. The code is public on GitHub under the MIT licence. The last release, 3.0.1, came out in October 2017, for the Swift and Xcode of that time.2
-
Who built it?
I created it and wrote most of it. Alejandro Isaza led the move to Swift from 2014. The footnotes name everyone else.3
-
Why iOS only?
The Mac version came first, in 2010. By 2012 people carried iPhones everywhere, and touch was native there, so I cut the Mac version and kept iOS.
-
Was Flow built on C4?
No. We planned to, then built a new animation framework on the same principles. Flow began in 2015 as C4 Studio.
-
How was it funded?
With grants and my own time. An ACAD fellowship funded its production in 2012, and an AACTI grant through ACAD paid for examples, tutorials and the website.6
-
Do you still use it?
I did in December 2024 and 2025. I got it running again and made the first Automata series with it. Automata moved to a Metal engine in 2026, when it needed to make far more images.
