Dark Bit Factory & Gravity

ARCHIVE => Archive => Useful links => Topic started by: rdc on February 28, 2009

Title: Black Art of 3D Game Programming
Post by: rdc on February 28, 2009
I was over at my local used book yesterday and found a copy of The Black Art of 3D Game Programming by Andre Lamothe. I remember when this book first came out (1995) and being an old fart I had to get it. Heck, it was only a $1.00 US. I have been going back through it, and I have to say that it still a great book. You actually build a 3D engine from scratch (there was no OpenGL or DirectX back then, at least not on PCs). It's DOS (3.11) based of course, so the graphics aren't what they are today, but all the math and concepts could be used in any modern language. The language they use is C and fairly standard C at that. Most would translate today except for all the Mode 13h stuff.

The cool part is, that the book is now online (http://www.dpfiles.com/dpfileswiki/index.php?title=Black_Art_of_3D_Game_Programming:_Writing_Your_Own_High-Speed_3D_Polygon_Video_Games_in_C). If you want to get the scoop on building a 3D engine without all the shmanzy-dancy DX or OGL, check it out. :) Seriously though, the math and concepts info the book would help with OGL since Andre goes into projects, transformations, how to build polygons, etc. Cool stuff. I am going to try and get a grasp of this stuff so I can do some old school 3D demos. Something besides Chladni demos. :)
Title: Re: Black Art of 3D Game Programming
Post by: Jim on February 28, 2009
I'd buy that for a dollar too.  Good book, and brilliant to see it online.

Jim
Title: Re: Black Art of 3D Game Programming
Post by: Pixel_Outlaw on February 28, 2009
WOW this is great. Have some karma.
Title: Re: Black Art of 3D Game Programming
Post by: Rbz on March 01, 2009
K++;   :)
Title: Re: Black Art of 3D Game Programming
Post by: Clyde on March 01, 2009
Coool stuff dude, thanks for the info :)
Title: Re: Black Art of 3D Game Programming
Post by: benny! on March 01, 2009
Yeah ... that's somehow oldschoolish. Nice finding!
Title: Re: Black Art of 3D Game Programming
Post by: rdc on March 01, 2009
Thanks folks. I thought it might interest a group like this.
Title: Re: Black Art of 3D Game Programming
Post by: Clyde on March 02, 2009
How would the Mode 13h stuff translate into for more modern setups?
Title: Re: Black Art of 3D Game Programming
Post by: rdc on March 02, 2009
I have uploaded the source files to my Windows Live Skydrive (http://cid-bcdbe1b9697ff5dc.skydrive.live.com/self.aspx/.Public/Black%7C_Art%7C_3D). I have also included the NCAD program that is used to create the PLG files. These are DOS programs but they seem to run under Dosbox.
Title: Re: Black Art of 3D Game Programming
Post by: rdc on March 02, 2009
How would the Mode 13h stuff translate into for more modern setups?

Mode 13h is the VGA mode 320x200, 256 colors. In FreeBasic, for example, you would use the screen statement and set the resolution to what you want. To draw the graphics, you would need to replace the drawing routines with FB compatible routines. To do a fast draw to the screen you could use code like this:

Code: [Select]
Const scrw = 640

sub DrawPixel (x As Integer, y As Integer, clr As UInteger)
  Dim buffer As UInteger Ptr = ScreenPtr()

  Poke UInteger, buffer + (x + y * scrw), clr
End sub

Screen 18, 32

ScreenLock
For x As Integer = 0 To 100
  For y As Integer = 0 To 100
    DrawPixel x, y, RGB(255, 255, 255)
  Next
Next
ScreenUnlock
Sleep

You could also use TinyPTC or SDL as well.
Title: Re: Black Art of 3D Game Programming
Post by: Shockwave on March 02, 2009
That is a great find.

Have some karma Rick. I'll be reading that for sure.
Title: Re: Black Art of 3D Game Programming
Post by: rdc on March 02, 2009
Thanks man. I am going to port the examples over to FB and I'll post them in the FB section as I do them. May be helpful for some, including me. :)
Title: Re: Black Art of 3D Game Programming
Post by: Moroboshisan on April 01, 2009
I have uploaded the source files to my Windows Live Skydrive (http://cid-bcdbe1b9697ff5dc.skydrive.live.com/self.aspx/.Public/Black%7C_Art%7C_3D). I have also included the NCAD program that is used to create the PLG files. These are DOS programs but they seem to run under Dosbox.


many thanks for that!! I just received my .50c book purchased on ebay but i'm really disappointed since it is missing the bundled CD  :o ... Is it the archive you uploaded in your skydrive the full content or just an excerpt? If your archive is an excerpt May I ask you to post anywhere (rapidshare or something like that; p2p and similars are not an option i'm considering) the full content? I would be happy to have the full book + CD-Rom in my library.

Thank you in advance.  ;D
Title: Re: Black Art of 3D Game Programming
Post by: rdc on April 01, 2009
That is everything that was on the disc except for the shareware dos games folder. I figured no one needed that in the archive.

Title: Re: Black Art of 3D Game Programming
Post by: Moroboshisan on April 01, 2009
That is everything that was on the disc
ok, 10x! :D just what my ears wanted to hear!

I figured no one needed that in the archive.
you're right.... sooooooooooooo damned right! ;-)