Examples

To keep the promise, of making the entry level as low as possible, examples are provided, which give first hints, how to program with HGamer3D.

Source Code of All Examples, Version 0.1.5

Rotating Mesh
code
This example shows the basic ingredients of a 3D application, setup of scene, rendering loop and keyboard input. Keyboard is used, to rate a loaded mesh, try the keys: "A", "D", "W", "S" and "Q", "E" for different rotations.
Rotating Mesh Example

Lines and Cubes
code
This example shows the creation of geometry basics. Lines and Cubes. Also what can be seen here, is that a group of objects can be rotated as a group.

Animated Figure
code
This example shows the animation of a character.

Animated Lights
code
This example shows the animation of a lens flare, which is implemented as a billboard. It also shows, how to combine methods of the "One" API with methods from the bindings API.

Manual Object Cube
code
This example shows the creation of a cube with many colors by the manual object API of Ogre. Almost direct usage of the bindings API.

Regular Solids
code
This example shows how to create regular solids with metal like material.
Regular Solids Example

Dump Devices
code
This example shows how to get the names of all connected Input devices from OIS, useful, to check before using names in OIS.

Audio Examples
code 2d
code 3d
Those examples show usage of the Audio API (2D and 3D).

Y-Wing Flight
code
This example shows a Y-Wing flying through a series of goals. It is equipped with Joystick support, creating of a larger number of colorful rectangles, loading a mesh and also following the Y-Wing with the camera.

One API
code
This is the implementation of the One API (the first higher level Haskell API), based on the wrapper methods. It shows pretty well the usage of the basic wrapper API. From this and the Ogre C++ documentation, you should gather a good understanding, how to use the deeper layers of the binding.

Add new comment

Filtered HTML

  • Web page addresses and e-mail addresses turn into links automatically.
  • Allowed HTML tags: <a> <em> <strong> <cite> <blockquote> <code> <ul> <ol> <li> <dl> <dt> <dd>
  • Lines and paragraphs break automatically.

Plain text

  • No HTML tags allowed.
  • Web page addresses and e-mail addresses turn into links automatically.
  • Lines and paragraphs break automatically.