June 23, 2009

Mugi

The Mugi simulator can be downloaded here. Download the latest version for the best features.

Please note the simulator requires DirectX9c and does not have an installer. It can be simply unpacked from the zip archive to an install folder of your choice. I've done this to avoid writing to the registry so when your install folder is deleted, nothing whatsoever remains.

The following link DirectX9c Installer can be used to install DirectX.

If you have an Xbox controller plugged in it is used automatically. A two stick analogue joystick, keyboard, or mouse can also be used.

Xbox controller or joystick is the best way to play our flight simulator.

Xbox controllers can be downloaded from here.

February 13, 2009

Introduction

This blog will feature programming my current programming projects and follow my current interests. All the demos uise my abstracted cross platform graphics engine called 'Struffy'.

  • .Net
  • Cross platform game engine design
  • DirectX
  • OpenAL
  • SQLite
  • PHP
  • Collada
  • ODE and Bullet physics SDK
  • Mugi

Please click on a feed in the "blogs by subject" on the right hand side.

The following will link to my published source files. Empty at the moment but soon find the source code here.

For best results download the latest tech demo in the bottom right.

The following link DirectX9c Installer can be used to install DirectX. You can alternatively search the Microsoft site using the search words "DirectX End-User Runtime Web Installer".

All the demos require DirectX9c run time, but otherwise do not require installation. Unpack the zip, double click on the executable. Removing the folder will completely remove the demo from your system. Your computer will need a graphics card with Shader model 3, or above.

Car simulation

The car demo uses the Bullet SDK to simulate a car. Suspension is simulated using four spring constraints using a cylinder for each wheel. The game logic and renderer are decoupled so the logic can run a fixed 60 frames a second.

February 09, 2009

Terrains

This is a terrain rendered using a real time adaptive mesh. The wireframe view is shown below to illustrate how triangles concentrate around areas of roughness. This terrain algorithm is my own based on pre-chunked tiles. At run time only 16 bit index are uploaded. It's still too slow, so future releases will include the dual queue implementation from ROAM.


Download Terrain here, but this is work in progress. Currently the terrain holds a few lookup tables for the terrain which is 1 * 2^21 tiles big. As you can imagine, this is a lot of memory.

March 15, 2008

Normal mapping

I've added normal mapping to each of the skinned shadowing routines. To achieve this binormals and tangents were added to my vertex declaration and exported. The normal map is decoded in the pixel shader and a simple dot product used against the light vector made from multiplying the world space light vector and 3x3 matrix formed from tangent, binormal and normal.

March 10, 2008

Queried Virtual Shadow Maps

The latest uploaded shadow map technique is QVSM. The QVSM paper describes an approach where a large virtual texture can be used for the shadow map through several tiling and rendering schemes.

'Tech' demo 11 uses their brute force approach to tile shadow maps with multi-pass rendering. This is slow, but the paper goes on to discuss improved algorithms. I'm going to try these next.

I realised the first shadow map examples used a perspective matrix. I should have used an orthogonal perspective matrix for the light projection. This makes better use of the texture so the shadow map has a higher effective resolution.

March 04, 2008

Archived shaders

I use archives to organise data at a packing stage. They also reinforce a stringent memory layout as the game is running. Archives are just a collection of resources. For example, a vertex buffer, material and texture are resources.

The HLSL shaders are now resources. This enables the renderer to hot-swap between different shaders for the same model. "Tech" demo 10 shows a comparison between shadow maps and Variance Shadow Maps. The shader resource has enabled easy shadowing of the motion capture guy.

February 25, 2008

Variance Shadow Map

Variance Shadow Maps use a floating point texture to hold the values of the mean and mean squared distance from light source to shadowed pixel. The original paper published by William Donnelly and Andrew Lauritzen can be found here on the Variance Shadow Map page.

This technique is great because it allows the graphics hardware to be used to blur the shadow map and produce soft shadows. My first attempt at this routine doesn't use any filtering but this means it can be compared with the previous standard shadow map demo. The screenshot shows a single case where the standard shadow map had a banded shadow, and where the Variance Shadow Map has an artefact free shadow.

February 22, 2008

Shadow maps

No percentage closer filtering or bias as used in the yacht demo. Just a simple 512 square shadow map and sharp edged shadows. I have programmed this simple shadow map algorithm so I can make comparisons with other shadowing routines.

February 16, 2008

Blend shapes

I've added something in the middle of the test level that looks like a reshaping biscuit. This is a blend shape, blending between cube, sphere and pyramid. This can be used for deformable objects.

February 03, 2008

Picking algorithm



The current "tech" demo demonstrates a picking algorithm which lets the user control the placement of objects through the mouse pointer. A ray cast is used from the eye to determine both the object for selection, and the drop point. The picking logic determines the best position to place on the drop point. This takes some getting used to, but the speed which objects can be positioned shows it's effectiveness.

January 30, 2008

Struffy

A "tech" demo has been added to the downloads section. This is a small showcase of Struffy, my abstracted cross platform engine. This engine has been in development for 5 years.

The demo renders some physics objects which are modelled using ODE, although the physics implementation is also abstracted. The objects can be selected and moved. I'm going to continue to add new Struffy demos to this blog. The older versions of the same demo remain on the site but have been removed from the downloads list to save bandwidth.

January 27, 2008

WeatherLink to APRS

I've added a link in downloads describing an approach to uploading data from a weather station program to APRS using the scripting language PHP.

Here, the weather station program is WeatherLink and the APRS program is UI-View32, but this approach could be applied to other Weather stations and other APRS programs.


APRS was devised by Bob Bruninga, call sign WB4APR. The acronym stands for Automatic Packet Reporting System. Ham radio enthusiasts use this system across radio waves.

Through it's widespread adoption, a large network of stations running APRS has grown. The APRS network is currently used to place objects of interest on real world maps. This information is often details of the Ham enthusiast themselves, but equally it can be information that's useful to the Ham community. For example, hospitals, roads, ports and here, weather stations.



January 19, 2008

Nintendo Wii

After seeing Johnny Chung Lee's Wii remote projects I wanted to try them, but I had given my parents my Nintendo Wii. Instead, I made my own sensor bar and borrowed a Wii remote for work. You can use the Mugi easy LED unit guide if you fancy making one. IR Leds are invisible to the naked eye so you can use a phone camera or visible LED to establish if your circuit is working.

I've implemented my own HID driver in C++ from the WiiLi pages, but the library referenced from his site is worth downloading.

December 31, 2007

Photos

The photos in the slide show were taken with an Olympus Mju Touch 790 SW camera. It's water proof to 3m and shock proof. It probably takes better pictures than some of the cameras in enclosures and the lower quality wrist cameras. The only downside was that the strap supplied with the camera does not tighten, but you can fix that by using a Nintendo Wii strap if you have a spare.

December 30, 2007

My Mugi


Motion Capture Demo


This motion capture example uses a mesh and skeleton from http://www.motioncapturesociety.com. Motion capture data provided by http://www.mocapclub.com. Assets are released under their educational licence.