NewsProjectsTutorialsGalleryContactForum





Delphi :: OpenGL


Delphi :: OpenGL

:: Heightmap Terrain ::

Wednesday, July 18, 2007

A small demo which shows how to load a heightmap into OpenGL and display the terrain with a texture and normals. The terrain is encapsulated within a class which loads a heightmap from a bitmap picture, calculates surface normals and draws the heightmap optimally.


Developed using Delphi 2006Delphi 2006
   
 
 

Delphi :: OpenGL

:: Font Testbed ::

Sunday, May 06, 2007
   
 

An example program which uses a font loading unit (Font4.pas) to load fonts generated by the Font Studio project. (Updated to Version 4)


Developed using Delphi 2006Delphi 2006
 

Delphi :: OpenGL

:: FMod Frequency Spectrum ::

Monday, December 04, 2006

There is something special about visuals which go with music. This project shows how to get FMod to output the frequency spectrum of whatever it's playing at that moment, then uses the output to display a very satisfying lightshow. The only limit on the effects is your imagination!

The exe is bundled with Fmod 3.75 and one of Mark Vera's songs which he kindly let me use.


Developed using Delphi 7Delphi 7
   
 
 

Delphi :: OpenGL

:: Physics Testbed ::

Thursday, July 20, 2006
   
 

A work in progress.

One of my favorite algorithms is the spring model which allows you to simulate very realistic looking rope, string or elastic using 1D formations, Cloth and material in 2D lattices and boxes and jelly in 3D structures. The mathematical model of springs can simulate (read 'fake') quite complex physical behaviours which would otherwise be very hard to program. I developed a two dimensional testbed which allows you to create, link and manipulate vertexes to create structures such as ropes, boxes, bridges etc and to generally 'mess around' with the whole simulation. Using the magic of the spring model, these structures automatically have mass, a center of gravity and inertia.

The program allows you to create vertexes and then link them together with springs to form boxes and ropes. The links can be set to break under high stress.


Developed using Delphi 7Delphi 7
 

Delphi :: OpenGL

:: Castle Adventure (beta) ::

Sunday, February 26, 2006

Castle Adventure is based on the 1980's game by the same name. It's still in production and this is just a beta preview.

Castle Adventure's graphics engine uses OpenGL to display a 3D maze lit by baked vertex lighting and rendered with vertex buffer objects, with a 3rd person camera focused on the 'hero' character which is dynamically lit and casts simple blob shadows.


Developed using Delphi 2006Delphi 2006
No Source
   
 
 

Delphi :: OpenGL

:: Smoke Stack ::

Wednesday, October 01, 2003
   
 

Another great effect, this time it's a particle-based smoke effect. The program is ment to be kind of like a screen saver (Fullscreen, gentle and mesmerising) but if it doesnt like your screen (needs 85hz refresh rate at 800x600), just open up the config.txt file and edit the screen sizes, there is explanations in the file.

Another interesting point is that I tried to make the smoke act completely random; sometimes a thin wisp comes out, other times a great smoke-screen. The program continually changes these parameters to create a more dynamic feel.

Usefull stuff in the source:

  • - Drawing camera aligned billboards
  • - Practical application of the Font unit
  • - Framerate independant particle engine
  • - 3DS loading and display lists.


Developed using Delphi 7Delphi 7
 

Delphi :: OpenGL

:: Feedback ::

Tuesday, July 01, 2003

Another nice effect, this time it's a feedback effect: your cursor effects a map of forces then a grid of particles are pushed around by those forces. Rather like twisting a sheet of plastic into a wierd shape then pouring tiny balls onto it!

The project has three modes. The first, particle view, is the default where you just see the moving particles. Then the second mode, pictured here, applies the motion of the particles to a texture. The third mode just lets you see the force map, areas of brightness indicate high forces and different colours indicate direction. Another nice addition is the Auto-Reform mode where the particles also try to get back into the original grid while being pushed around by the force map.

Read the readme in the executable for info on how to use the program.


Developed using Delphi 5Delphi 5
   
 
 

Delphi :: OpenGL

:: Cloth Simulation ::

Tuesday, July 01, 2003
   
 

This project was my early attempt at physically modeling spring compression and reaction. Following a Gamasutra tutorial on springs and Hooke's law, I wrote this program to simulate a cloth which interacts with a plane and a sphere.

There are a few extras added such as environment mapping on the cloth (which requires normals to be calcuated frame-by-frame) and wind forces. For instructions, read the included readme file.

Included in the source to this program is my Strings unit which provides routines for creating, linking and simulating 3D/2D springs in real-time.


Developed using Delphi 5Delphi 5
 

Delphi :: OpenGL

:: 3DS Object Loader ::

Thursday, August 01, 2002

A program I wrote while figuring out how to load 3DS files. Any serious game or intro needs models, and 3DS is the easiest and most common way to get them. Unfortunately, understanding the structure of the files can be quite tricky at first, but luckily I've done all the hard work for you and packaged it all in a unit (Load3DS.pas) for easy intergration into any OpenGL program.

UPDATE:
It's been almost 4 years since the first incarnation of this project, and I've added many features and speed-ups to my 3DS file loader over those years. This is the latest version which includes:

  • Correct smoothing of vertex normals (using smoothing angle threshold)
  • Loads objects separately
  • Loads lights (untested)
  • Loads materials and material groups
  • Ability to load from resources embedded into the executable
  • Saves and loads back CMF files which offer simplicity and speed


Developed using Delphi 7Delphi 7
   
 
 

Delphi :: OpenGL

:: Lightning ::

Monday, July 01, 2002
   
 

A small project showing a cool lightning like effect. The code is very well documented and deals with linked lists or rather linked trees, using pointers. Some interesting recursive code here..

As usual, feel free to play around with it, use it in your own projects, just give credit where necessary.

UPDATE: I've remapped the effect, it looks more like proper real life lightning now…


Developed using Delphi 7Delphi 7
 

Delphi :: OpenGL

:: The Foundry ::

Saturday, June 01, 2002

The Foundry was my entry into the 2002 Gamedev.net 4e3 competition. (it came 5th out of ~40 entries) The competition centered around making a demo which displayed each of the four elements; Earth, Water, Fire and Air. Rather than make a boring terrain engine with water like most did, I opted for originality.

A lot of the inspiration for this project came from the now-legendary Kasparov demo and with the help of textures from Max Payne 1, the Foundry was born.

As usual, full source is provided…


Developed using Delphi 5Delphi 5
   
 
 




Delphi :: Win32


Delphi :: Win32

:: Mscript ::

Thursday, January 31, 2008
   
 

Writing your own programming language is one of those milestone projects that every programmer should attempt at least once.. Apart from being rediculously fun to do, it also teaches you a lot about how to structure code and why your compilers work the way they do.. So this is my attempt at a scripting language.

The demo comes with a testbed which allows you to run your own scripts and try out the language. The code shows how you might intergrate the Mscript class into your own project. It’s very easy to do, you only need use three functions: "Load" "Parse" and "Execute".


Developed using Delphi 2006Delphi 2006
 

Delphi :: Win32

:: Plugin DLL Demo ::

Friday, January 12, 2007

This small project demonstrates how to dynamically load and communicate with DLL files from within a parent application. As long as each DLL has a common interface with the outside world, each can perform a completely independent task. And because the DLL and parent application share memory spaces, you can pass classes and pointers between the two without having to worry about access violations.


Developed using Delphi 2006Delphi 2006
   
 
 

Delphi :: Win32

:: Lightmapper 2 ::

Sunday, August 27, 2006
   
 

I've revisited one of my older projects, the Lightmapper. While lightmappers arent exactly bleeding edge these days, they confront a lot of complex problems with usefull and multipurpose solutions.

New: I've implemented Spotlights, a number of lighting options (antialiasing, draft mode etc.), more unwrapping/packing options, project saving, and Lightmap Exporting.

Instruction Manual is included in the package.
Also look for the tutorial on how to read the LUV format back into your own apps.


Developed using Delphi 7Delphi 7
 

Delphi :: Win32

:: Normal Mapper ::

Thursday, August 17, 2006

If you doing any work with pixel shaders, you going to need some normal maps sooner or later. Well, I wasn’t impressed with the normal map generation programs out there at the moment, so I built my own.

It supports sourcing the data from each or all of the 3 colour channels and optionally inverting it. It can output the result to BMP, JPG and (uncompressed) TGA files.

Update:
Fixed a minor bug with the colour source selector and added a diffuse shaded preview.


Developed using Delphi 2006Delphi 2006
   
 
 

Delphi :: Win32

:: TCP/IP Networking ::

Saturday, December 10, 2005
   
 

This is an example of using Delphi's built in TTCPclient and TTCPserver objects (Delphi 7 that is) to create a networking client and server.
These components follow the structure of the usual winsock controls so it's not that hard to figure out whats going on if your more familiar with the winsock API.

It's the result of my first foray into the world of networking so it's pretty basic, but I've actually commented the code this time ;-)


Developed using Delphi 7Delphi 7
 

Delphi :: Win32

:: Matrix Math Demo ::

Sunday, August 01, 2004

A little project demonstrating matrixes and their effect on a 3D object.

Back in the 8-bit stoneage, before OpenGL, most DOS graphics programmers were obsessed with finding fast matrix routines for those ultra-cool rotating gouraud-shaded cubes! Well, here is my own rendition, just using GDI canvas commands. It also includes a usefull, if very basic, matrixmath unit.


Developed using Delphi 7Delphi 7
   
 
 

Delphi :: Win32

:: Cellular Automata ::

Sunday, February 01, 2004
   
 

Cellular Automata are a type of simulation where elements represent single-celled organisms. The survival and propagation of these cells are governed by very simple rules, such as how many neighbouring cells are alive and how many are required for new cells to be 'spawned'. This program allows you to interactively run a CA simulation and change the rules on the fly, as well as spawn your own cells.


Developed using Delphi 7Delphi 7
 

Delphi :: Win32

:: Lightmapper ::

Thursday, January 01, 2004

This project has been superceeded by Lightmapper 2
This quite large project creates lightmaps from 3DS scenes. It combines work I've done on various projects, including 3DS loading, planar mapping and volume shadows.

The lightmapper can output lightmaps from between 128x128 to 1024x1024 dimensions, and can handle multiple lights and shadows. The project also includes features such as an octtree implementation and normal smoothing. However, the program is not complete yet so feel free to improve on it! It still produces some visual artefacts at the lightmap corners and doesn’t handle certain cases well.

Please read the document included for operating instructions.


Developed using Delphi 7Delphi 7
   
 
 

Delphi :: Win32

:: Firestorm ::

Wednesday, October 01, 2003
   
 

A demonstration that 3D acceleration isnt everything.

Firestorm uses a 24-bit drawing surface with a 1024 colour palette to draw a particle engine at about 95fps average (for a 400x400 surface with 10000 particles on a 1.5ghz AMD) with the aid of FastLib. This can be blended with a 24bit background (additive or straight blending).

Firestorm offers a completely interactive tool for generating cool looking fire effects. Change one of the numerous sliders to the right of the fire and watch it change in real time. Also in this version is the ability to draw your own emitting maps (a series of points for the fire to originate from), and attractor and detractor modes. These modes change your mouse cursor into a magnet which affects each particle in real time. You can also make your own palettes, to change the colour of the fire very easily and on the fly.

Unfortunately no source is given with this project.


Developed using Delphi 7Delphi 7
No Source
 

Delphi :: Win32

:: Biezer Curves ::

Tuesday, July 01, 2003

A simple project which demonstrates beizer curves and interpolations.
Biezer curves are especially effective in camera paths and designing roads and tracks in games. Click and drag the control points around to see how the curve changes, and the slider controls how refined the curve appears.


Developed using Delphi 5Delphi 5
   
 
 

Delphi :: Win32

:: Crossword Generator ::

Tuesday, July 01, 2003
   
 

A break from my normal projects, I was asked to create a program which allows you to create crosswords easily and print them out. This was the result after a few days of coding. It's a very simple program but maybe someone will find some use for it.


Developed using Delphi 6Delphi 6
 


Tools


Tools

:: Font Studio ::

Sunday, September 02, 2007

Font Studio 4.1 is here!
Font Studio is my completely free bitmap font generator for use in OpenGL/DirectX/XNA applications. It generates bitmaps from windows fonts, and applies special effects such as a drop shadow, colouring and kerning (space between characters). It provides support for any range of unicode characters you'd want and can output to any sort of file you want via a robust plugin interface.


Developed using Delphi 2006Delphi 2006
No Source
   
 
 

Tools

:: Sims Package Explorer ::

Wednesday, December 01, 2004
   
 

This project opens .Package files used in The Sims 2 and SimCity 4 and can extract the files they contain.

I wrote it primarily to extract music so it detects MP3 files and little else. You can edit the known file types by editing the .ini file included. It uses the first few bytes of the file to detect what it is.

Once the package is loaded, you are able to select multiple files and extract them to your directory of choice.


Developed using Delphi 7Delphi 7
 

Tools

:: Diablo 2 Character Resurrector ::

Monday, November 01, 2004

While playing Diablo 2 on the Hardcore skill level, you get better items and more experience, quicker. But there is always the danger of dying because hardcore characters cannot be resurrected.

Until now that is! This tool can resurrect hardcore characters that have died, but you do not loose experience or your items (The body is placed at the town centre).

Please backup your character files before resurrecting.


Developed using Delphi 7Delphi 7
   
 
 

Tools

:: Need For Speed 6 - Model Viewer ::

Wednesday, October 01, 2003
   
 

A professional looking application I developed for fun. It loads NFS 6 cars and allows you to view them with almost as good graphics as in the game. It's a bit tricky to use because you first have to read the help file! and extract all the data out of the resource files that come with the game. The help file shows you how to do this, with what tools and where to get them.

UPDATE:
I've uploaded the source to this project. You may have some difficulty when trying to compile it since it uses Mike Lischke's VirtualTreeView (avaliable here)


Developed using Delphi 6Delphi 6
 


 
 

Site Map: News | Projects | Tutorials | Gallery | Contact

Best Viewed With Mozilla Firefox

:: Nitrogen V3.0 © 2007 Michael Pote ::