Fog Creek Software
g
Discussion Board




Picking up math for 3D graphics for a dev

My friend recently accepted an offer to work at a CAD visualization company designing software using 3D graphics.He  comes from a business apps background, with 2 years experience.We were discussing how the transition would be for him.Would it be difficult to pick up the Math needed?

Dev
Thursday, March 4, 2004

Run, don't walk, to your nearest book store, and pick up the classic work "Computer Graphics: Principles and Practice".  This book is all about the theory: you won't find anything about Win32, X11, OSX, or whatever, because they didn't exist when this book was written.  Every serious 3D developer should have this book on their shelf.

Your friend is in for a heck of a shock: the requirements for a typical business application are far, far different than CAD software...

http://www.amazon.com/exec/obidos/ASIN/0201848406

joev
Friday, March 5, 2004

> Would it be difficult to pick up the Math needed?

It depends on what part of the system he's going to be working on -- CAD systems cover a lot of ground these days, and I would be surprised if the underlying graphics subsystem wasn't already implemented. I would imagine that an existing CAD system would use OpenGL or some similar package to do the heavy lifting.

That said, the actual math isn't that hard.  You need to have a solid understanding of the relationship between matrix mathematics and transformations -- scaling, translation, rotation, etc. 

Of course, it could get arbitrarily complicated -- you start thinking about declaring an arbitrary spline, rotating it about an arbitrary axis to describe a lathed part, and then determine its volume and you start talking about some reasonably buff calculus. 

Eric Lippert
Friday, March 5, 2004

I second the motion for: "Computer Graphics: Principles and Practice". 

We used it back in, oh about 1992 or so, as the primary text for a full year of graphics class in college. We built a limited 3D rendering engine over the course of that year.

Most of what's covered will likely already be handled by whatever library/package you'll be using, but unless you know this stuff you'll be really confused at times.

I'd also recommend a full academic year of Linear Algebra at your local college. Linear Algebra usually requires no prerequisites, other than a basic high school Algebra class.

From there, things get quite a bit more complicated. Non-linear 3D surfaces will require some difficult Calculus/Analytic Geometry, set theory, topology and whatnot.

BTW -- this is from someone who writes SQL all day. I may be blowing smoke up your arse! <grin>

Sgt. Sausage
Friday, March 5, 2004

Hold on. Dev, do you mean this guy is just doing "authoring," putting together models using a package?

I think you must, because no-one would hire a bus-app guy to write 3D apps. The learning curve is enormous and takes years, presuming he has the mathematical expertise to start with.

Must be a Manager
Friday, March 5, 2004

Don't go and buy that book! You won't need it. Most of the complex math that used to be dumped on the programmer is now routinely dealt with by graphics libraries you use. Only buy the book if it turns out you need it.

Mr Jack
Friday, March 5, 2004

CG:P&P is a great book, and the math in it is simple enough that anybody with a high school education can understand it.

K
Friday, March 5, 2004

CG: P & P is the classic text.  If your friend is looking for something that holds your hand a bit more, he can try "Mathematics for Computer Graphics Applications" by Mortenson or "Mathematics for 3D Game Programming & Computer Graphics" by Lengyel.  Even though the latter book refers to game programming, almost everything in the text is equally applicable to CAD programs.

A great site for free OpenGL tutorials can be found at:

http://nehe.gamedev.net/

OpenGL is the graphics API that is used by just about every CAD program.  Just writing a simple program which loads a small 3D mesh & spins it around under user control can teach you a lot about 3D graphics.

jeff
Friday, March 5, 2004

Don't waste your time on "Mathematics for Computer Graphics Applications".  I got that book years ago because I wanted to make a little program that would generate a pulsating b-spline surface, spin it around, and do all the transformation/projection and clipping stuff.  It has *terrible* explanations for everything from parametric representations of lines and curves to basic projection operations.  CG:P&P, on the other hand, covers *much* more information and it has you derive all relevant functions/relations from first principles (the treatment of projection alone is worth the price of the book).

K
Friday, March 5, 2004

I really can't recommend CG: Principles and Practice highly enough - it is really the definitive introductory text for computer graphics. It's more clear, and more in-depth than any other introductory book I've seen. Some of the descriptions take a while to pick through, but it will save you loads of grief later on. Yes, some of the math involved is now handled by most libraries (like clipping, for instance), but to be able to efectively use these libraries you need to understand what the library is doing for you. When things go wrong, as they inevitably will, you really, really need the math background to be able to track down the problems.

Full name: Email:
Friday, March 5, 2004

Dev, is this guy being hired to write 3D apps?


Saturday, March 6, 2004

yes

Dev
Saturday, March 6, 2004

I'm pretty much in the same boat :

I'm a Database programmer, and would like
to write 3D apps (for fun, during my spare time)

My maths background is pretty nill, basic arthmetics that's all...
(I've dropped out of school a long time ago) :-(

Could please tell me what subjects in maths I should pick up please ... Any book recommendation ...

I learn best if I can apply (in a snippet of code for instance)
the implementation of a maths formulas for example ....

Any book which teach maths for 3D coding that way ?

3D Newbie too
Sunday, March 7, 2004

*  Recent Topics

*  Fog Creek Home