Skip navigation

Quake 3 BSP

Accurate and efficient environment geometry rendering is a fundamental part of any good game engine, and as such, one of the earliest features I implemented for my engine is the ability to load and render Quake 3 BSPs.

Tech:

  • C++
  • Direct3D
  • OpenGL

Notable Features:

  • Mulit-texturing (light maps)
  • PVS Culling
  • Bezier Patches
  • Frustum Culling

 

Real-time Lighting

As programmable video hardware is now the standard, a working knowledge of shader language programming is fundamental for game engineers. In this case, I have implemented a vertex and pixel shader for real-time lighting.

Tech:

  • C++
  • GLSL
  • HLSL

Notable Features:

  • Per Pixel Dyanmic Lighting
  • Specular Highlighting
  • Parallax Occlusion Mapping

 

Post Processing

In modern games, post processing effects such as blurring and lens flares are commonplace. In this example, I demonstrate the use of a sobel post processing filter to darken the lines of the rendered image to add a visual pop to the look of the world. When the debug text is blue, the filter is turned on.

Tech:

  • C++
  • GLSL
  • HLSL

Notable Features:

  • Sobel Post Process Filter
  • Two-Pass Rendering

 

Dynamic Shadows

Accurate shadows add visual fidelity and atmosphere to game experiences. In this demo, I use a typical two-pass shadow mapping technique whereby I cast a shadow from a dynamic object onto the Quake 3 BSP geometry.

First pass:
The scene is rendered from the light frustum perspective, and only objects that can cast shadows are rendered. The render target is a texture rather than the screen, and this texture is a shadow map that contains the distances from the rendered vertices to the light.

Second Pass:
A check is performed on objects that could be in shadow to see if they are in shadow. Basically, the object vertices are transformed into light camera clip space (this yields a shadow map texture coordinate). I then sample the shadow map using this texcoord and then check to see if the distance from the object vertex to the light is greater than the sampled shadow map distance. If so, then the given pixel is shadowed.

 

3DS Max Scene Rendering

Many game studios use their own custom file formats for the art and level assets for efficient packaging, security, and economy. To facilitate this, I have implemented a plugin for 3D Studio Max that exports to a custom file format called HMAX, and I have updated my engine to support HMAX file parsing and render the resulting scenes. This demo shows such a scene.

Tech:

  • C++
  • 3DS Max SDK
  • Custom 3DS Max Exporter Plugin (HMAX)

Notable Features:

  • Max Scene Rendering
  • Camera Animations
  • Object Animations

 

Skeletal Animations

The ability to accurately portray skeletal based animations is an incredibly important feature in modern games. I have implemented this in the typical way by passing bone weights, indices, and rest transforms to a vertex shader.

Tech:

  • C++
  • GLSL
  • HLSL
  • Custom 3DS Max Exporter Plugin (HMAX)

Notable Features:

  • Embedded In HMAX Format
  • Uses Bone Weights, Indices, and Rest Transforms

 

Terrain With LOD

Many games have large outdoor environments these days. The ability to render such environments in an accurate and economic way is an interesting and challenging problem. In this case, I divide the map into chunks, and I calculate the LOD of each chunk using its distance from the camera. I then use a stitching algorithm to fill in the holes left when 2 adjacent chunks have different LODs.

Tech:

  • C++
  • OpenGL
  • Direct3D

Notable Features:

  • Height Map
  • Terrain LOD Chunks
  • Stitching

 

“Lockless” Concurrency

Concurrency is an increasingly important technology in game engineering, and the importance will climb as consumer CPUs have more and more cores. The most efficient type of concurrency is known as “lockless”, and this technique is demonstrated via a simple RTS simulation. In this example, each unit update request is a work item in the FIFO, and the worker threads process these work items which make the units move and shoot at each other.

Tech:

  • C++

Notable Features:

  • Lockless Thread-safe Concurrency
  • FIFO Container For Work Items

 

Cloth Physics

Accurate physics simulations are a necessity in modern games. In this case, a cloth blowing in the wind that collides with other objects is an example of the kind of feature that’s included in modern games.

Tech:

  • C++
  • Direct3D
  • OpenGL

Notable Features:

  • Verlet Integrations
  • Constrained Particle System
  • Sphere Collisions On Particles

 

Level Design Tool

This was my first exposure to 3D graphics programming. As an undergrad I took a summer special topics course covering 3D graphics programming with OpenGL in C#. This was the final project that I implemented at the end of that class.

Tech:

  • C#
  • OpenGL

Notable Features:

  • Mouse Picking
  • Placable and Movable Objects
  • Quake 2 model support