top of page

Raymarched Clouds

Language: OpenGL 

I created a cloud-like effect by raymarching through octaves of simplex noise, with a nested raymarch towards the light source to create shadows. This was implemented as a custom shader in Substance Designer.

Pathtracer

Language: C++

A path tracing renderer assignment for the Computer Graphics course at Carnegie Mellon. It can render diffuse, reflective, and refractive materials. Global illumination is done via Monte Carlo path tracing with Russian Roulette to terminate the paths. The renderer can use .exr files as environment maps to add light to scenes. It also generates a Bounding Volume Hierarchy for each mesh to accelerate triangle mesh intersection.

Crowd Simulation

Language: C#

I read the paper ‘A Synthetic-Vision Based Steering Approach for Crowd Simulation’ (SIGGRAPH 2010) by Ondrej et al. and attempted to replicate their results with a C# script in Unity. The paper describes an algorithm to simulate obstacle avoidance in humans by creating a synthetic optic flow for each individual. Each individual continuously calculates the change in bearing angle between themselves and all obstacles in their field of vision, turning to eliminate the danger of collision as well as slowing down if collision is imminent. Using this method, Ondrej et al. were able to show the emergence of patterns within crowds and eliminate deadlocks.

When implementing the algorithm, I had to make some adjustments such as changing model parameters. Some parameters chosen in the paper didn't work well in my simulation, most likely due to differences in scale, and had to be adjusted. 

Flocking Simulation

Language: C++, Python

I created a flocking simulation in C++ for my final project in the Computer Graphics course at Dartmouth. The program simulates flocking behavior, following the Boids model established by Craig Reynolds. The particles in the program all obey rules of cohesion, alignment, and separation. The resulting behavior simulates the movement of animals groups such as flocks of birds or schools of fish.

I later wrote a new version of this script in Python to run in Maya, and added goal steering behavior. The above video is a demo created in Maya using the script. 

Mathematical Model

I formulated a mathematical model based on this flocking simulation for a 2 week research project in my applied math course. A poster detailing my research can be viewed by clicking on the image above.

Viscoelastic Fluid Simulation

Engine: Unity     Language: C#

For a project in my Technical Animation course at Carnegie Mellon, I read the paper 'Particle-based Viscoelastic Fluid Simulation' by Clavet et al. (2005), and implemented it in Unity. The goal of this paper was to improve the traditional Lagrangian fluid simulation method by introducing a new procedure to enforce incompressibility and anti-clustering, called double density relaxation. The double density relaxation prevents clustering by taking into account density as well as a new term called near-density, which creates a repulsive force between neighboring particles. Viscoelasticity is a combination of elasticity, plasticity, and viscosity. Elasticity is created by inserting springs between particles, which apply displacement to the particles depending on the spring’s rest length and stiffness constant. Plasticity is determined by the extent to which the springs change their rest length as the fluid moves. 

Using this algorithm, I was able to simulate a variety of fluid behaviors. I ran simulations ranging from 300 to 10,000 particles. For 300 particles, I was able to achieve an frame rate of around 20fps, allowing the fluid to be interactible. 

FABRIK IK Solver

Engine: Unity     Language: C#

For a project in my Technical Animation course at Carnegie Mellon, I read the paper 'FABRIK: A fast, iterative solver for the Inverse Kinematics problem' by Aristidou & Lasenby (2011), and implemented it in Unity. This paper describes a new algorithm to solve for joint positions in an inverse kinematic system. The method is called Forward and Backward Reaching Inverse Kinematics, and computes joint positions by locating positions on a line instead of solving for rotational angles. The result is efficient and produces reliable results. I implemented the algorithm for a single chain as well as a chain with multiple end effectors. 

Cloth Simulation

Engine: Unity     Language: C#

A spring-mass cloth simulation script written for my Technical Animation course at Carnegie Mellon. It can perform four different integration methods, which can affect the cloth appearance and the maximum allowable timestep for the simulation. 

Raindrop Ripple Shader

Engine: Unity      Language: Cg/HLSL, Shaderlab

During GDC 2017, I attended a talk called 'Shaders 201: Creating Art with Math' by Ben Cloward from BioWare. He showed how to create a rain ripple effect using the node-based shaders in Unreal Engine. I thought it was really clever how he stored all the needed information within one texture. The ripple effect used a radial gradient texture and a cone normal map. The red channel of the gradient texture is combined with the green and blue channels of a cone normal map. The value of the red channel is offset by a time value that loops from 1 to 0, and fed into a damped sine curve and appended to the green and blue channel values to get the amount of normal offset. Then the combined gradient and normal texture is cloned several times in one image to get the effect of multiple drops. In order to make the drops occur at different times, he used the texture's alpha channel to store different values for each drop, and referenced these values to add an extra time offset. I recreated the shader in Unity, then took some pre-made models to create a scene layout with lighting and fog. 

Raytracer

Language: C++

A basic raytracing program created for my Computer Graphics course. Its features include lambert and Blinn-Phong materials, point and area lights, anti-aliasing, reflections, projective texture mapping, and mesh intersection. It can also implement normal smoothing, different types of spline subdivision, displacement mapping, and Catmull-Clark subdivision.

Webcam AR

Engine: Unity      Duration: 1 day      Language: C# 

I worked on this simple augmented reality progam for the 2016 HackDay at Dartmouth, where students created new apps in less than a day. Using Unity's ability to access a computer's webcam, I wrote a script that tracks the location of a specific color in the webcam and moves a 3D model in relation to it. 

bottom of page