Graphical Solar System in C++

Weeks Spent
Team Size


For Graphics/Game Engine Programming II, our final assignment was to take all of the knowledge we have learned about graphics programming, and lighting models and create a solar system from it. There were two parts to this project:

  • Joint Based Animation
  • Graphics

The assignment was a team project, and I took the graphics side, and my partner took the animation side. We were given about 4 weeks to create this, and I wanted to do some really awesome effects for this, and bring the project to the next level.


SS_01  RockIcePlanetSolarSystem


Real Time Glow

The multiple stars in the scene have a real time glow applied to them. This effect is based on a rendering technique outlined in GPU Gems: Real Time Glow. The technique in GPU Gems focuses on technique that includes multiple rescaling operations on the render texture, scaling it down by small amouts a set amount of times, then rescaling it back up to take some of the work of the blur effect.

This sounded like a costly operation, copying and resizing a texture multiple times per frame for every frame. Instead, I opted to scale it down only once, and then back up. This reduced the amount of memory needed for render textures, and hardly effected render time. On each rendertarget resize, we perform a blur to get the glow texture.

The glow texture is a multicolor texture that is alpha blended on top of the scene to create the effect. It is important to remember to render each object that doesn’t have glow as a blacked out object so that we can block certain objects that will glow. This prevents the glow effect from appearing above objects in the scene.


The lighting model used in this solar system is a simple phong implementation. Each type of shader we wanted is available as it’s own HLSL .fx file. So a file that has diffuse and specular is available as a simple fx file, and each permutation that can be made.

You will notice that some of the planets have a lot of texture. As in they look very bumpy or mountainous. I used a heigh map to perform this, and the displace is performed in the vertex buffer using


by using this we are able to displace each vertex by a given amount represented by the height map.

Leave a Reply

Your email address will not be published. Required fields are marked *