Normal quotes
This commit is contained in:
parent
5e10794a24
commit
18011c595a
352 changed files with 6040 additions and 6040 deletions
18
61-02.md
18
61-02.md
|
|
@ -2,7 +2,7 @@
|
|||
[Previous](61-01.html) [Table of Contents](index.html) [Next](61-03.html)
|
||||
------------------------ --------------------------------- --------------------
|
||||
|
||||
I’ll be working in a left-handed coordinate system, whereby if you wrap
|
||||
I'll be working in a left-handed coordinate system, whereby if you wrap
|
||||
the fingers of your left hand around the z axis with your thumb pointing
|
||||
in the positive z direction, your fingers will curl from the positive x
|
||||
axis to the positive y axis. The positive x axis runs left to right
|
||||
|
|
@ -15,7 +15,7 @@ coordinates onto a viewplane, scaling coordinates according to their z
|
|||
distance from the viewpoint in order to provide proper perspective.
|
||||
*Objectspace* is the coordinate space in which an object is defined,
|
||||
independent of other objects and the world itself. *Worldspace* is the
|
||||
absolute frame of reference for a 3-D world; all objects’ locations and
|
||||
absolute frame of reference for a 3-D world; all objects' locations and
|
||||
orientations are with respect to worldspace, and this is the frame of
|
||||
reference around which the viewpoint and view direction move.
|
||||
*Viewspace* is worldspace as seen from the viewpoint, looking in the
|
||||
|
|
@ -23,16 +23,16 @@ view direction. *Screenspace* is viewspace after perspective projection
|
|||
and scaling to the screen.
|
||||
|
||||
Finally, *transformation* is the process of converting points from one
|
||||
coordinate space into another; in our case, that’ll mean rotating and
|
||||
coordinate space into another; in our case, that'll mean rotating and
|
||||
translating (moving) points from objectspace or worldspace to viewspace.
|
||||
|
||||
For additional information, you might want to check out Foley & van
|
||||
Dam’s *Computer Graphics* (ISBN 0-201-12110-7), or the chapters in this
|
||||
Dam's *Computer Graphics* (ISBN 0-201-12110-7), or the chapters in this
|
||||
book dealing with my X-Sharp 3-D graphics library.
|
||||
|
||||
### The Dot Product {#Heading5}
|
||||
|
||||
Now we’re ready to move on to the dot product. Given two vectors **U** =
|
||||
Now we're ready to move on to the dot product. Given two vectors **U** =
|
||||
[u~1~ u~2~ u~3~] and **V** = [v~1~ v~2~ v~3~], their dot product,
|
||||
denoted by the symbol •, is calculated as:
|
||||
|
||||
|
|
@ -44,7 +44,7 @@ As you can see, the result is a scalar value (a single real-valued
|
|||
number), *not* another vector.
|
||||
|
||||
Now that we know how to calculate a dot product, what does that get us?
|
||||
Not much. The dot product isn’t of much use for graphics until you start
|
||||
Not much. The dot product isn't of much use for graphics until you start
|
||||
thinking of it this way
|
||||
|
||||

|
||||
|
|
@ -52,7 +52,7 @@ thinking of it this way
|
|||
(eq. 3)
|
||||
|
||||
where q is the angle between the two vectors, and the other two terms
|
||||
are the lengths of the vectors, as shown in Figure 61.1. Although it’s
|
||||
are the lengths of the vectors, as shown in Figure 61.1. Although it's
|
||||
not immediately obvious, equation 3 has a wide variety of applications
|
||||
in 3-D graphics.
|
||||
|
||||
|
|
@ -73,7 +73,7 @@ One obvious use of this is to find angles between unit vectors, in
|
|||
conjunction with an inverse cosine function or lookup table. A more
|
||||
useful application in 3-D graphics lies in lighting surfaces, where the
|
||||
cosine of the angle between incident light and the normal (perpendicular
|
||||
vector) of a surface determines the fraction of the light’s full
|
||||
vector) of a surface determines the fraction of the light's full
|
||||
intensity at which the surface is illuminated, as in
|
||||
|
||||

|
||||
|
|
@ -101,7 +101,7 @@ direction vector, as shown in Figure 61.2.
|
|||
|
||||
One question equation 6 begs is where the surface unit normal comes
|
||||
from. One approach is to store the end of a surface normal as an extra
|
||||
data point with each polygon (with the start being some point that’s
|
||||
data point with each polygon (with the start being some point that's
|
||||
already in the polygon), and transform it along with the rest of the
|
||||
points. This has the advantage that if the normal starts out as a unit
|
||||
normal, it will end up that way too, if only rotations and translations
|
||||
|
|
|
|||
Loading…
Reference in a new issue