NeHe Lessons

From SDL.NET

The NeHe lessons are a series of demos and tutorials to guide through the various features of OpenGL. SDL.NET provides implementations of most of the NeHe lesson tutorials by using a number of assemblies from the Tao Framework including Tao.OpenGl and Tao.Platform.Windows

Table of contents

NeHe Lesson 01: Setting Up An OpenGL Window

NeHe001 Demo Screenshot
Enlarge
NeHe001 Demo Screenshot

This lesson simply sets up an OpenGL window using SDL.NET. It shows up blank. The source code is here (http://cs-sdl.svn.sourceforge.net/viewcvs.cgi/cs-sdl/trunk/SdlDotNet/examples/SdlDotNetExamples/NeHe/NeHe001.cs?view=markup)

NeHe Lesson 02: Your First Polygon

NeHe002 Demo Screenshot
Enlarge
NeHe002 Demo Screenshot

A triangle and a square polygon are drawn to the Surface. The source code is here (http://cs-sdl.svn.sourceforge.net/viewcvs.cgi/cs-sdl/trunk/SdlDotNet/examples/SdlDotNetExamples/NeHe/NeHe002.cs?view=markup)

NeHe Lesson 03: Adding Color

NeHe003 Demo Screenshot
Enlarge
NeHe003 Demo Screenshot

Color is added to the polygons. The source code is here (http://cs-sdl.svn.sourceforge.net/viewcvs.cgi/cs-sdl/trunk/SdlDotNet/examples/SdlDotNetExamples/NeHe/NeHe003.cs?view=markup)

NeHe Lesson 04: Rotation

NeHe004 Demo Screenshot
Enlarge
NeHe004 Demo Screenshot

The polygons will rotate. The source code is here (http://cs-sdl.svn.sourceforge.net/viewcvs.cgi/cs-sdl/trunk/SdlDotNet/examples/SdlDotNetExamples/NeHe/NeHe004.cs?view=markup)

NeHe Lesson 05: 3D Shapes

NeHe005 Demo Screenshot
Enlarge
NeHe005 Demo Screenshot

The demo renders a tetrahedron and a cube and rotates them. The source code is here (http://cs-sdl.svn.sourceforge.net/viewcvs.cgi/cs-sdl/trunk/SdlDotNet/examples/SdlDotNetExamples/NeHe/NeHe005.cs?view=markup)

NeHe Lesson 06: Texture Mapping

NeHe006 Demo Screenshot
Enlarge
NeHe006 Demo Screenshot

This demo renders a texture on a rotating cube. The source code is here (http://cs-sdl.svn.sourceforge.net/viewcvs.cgi/cs-sdl/trunk/SdlDotNet/examples/SdlDotNetExamples/NeHe/NeHe006.cs?view=markup)

NeHe Lesson 07: Texture Filters, Lighting, and Keyboard Control

NeHe007 Demo Screenshot
Enlarge
NeHe007 Demo Screenshot

The right, left, up and down arrows will rotate the cube. The'L' key will change the lighting. The 'F' key will change the filtering. The source code is here (http://cs-sdl.svn.sourceforge.net/viewcvs.cgi/cs-sdl/trunk/SdlDotNet/examples/SdlDotNetExamples/NeHe/NeHe007.cs?view=markup)

NeHe Lesson 08: Blending

NeHe008 Demo Screenshot
Enlarge
NeHe008 Demo Screenshot

Similar to Lesson 7, but the 'B' key will blend the cube. The source code is here (http://cs-sdl.svn.sourceforge.net/viewcvs.cgi/cs-sdl/trunk/SdlDotNet/examples/SdlDotNetExamples/NeHe/NeHe008.cs?view=markup)

NeHeLesson 09: Moving Bitmaps in 3D Space

NeHe009 Demo Screenshot
Enlarge
NeHe009 Demo Screenshot

This demo draw a bitmap in 3D space. the 'T' key will change the twinkling of the stars. The 'PageUp' and 'PageDown' keys change the zoom. The 'Up Arrow' and 'Down Arrow' keys change the tilt. The source code is here (http://cs-sdl.svn.sourceforge.net/viewcvs.cgi/cs-sdl/trunk/SdlDotNet/examples/SdlDotNetExamples/NeHe/NeHe009.cs?view=markup)

NeHe Lesson 10: Loading and Moving through a 3D World

NeHe010 Demo Screenshot
Enlarge
NeHe010 Demo Screenshot

This demo moves you through a small room of rendered walls. Use the arrow keys to move around. The 'F' key will change the filter. The source code is here (http://cs-sdl.svn.sourceforge.net/viewcvs.cgi/cs-sdl/trunk/SdlDotNet/examples/SdlDotNetExamples/NeHe/NeHe010.cs?view=markup)

NeHe Lesson 11: Flag Effect (Waving Texture)

NeHe011 Demo Screenshot
Enlarge
NeHe011 Demo Screenshot

This demo shows a texture waving liek a flag. The source code is here (http://cs-sdl.svn.sourceforge.net/viewcvs.cgi/cs-sdl/trunk/SdlDotNet/examples/SdlDotNetExamples/NeHe/NeHe011.cs?view=markup)

NeHe Lesson 12: Display Lists

NeHe012 Demo Screenshot
Enlarge
NeHe012 Demo Screenshot

This demo uses lists to create series of boxes that can be rotated withte arrow keys. The source code is here (http://cs-sdl.svn.sourceforge.net/viewcvs.cgi/cs-sdl/trunk/SdlDotNet/examples/SdlDotNetExamples/NeHe/NeHe012.cs?view=markup)

NeHe Lesson 13: Bitmap Fonts

NeHe013 Demo Screenshot
Enlarge
NeHe013 Demo Screenshot

This lesson renders a bitmapped font. This lesson is for the Windows platform. The source code is here (http://cs-sdl.svn.sourceforge.net/viewcvs.cgi/cs-sdl/trunk/SdlDotNet/examples/SdlDotNetExamples/NeHe/NeHe013.cs?view=markup)

NeHe Lesson 14: Outline Fonts

NeHe014 Demo Screenshot
Enlarge
NeHe014 Demo Screenshot

This lesson renders a outline bitmapped font. This lesson is for the Windows platform. The source code is here (http://cs-sdl.svn.sourceforge.net/viewcvs.cgi/cs-sdl/trunk/SdlDotNet/examples/SdlDotNetExamples/NeHe/NeHe014.cs?view=markup)

NeHe Lesson 15: Texture Mapped Outline Fonts

NeHe015 Demo Screenshot
Enlarge
NeHe015 Demo Screenshot

This lesson renders a texture onto a bitmapped font. This is for the Windows platform. The source code is here (http://cs-sdl.svn.sourceforge.net/viewcvs.cgi/cs-sdl/trunk/SdlDotNet/examples/SdlDotNetExamples/NeHe/NeHe015.cs?view=markup)

NeHe Lesson 16: Cool Looking Fog

NeHe016 Demo Screenshot
Enlarge
NeHe016 Demo Screenshot

This lesson creates fog around the rotating cube found in Lesson 7. The 'G' key will filter the fog. The source code is here (http://cs-sdl.svn.sourceforge.net/viewcvs.cgi/cs-sdl/trunk/SdlDotNet/examples/SdlDotNetExamples/NeHe/NeHe016.cs?view=markup)

NeHe Lesson 17: 2D Texture Font

NeHe017 Demo Screenshot
Enlarge
NeHe017 Demo Screenshot

This lesson uses a 2D texture font instead of a bitmapped font. The source code is here (http://cs-sdl.svn.sourceforge.net/viewcvs.cgi/cs-sdl/trunk/SdlDotNet/examples/SdlDotNetExamples/NeHe/NeHe017.cs?view=markup)

NeHe Lesson 18: Quadrics

NeHe018 Demo Screenshot
Enlarge
NeHe018 Demo Screenshot

This lesson shows how to use quadrics to draw complex shapes such a a cube, a cone, a cylinder and a sphere. The 'space bar' will toggle through the various shapes. The arrow keys will rotate the object in different directions. The source code is here (http://cs-sdl.svn.sourceforge.net/viewcvs.cgi/cs-sdl/trunk/SdlDotNet/examples/SdlDotNetExamples/NeHe/NeHe018.cs?view=markup)

NeHe Lesson 19: Particle Engine Using Triangle Strips

NeHe019 Demo Screenshot
Enlarge
NeHe019 Demo Screenshot

The source code is here (http://cs-sdl.svn.sourceforge.net/viewcvs.cgi/cs-sdl/trunk/SdlDotNet/examples/SdlDotNetExamples/NeHe/NeHe019.cs?view=markup)

NeHe Lesson 20: Masking

NeHe020 Demo Screenshot
Enlarge
NeHe020 Demo Screenshot

This lesson uses masking instead of blending to place two images on top of each other. The source code is here (http://cs-sdl.svn.sourceforge.net/viewcvs.cgi/cs-sdl/trunk/SdlDotNet/examples/SdlDotNetExamples/NeHe/NeHe020.cs?view=markup)

NeHe Lesson 23: Sphere Mapping, Multi-Texturing and Extensions

NeHe023 Demo Screenshot
Enlarge
NeHe023 Demo Screenshot

This lessons shows how to create a reflection off of an object. The space bar will toggle through the various objects. The arrow keys will rotate the object. The source code is here (http://cs-sdl.svn.sourceforge.net/viewcvs.cgi/cs-sdl/trunk/SdlDotNet/examples/SdlDotNetExamples/NeHe/NeHe023.cs?view=markup)

NeHe Lesson 25: Morphing and Loading Objects from a File

NeHe025 Demo Screenshot
Enlarge
NeHe025 Demo Screenshot

This lesson loads points from a file and displays them in a shape. use the arrow keys to rotate the object. Use the '1-4' keys to toggle through the shapes. The source code is here (http://cs-sdl.svn.sourceforge.net/viewcvs.cgi/cs-sdl/trunk/SdlDotNet/examples/SdlDotNetExamples/NeHe/NeHe025.cs?view=markup)

NeHe Lesson 26: Clipping & Reflections Using The Stencil Buffer

NeHe026 Demo Screenshot
Enlarge
NeHe026 Demo Screenshot

This lesson creates realistic reflections. Use the arrow keys to rotate the ball. Use the 'Page Up' and 'Page Down' keys to change the ball height. The source code is here (http://cs-sdl.svn.sourceforge.net/viewcvs.cgi/cs-sdl/trunk/SdlDotNet/examples/SdlDotNetExamples/NeHe/NeHe026.cs?view=markup)

NeHe Lesson 34: Beautiful Landscapes By Means Of Height Mapping

NeHe034 Demo Screenshot
Enlarge
NeHe034 Demo Screenshot

This lesson renders a height map. Use the 'Up' and 'Down' arrow keys to zoom in an out. The source code is here (http://cs-sdl.svn.sourceforge.net/viewcvs.cgi/cs-sdl/trunk/SdlDotNet/examples/SdlDotNetExamples/NeHe/NeHe034.cs?view=markup)

See Also