Everything

Programming Side Projects Music Art Animation Blog Everything

Programming

p5.Framebuffer

June 4, 2022

A library for efficiently drawing to a texture in p5 WebGL mode.

This gives you access to Framebuffers, which are WebGL-only and similar to a p5.Graphics, but faster, and includes depth information.

GLSL Autodiff

August 13, 2021

Tired of doing math to get normals in your vertex shader? Same. Use this library to write your function once and generate derivatives automatically!

Sometimes, I want to displace mesh vertices in a vertex shader. After doing this, the normals of a surface should change. However, per-vertex normals don't automatically update! Manual updating of vertex normals requires you to take the derivative of your displacement function. This library automates that process so that it takes less time and is less prone to user error.

StrokeStrip: Joint Parameterization and Fitting of Stroke Clusters

Written in collaboration with Chenxi Liu, Nicholas Vining, Mikhail Bessmeltsev and Alla Sheffer.

ACM Transactions on Graphics, August 1, 2021

Artist-drawn vector sketches use clusters of strokes to convey intended curves. StrokeStrip fits intended curves to such clusters by computing and utilizing a joint arc length parameterization of each cluster, producing clean lines consistent with viewer expectations.

We observe that viewers perceive stroke clusters as continuous, varying-width strips whose paths are described by the intended curves. An arc length parameterization of these strips defines a natural mapping from a strip to its path. We therefore recast the curve fitting problem as one of parameterizing the cluster strokes using a joint 1D parameterization that is the restriction of the natural arc length parameterization of this strip to the strokes in the cluster.

Differentiable Shadow Rendering

Written in collaboration with Jerry Yin.

April 14, 2020

We propose a differentiable formulation for soft shadows, allowing optimization of rendered images that include soft shadows with respect to scene parameters.

Our implementation enables applications such as optimizing a model with respect to its shadow. An example task motivating this work is the algorithmic generation of shadow art, in which a 3D shape produces different artist- specified shadow shapes when lit from different angles. An example of shadow art can be found on the cover of the book Gödel, Escher, Bach. Our goal is to find a reasonable tradeoff in this optimization task between visual quality and performance.

More Programming

Side Projects

Weather Systems

June 17, 2022

Clouds, trees, and rainbows

Train Knots

June 2, 2022

Loopy knotty tracks

Twinge

Written in collaboration with Maddy Leadbetter.

April 22, 2022

Replace every face in a group of faces with your face

Math textbook covers

April 15, 2022

Why do they always have bears?

More Side Projects

Music

She Answered The Trees

November 19, 2021

A mashup of a few genres, centered around some ukulele

Limits

January 16, 2021

Channeling stress into dance music, inspired by Remain In Light.

Motion Blur

March 29, 2020

Reflections on quarantine distilled into a small EP.

More Music

Art

Zoom friends

May 24, 2022

A meme painting, done with my sister

Yonge St. near Davisville

May 24, 2022

Looking down at Yonge St. near the Mt. Pleasant cemetery

Experimental Farm greenhouse

March 7, 2022

The greenhouse in Ottawa's Experimental Farm in the fog

Hourly Comics

February 16, 2022

Made for #hourlycomicday 2022

More Art

Animation

Pickle brine shot

April 20, 2022

A tiny animation about drinking a shot of pickle brine

Adrift

August 16, 2020

A meditation on feeling isolated, counting down to something different.

Get Back to Work

April 18, 2019

A vignette about daydreaming when you have work to do.

Spring

May 4, 2017

A vignette about the changing of seasons.

More Animation

Blog

Flood Fill in Blender Grease Pencil

May 1, 2022

How the fill bucket tool in Blender works and how I tried to make it a little better.

Depth of field in p5.js

October 3, 2021

Let's add some blur to p5 WebGL mode!

Deforming 3D shapes in real time, for the algebraically challenged

August 1, 2021

A recent rabbit hole I went down: how do you deform and distort arbitrary 3D shapes in real time and still have useable normals without having to do a bunch of derivatives by hand?

Why does dappled light look like that?

May 8, 2021

A bit about how lighting works. Tl;dr: it's a bunch of pinhole cameras.

More Blog