Lane’s Blog

Roguestar, Haskell, and Fun

Archive for the ‘RSAGL’ Category

Monolith

without comments

monolith1.png

Written by Lane

January 12th, 2008 at 10:22 pm

Posted in RSAGL

Progressive Model Construction in RSAGL

without comments

Basically, the idea is that we want, for example, four levels of detail (LOD), with objects closest to the camera having the highest detail. But it takes time to generate models from their abstract description. So the solution is to generate the model at the lowest level of detail, and then fire off a thread to generate the remaining three levels of detail. The resulting image looks worse, but the animation is more fluid. It’s preferable to a three-second pause in the middle of a combat scene. Visually what you see is a 3D model that increases in quality with time, much like a progressive JPEG.

Written by Lane

December 9th, 2007 at 10:24 am

Posted in RSAGL

RSAGL, More Features

without comments

This planet has a slice taken out of it.

It uses a very simple ray-caster to compute a deformation of the sphere onto three planes. This has a benefit that we can take normal vectors from the planes, saving us the cost of computing normals for the entire deformed surface. It also has the benefit that as the ray-caster gains more geometries, it will be possible to project surfaces onto those geometries as well.

The ray caster will also be used to implement collision detection for projectiles and beams.

ringedplanetcut3.png

Written by Lane

December 6th, 2007 at 12:03 am

Posted in RSAGL

RSAGL, Some Features

without comments

So the first working version of the Roguestar Animation and Graphics Library is almost ready (but not in darcs yet).

One of the chief goals of RSAGL is a modeling language and model optimizer. You can see the results in this image:

ringedplanet2561.png

This image consists of three surfaces: two spheres and one disk with a hole. The moon in the background is modeled with visibly few polygons, being small, while the nearby planet is rendered at a high detail. The ring (which is unrealistically too close to the planet) is deformed using a sine wave.

Here’s another image with the same number of total vertices but the optimizer turned off. The moon actually looks better:

ringedplanet16x161.png

Written by Lane

November 25th, 2007 at 10:43 am

Posted in RSAGL