АвтоАвтоматизацияАрхитектураАстрономияАудитБиологияБухгалтерияВоенное делоГенетикаГеографияГеологияГосударствоДомДругоеЖурналистика и СМИИзобретательствоИностранные языкиИнформатикаИскусствоИсторияКомпьютерыКулинарияКультураЛексикологияЛитератураЛогикаМаркетингМатематикаМашиностроениеМедицинаМенеджментМеталлы и СваркаМеханикаМузыкаНаселениеОбразованиеОхрана безопасности жизниОхрана ТрудаПедагогикаПолитикаПравоПриборостроениеПрограммированиеПроизводствоПромышленностьПсихологияРадиоРегилияСвязьСоциологияСпортСтандартизацияСтроительствоТехнологииТорговляТуризмФизикаФизиологияФилософияФинансыХимияХозяйствоЦеннообразованиеЧерчениеЭкологияЭконометрикаЭкономикаЭлектроникаЮриспунденкция

Plane Equations

Читайте также:
  1. Analytic geometry in the plane.
  2. Differential equations
  3. Differential equations of the first and second order. Homogeneous and non-homogeneous linear differential equations
  4. Equations with separable variables
  5. Equations with undetermined coefficients
  6. General Equations for Conic Sections
  7. Matrices. Determinants. Systems of linear equations
  8. Non-homogeneous second-order equations
  9. Solving systems of linear equations on Cramer's rule
  10. Solving systems of linear equations on Gauss's method
  11. Solving systems of linear equations on matrix method

To produce a display of a three-dimensional object, we must process the input data representation for the object through several procedures. These processing steps include transformation of the modeling and world-coordinate descriptions to viewing coordinates, then to device coordinates; identification of visible surfaces; and the application of surface-rendering procedures. For some of these processes, we need information about the spatial orientation of the individual surface components of the object. This information is obtained from the vertex coordinate values and the equations that describe the polygon planes.

The equation for a plane surface can be expressed in the form:

(2.66)

where (x, y, z) is any point on the plane, and the coefficients A, B, C, and D are constants describing the spatla1 properties of the plane. We can obtain the values of A, B, C, and D by solving a set of three plane equations using the coordinate values for three non-collinear points in the plane. For this purpose, we can select three successive polygon vertices, (x1, y1, z1), (x2, y2, z2), and (x3, y3, z3), and solve the following set of simultaneous linear plane equations for the ratios A/D, B/D, and C/D:

(2.67)

The solution for this set of equations is [6]:

(2.68)

As vertex values and other information are entered into the polygon data structure, values for A, B, C and D are computed for each polygon and stored with the other polygon data.

Orientation of a plane surface in space can be described with the normal vector to the plane. This surface normal vector has Cartesian components (A, B, C), where parameters A, B, and C are the plane coefficient calculated in equation 2.68.

Since we are usually deal with polygon surfaces that enclose an object interior, we need to distinguish between the two sides of the surface. The side of the plane that faces the object interior is called the "inside" face, and the visible or outward side is the "outside" face. If polygon vertices are specified in a counterclockwise direction when viewing the outer side of the plane in a right-handed coordinate system, the direction of the normal vector will be from inside to outside.

To determine the components of the normal vector for the shaded surface, we select three of the four vertices along the boundary of the polygon. These points are selected in a counterclockwise direction as we view from outside the cube toward the origin. Coordinates for these vertices, in the order selected, can be used in equation 2.68 to obtain the plane coefficients: A =1, B =0, C =0, D =-1. Thus, the normal vector for this plane is in the direction of the positive x axis.

The elements of the plane normal can also be obtained using a vector cross-product calculation. We again select three vertex positions, V1, V2, and V3, taken in counterclockwise order when viewing the surface from outside to inside in a right-handed Cartesian system. Forming two vectors, one from V1 to V2 and the other from V1 to V3, we calculate N as the vector cross product:

(2.69)

This generates values for the plane parameters A, B, and C. We can then obtain the value for parameter D by substituting these values and the coordinates for one of the polygon vertices in plane equation 2.66 and solving for D. The plane equation can be expressed in vector form using the normal N and the position P of any point in the plane as

(2.70)

We can identify the point as either inside or outside the plane surface according to the sign (negative or positive) of Ax + By + Cz + D:

· if Ax + By + Cz + D < 0, the point (x, y, z) is inside the surface

· if Ax + By + Cz + D > 0, the point (x, y, z) is outside the surface

These inequality tests are valid in a right-handed Cartesian system, provided the plane parameters A, B, C, and D were calculated using vertices selected in a counterclockwise order when viewing the surface in an outside-to-inside direction.


1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | 44 |

Поиск по сайту:



Все материалы представленные на сайте исключительно с целью ознакомления читателями и не преследуют коммерческих целей или нарушение авторских прав. Студалл.Орг (0.005 сек.)