Odiesoft - Enhanced Texture MappingDemoscene Demos
★ Ce texte vous est présenté dans sa version originale ★ 
 ★ This text is presented to you in its original version ★ 
 ★ Este texto se presenta en su versión original ★ 
 ★ Dieser Text wird in seiner Originalfassung präsentiert ★ 

If you want to stay in business in the demo scene you always had to come up with new effects, cool graphics and great demos. So I often spent a great deal of time to come up with new ideas or to think about how I could convert an idea from some other computer (mostly Amiga or PC) to the CPC.

Texture Mapping was THE big thing on 16 and 32 Bit computers in the early nineties. Games like "Wolfenstein 3D" and "Doom" were selling in the millions, mostly because of the texture mapped 3D environment that was the main feature of these games (and is an necessity for any game whatsoever nowadays...). For the 8 bit users the question whether texture mapping was possible on their machines or not was the paramount concern at that time.

On the C64 and later on the ZX Spectrum some users actually managed to create 3D engines with not too many drawbacks and a decent speed. Despite the higher CPU speed (3.75 Mhz) and the better calculation abilities the CPC was somehow left out of that 3D movement. Just a few users developed vector graphics routines and besides Face Hugger and me (as far as I know) nobody tried to write routines that rotated or twisted bitmaps and not only line graphics.

When I started to work on a texture mapping routine for the CPC I didn't really know how this was achieved on other systems. I hadn't looked up the algorithms in a book or so. I just thought about how I would do that. It turned out that the ideas I had weren't this much different from how it is really done. But I figured that rotating a surface in all three axes at the same time would consume too much calculation time for an at least somewhat smooth animation.

I wanted to give it a try anyways. I thought that if I just rotated a small square and then zoomed it to occupy a more substantial part of the screen it would look a lot better, probably a bit blocky, but hey, the CPC just ran with 3.75 Mhz, any texture mapping whatsoever on this machine would have been an accomplishment worth an award for outstanding achievements!

Nevertheless I wanted to start by rotating a face around the y-axis. Doing a rotation around the x-Axis would have been easier, but I felt that it wouldn't look very impressive. Actually I intended to do both, the rotation around x or around y (but not at the same time), but just the y-Axis rotation took up so much memory that there wasn't enough memory left for the x-Axis rotation anymore.

After trying to do this rotation routine with a regular program that used precalculated slopes for the different rotation phases I switched to a direct addressing scheme, since the former was way to slow. In the direct addressing approach each individual rotation is a complete program without any loops. Instead which byte or which part of the byte will be painted on what screen position is directly coded in assembler to speed up the drawing process. But as I said before, this takes up a lot of memory so I could just created a few animation phases and then there wasn't enough main memory left for much else. So the texture mapping is the main and only feature of the demo...

When I wrote the texture mapping demo I hadn't planned a release date or place yet. I just wrote it and when I was asked to contribute a part to the Jubilee Joy demo for the 10th birthday of the CPC I accepted. Thus the Texture Mapping became the final part of the Jubilee Joy demo.

The texture mapping demo was a classic suspense part, that is it didn't reveal its true face at once but offered just enough of the effect to arise curiosity in the viewers. Bit by bit it would add to the effect until it finally revealed itself for what it was: the first texture mapping on the CPC! So at fist you saw just a regular vector line cube, then it turned to a filled vector cube and finally the textures were displayed on the four available surfaces of the cube (the top and bottom surface were never seen...). Unfortunately I think I kept the users a little too much on the tenderhook, because it really took several minutes until you got to see the texture mapping and maybe some CPC freaks just didn't have the patience.

Well, but besides that I added some extra feature that fortunately didn't take up too much memory: a light source. This light source as just a simple ball that was able to rotate around the cube in both directions on the y-axis. By calculating a vector from the sun to the cube I was able to determine the amount of light falling on the surface and thus set the luminance of the colors for the surface. Since the CPC can just display 16 out of 27 colors at a time the luminance values for each color were pre-defined in table. I tried to find the best matches for each color, but with 27 colors you can just do so much...

On a green screen it looked a lot better, since there the hues of the 27 colors compose a linear gradient from very bright to black. Even though not many people used a green screen I still created a version of the demo that was designed for green screens. It looked a lot better, but I don't think a lot of CPC users have seen it.

Later during the demo you were able to gain control over the rotation of the cube and the light source. With the correspondent keys you could move the light source in one or the other direction, turn it on or off and start and stop the rotation of the cube. I've designed the demo in a way that the cube would rotate only in one direction. I don't remember why I did that. I think a lot of extra programming effort was involved in having the cube rotate clockwise as well - or probably I was just a little lazy. I don't remember, really!

Some time later I created an update of the texture mapping that had used the extended color range of the CPC+, some new graphics for the textures and that didn't take this long to get down to business. See the Texture Mapping Plus page in the demos section for more information.


★ YEAR: 1993
★ CRTC: ???
★ CONFIG: ???


Dumps disquettes:
» Odiesoft-Enhanced  Texture  MappingDATE: 2013-08-30
DL: 159 fois
SIZE: 84Ko

» Odiesoft-Texture  Mapping    BEBDATE: 2013-08-30
DL: 146 fois
SIZE: 57Ko

Je participe au site:
» Newfile(s) upload/Envoye de fichier(s)
★ AMSTRAD CPC ★ A voir aussi sur CPCrulez , les sujets suivants pourront vous intéresser...

» Demoscene » Pinball Dreams Beat Box Musicdisk (Epyteor)
» Demoscene » DSC Demo 7
» Demoscene » Fatality Cracktro #03
» Demoscene » Maxi-Micro 7 Pub
» Demoscene » "Robocop & Clandestine" One Screen Graphic Demo
» Demoscene » Mind In Motion


L'alinéa 8 de l'article L122-5 du Code de la propriété intellectuelle explique que « Lorsque l'œuvre a été divulguée, l'auteur ne peut interdire la reproduction d'une œuvre et sa représentation effectuées à des fins de conservation ou destinées à préserver les conditions de sa consultation à des fins de recherche ou détudes privées par des particuliers, dans les locaux de l'établissement et sur des terminaux dédiés par des bibliothèques accessibles au public, par des musées ou par des services d'archives, sous réserve que ceux-ci ne recherchent aucun avantage économique ou commercial ». Pas de problème donc pour nous!

CPCrulez[Content Management System] v8.7-desktop
Page créée en 014 millisecondes et consultée 1286 fois

L'Amstrad CPC est une machine 8 bits à base d'un Z80 à 4MHz. Le premier de la gamme fut le CPC 464 en 1984, équipé d'un lecteur de cassettes intégré il se plaçait en concurrent  du Commodore C64 beaucoup plus compliqué à utiliser et plus cher. Ce fut un réel succès et sorti cette même années le CPC 664 équipé d'un lecteur de disquettes trois pouces intégré. Sa vie fut de courte durée puisqu'en 1985 il fut remplacé par le CPC 6128 qui était plus compact, plus soigné et surtout qui avait 128Ko de RAM au lieu de 64Ko.