From: "Nick Anderson" Newsgroups: comp.os.msdos.djgpp Subject: Re: Patterned polygons(PowerMonger style). Date: Thu, 16 Apr 1998 08:52:22 +0100 Organization: [not set] Lines: 42 Message-ID: <6h4del$qmf$1@svr-c-02.core.theplanet.net> References: NNTP-Posting-Host: gate-isdn.telsci.co.uk To: djgpp AT delorie DOT com DJ-Gateway: from newsgroup comp.os.msdos.djgpp Precedence: bulk >I'm not familiar with PowerMonger Oh... okay. ;-) > but if you just want a 2d tiled >pattern to be overlayed on your polygon, the best option is to use >the 2d triangle() or polygon() functions. To do this with the 3d >code, use any of the texture mapping functions (these could be made >to simulate a flat 2d texture if you specify the right u/v >coordinates, but are primarily intended for textures which will >scale and stretch to look like they are part of the 3d object, >rather than just a flat overlay). The problem is that I DON'T want to have to use texture mapping :-) The thing about powermonger was that as the landscape rotated, the pattern kept it's intensity as the polygon changed. I am holding the information for each polygon in something like V3D_f v[4]; and when I use the perspective projection, the v[?].x, v[?].y and v[?].z are turned into v[?].x and v[?].y coordinates on the screen. Therefore, I could probably call the 2D polygon routines anyway. Nick Anderson email: andersNOSPAMPLEASEnd AT hotmNOSPAMPLEASEail DOT com web: http://www.fortunecity.com/skyscraper/online/263 P.S. My landscape program(formerly "The Planet Project") used GCOL(interpolated) shading. Whenever I set up an RGB table to do GRGB gouraud shading, I ended up with a completely blue landscape. Any chance of perhaps some more tutorials about RGB use in 3D routines? > Shawn Hargreaves.