Cad Unit-3 PDF
Cad Unit-3 PDF
6 3D Graphics
1
f
~ fA/4 ~~ :--==
1
"• 6. 1. INTRODUCTION:THREE DIMENSIONAL
OBJECT REPRESENTATIONS
❖ Introduction: Three ~imensional
Object Representations rI'hn'e dimensional graphics scenes contain many
❖ Polygo n Surfaces and Mesh chffr.,rt>nt kinds of objects , for exnmple . trees . glass.
representation rock . water. etc . There is not any single method that
❖ Quadric, Superquadric Surfaces can lw used to describe objects t.hnt will include all
and Blobby Objects ehar:1etPristics of these <lifferent materials .
❖ Geometric Modeling • Polygon :rn<l quadric surfaces provide prPcise
❖ Solid Modeling Techniques dc>scriptions for simple Euclidean objects such
❖ Colour Models
as pol~1 lwdrons and Pllipsoids .
• Spline surfaces and construction techniques
an' uspful for designing curved surfaces such
as :ri.rernft wings . gears . etc .
• Procl'dural methods such as fractal
constructions and particle systems allow us
to givl-' ncc urnte reprt>sentations for clouds.
clumps of grass and ot.lwr natural objects .
• Physically bnsed modeling methods using
systems of interacting forces can lw ust>d to
describe tlw non-rigid behavior.
• Octree encodings nre used to rPprPsPnt
internal features of obiPrts : such :1s t hosL'
obtain0d from nwdicnl CT imng1:'s .
• lsosurfm·r displays. vnlunlt' rendl'r1ngs and
other visu:di zat.ion techniques are npplil d 1
109
• .. t""t Aided Design
\ h\_\ f undamt>ntals ,,1 l,ornpu o ,
p,,h'i:,;,
. ~ , ns. Th\s sirnplifo,s nnd spPl'ds
. lup . the
h 1· surfnct' rrnd<'nng
~. 'T"h nnd di APl·,lyti or
ul ~tir/'t1
,l(,,
1
.\ H t\w poly~on surfne~s nn) descnh ec wit. 1nt:'nr l l]lHldOns . p ------- ohj,;,,t ·
polyl!t'lH\l n•pn•s~ntat ion of n po I)' h pdron Pl'l' Cist' 1Y d d'i n e ,-; th,, '
~tufoet" ft' nttn·~s l)f nn objl)C't.
1n r'igurt> H.1. tlw surfm't' of a l'~' lindcr is n~pn'SPnted as a
polygon mt'sh . Bl:'CtHlSt' tlw wirefrnnw mod elling C[ll1 lw d isplnyed
quiekly to giYl' n gc1wr:1l indication of t.hP snrfocc polygons . Th is
simplifies ~1nd sp~ed up the surface rendering and display of objects.
All the polygon surfaces nre described with linear e quation s . The
polygonal representation of a polyhedron precis<:' ly <l cfi n es th<'
surfact' feat ures of an object . · ,
In Fig. 6. L the su~-face of a cylinder is represented us a poly gon
mes.h· . BecRnse th e• \". ireframe modellino-t-- can be displ"y
1
u od
\;, q ll 1· C k Iy f.1
t o giYe a gener al indication of tlw surface . 9 · 6.1. Wire frame
. d8:n~cture: the_refore such r epresentRtions are common in design representation of a
an solid- modehng applications cylin_der with hidden
o · line removed
. p 1g
ne type of polygon mesh is the triangle, strip cas s h own 111 · . 6.2.
Fig . 6.2.
In ge n e ral, for a triangle strip :
' . n - 2= num b er of. conn t · .
1 his r1 ives _ ec ing tnan°les
o n - number f' . b
'f h ' . . o vertices
e ex ampl e of triangle
. mesh t 0 generate an · , . . .
A polygon s urfac e 1s defined b . , image 1s shown 1n Fig. 6 .3.
tables which can he later used for dis;\ set of vertices . All the information is placed in
data table are categorized into geomet~.~~ng a nd manipulation of objects . These polygon
· nc tables a. n d attnbute
. . • table category. T h e d a. ta.
►
. _ _ __ 30 Graphics // I( '.1 ' 1
(a) Image generated by triangle mesh (b) Image generated by quadrilateral mesh
Fig . 6.3.
Attribute information of an object includes
parameters specifying the degree of transparency of
the obj ect and its texture characteristics .
To store geometric data a vertex table , an edge
table and a polygon table are created having the
fo llowing information :
• In the vertex table the coordinate values of each
vertex are stored .
• The edge table contains pointers back to the
vertex table to identify the vertices for each v2 E v 4 Es
polygon edge.
• The polygon table contains pointers back to the
. e~ge table to identify the edges for each polygon. Fig. 6 .4 . A polygon surface
. This 1s expl ained in Fig. 6.4, which shows a polygon
:,ur/ac:e and Fig. 6.5 shows three types of data tables for this polygon.
6 .3 . 1. Quadric Surfaces
These are frequently used objects. Quadric surfaces are describe d with second-degree
equations. The examples of quadric surfaces are spheres, ellipsoids, tori , paraboloidE
and hyperboloids . Spheres and ellipsoids are common elements of graphic scenes.
1. Sphere
• The equation of the sphere is:
x2 + y2 + 22 = r2
y = r cos a cos ~
z = r sin a
2. Ellipsoid: An ellipsoidal surface is described
as an extension for a spherical surface, where the
r a dii in 3 m ut u a lly perpendicular directions can
have uifforent values a s shown in F i g . 6 .5 .
• The equ at ion of ellipsoi d is: .d
F .19 . 6 .5. An el\i pSOI
~I
I
3D Graphics // I\113
v =-- ,. si 11"' 0
l '()~" ()
l
. "
. Fig ul'L' (, .7 ~ht)\\'~ dilll'l'L'11t t'o1·rn ~ ol' su}HH' Pllipsns gonerated wi th differ .
\)l -;- '\ ...->. l • O• ·t .:>.
- nnd ~.O n•~pcctiv<'ly). ent Val t1~s
Fig. 6.7 . Super ellipses with s = .5, 1.0, 1.5, and 2.0 respectively
2 . Super ellipsoid
• The equ ation of super ellipsoid is:
(a) (b)
Fig. 6 .9. Blobby huma n muscle . n
. 0 rc •n1 ~1:1
:-,
11
, Ji 1. y p1 : ,,f ,Jl>j,•ct H u 11 1 IH\ n: p n is!i 11 to d b y malhenwtit:d form with }lt']J) ''
d, II . !I l f l1J J( ' I. ./ l)l) l-J tH'l1 ; 1H:
where
or
Tis some threshold parameter , and a and bare used to adjust the blobbiness of the
object.
,. 6.4, GEOMETRIC MODELING
;:mputer co~patible _mathematical description of the geometry of the object is
called as geometric i:nodehng . The C~D software allows the mathematical description
of the object to be d1splaye~ a_s the image on the monitor of the computer. Computer
aided design attem_p ts to ehm1n~te the ~eed of developing a prototype for testing and
optimizing the design . ?eometri~ modelmg studies computer based representation of
geometry an_d rela_ted 1?form~t10n need~d for supporting various computer based
applications m engineering design, analysis , and manufacturing, and other areas with
similar requirements . This involves the study of data structures , algorithms, and file
formats for creating , representing , communicating, and manipulating geometric
information of physical parts and processes appearing in these applications . A geometric
modeling system can be similarly characterized as an application component responsible
~;'. for creating, inspecting, analyzing and distributing geometrical model [4] . Some of the
~
general requirements of geometric modeling are discussed in the following paragraph.
~ ~~
o e t _. c modeling in three 1mens10ns. a van •
t
rn ethod of geome iI ''"
~(&~
Fig. 6.10. Wire frame model
1
2. Surface Models: Surface
. .fmodels
. areh created
d using
1· points,
h Jines, and p anes A
surface model is unable to 1denti y porn ts t at o not 1e on t e surface and th , f ·
. . . '
the moment of mertia, volume, or sect10ns of the model cannot be obtained. A suf '
"'""
model can be shaded for better visibility. Surface models are used for modeling sur~ ac'.
· · F" 6 11 h f' acei
o engmeermg components. 1gure . s ows a sur a ce model.
f
rr;prr·sent
, ·
unam_h1guous im e
f' s are th e most preferr ed form of CAD 1110'..le
1,·zr
°
tlw· m<1m en t f' ·rne rtia m· ,age O a co m ponent. A solid model ca n be use d to an'"''
,,xa mpl<, of" solid mo<lei.ass, volu me, sections of t he model, etc. Figure 6.12 sh'"
A
Fig. 6.12. Solid model
Solid modeling sometimes is also referred as volume modeling. A solid model can
be used to generate cross-sectional views to know internal details of the object. The
solid models can be used to calculate mass, inertia, volume, centre of gravity and other
properties of the object.
Solid models are mathematical models of objects in the real world that satisfy specific
properties, listed below .
, Bounded: The boundary must limit and contain the interior of the solid .
, Homogeneously three-dimensional: No dangling edges or faces should be
present so that the boundary is always in contact with the interior of the solid.
• Finite: The solid mu st be finite in size.
\ . '.T>~, -
,-~~--· 1'L ~-:. : .: -:.-:-
Set P
f computer Aided Design
8 I // Fundament~ls _o -- :::::=-::::::- -
_::-:::::_:::::::::.--1' d models can be created from the
0 erations: New so l .
h fOllowing operations.
. l lVes or
other
prirn •t'
solid models by t e I'd are J'oined and the common volume of one of th .
. (U)· Two so 1 s h d d · e Pr1 ·
• Union · . h sulting solid. Full s a e area 1n Fig. 6.13 ( tn1tive
is neglected m t e r~. t . a) and (b;
shows union of two o JeC s.
A B
A-B
k;;~·.,.; *}~
AnB
-> ITT
(b) Intersection of two 3D objects A and B
Fig. 6.15.
The most common primitive solids found in a CAD program are: block, cylinder,
cone, sphere, wedge, and torus .
CSG Tree: CSG tree stores the history of applying boolean operations on the primitives:
• Stores in a binary tree format.
• The outer leaf nodes of tree represent the primitives.
• The interior nodes represent the boolean operations performed.
Figure 6.16 and 6.17 shows a CSG tree.
----,_--
I Union l
I
R
L__J
Intersection
I
I
C
\
'J
\
Fig. 6.16. CSG set operations on 2D objects: Example of CSG Tree
t Aided Design
·12~ \ // Fundamentals of Cor~pu er ..:. . -:- :._..:::::=
__:::=_:;_~_::'=_ ::::==:3::::::=::_:=:.. -~·:~:::: ·-:.~
Half Spaces:
• These are unbounded geometric entities.
Co:
• Each one of them divides the representation space into infinite portions, oni 0~
filled with material and the other empty.
• Surfaces can be considered half-space boundaries and half spaces can be considerei
directed surfaces.
• An object is defined by the volume space contained within the defined boundar;
of the object.
• By specifying different boundary surface, we can have any half-spaces.
• The most commonly used half-spaces are planar, cylindrical, spherical, conical
and toroidal.
• By combining half-spaces (using Boolean operations) in a building block fashion.
various solids can be constructed.
Cylindrical half space is given as follows and is shown in Fig. 6.18: I l
H = {(x, y , z) : x2 + y2 < R2} Di,,
,,
I '
\
llata&1
--
__ _ _ - - · - - · - - _ _ ______ 3D Graphics // I 121 I
----=.:..::.-::·:::-~--:::.::::::..-:.:-_;:-:::::.~--·::.-::: ·- .. ·___ ; -: \.
.: :.. -:.:.:::::.--:-::::::-.::...--:::::=.=.. -:::..:- .-
I
I
I
fig. 6.20. A conical half space Fig. 6.21 . A toroidal half space \
Constructing solids with half spaces: Figure 6.22 shows solid construction with
Pont
half spaces:
:neol
pam.
1rical.
0
Fig. 6.22. Solid construction with half spaces
Advantages of half spaces:
blocl~ • The main advantage is its conciseness of representation compared to other modeling
schemes.
l: • It is the lowest level representation available for modeling a solid object.
Disadvantages of Half spaces:
• The representation can lead to unbounded solid models as it depend on user
manipulation of half spaces.
• The modeling scheme is cumbersome for ordinary users/designers .
65 2
· · · Boundary Representation (B-Rep) Scheme
.-,/. f 'rhis scheme is based on the concept that a physical object is bounded by a set of
vate~. A solid model is created by combining primitives such as faces and cont ains
· , e cl ges, loops , and bodies. These prim
ert1ct11:, · ·ttlves
· are d'1scusse d a s f o11 ows:
• Vertex: A point i n space.
' 1'~tlge: /\. finite, no-inter sectin g space curve hounded by two Vl't'ticet, tha t are
not ni)t()ssn r ily diHtinct.
'\,2;l,\ II--
F~ ~entals of Computer Aided Design _:.===;===== :------
- - - - - -- .. - -
.... - -
• Face: A finite connected, non-self-intersecting. r egion of a ct 08 , d . 1
e or11J
bounded by one or more loops. . lH.t!d lll!tf
• Loop: An ordered alternating sequence of v~rticos and edges. A
00
:ir. l
non-self~intersecting closed space curve, wh~ch muy h<i a boundu~ P_ d\Jfin\',. \
• Body: Entity that has faces, edges and vertices . A minimum bod Y.(JI Q fuc~ 1
113
·
This scheme can model a variety of so l1'd s d epcn d"ing on t h o primitive
·
8
yf up0int ·
.d . d I .
cu1~ved, or sculptured)_. There_ are two _types O f ~o l i ~10 · e s :in ur aces (
thiH scheme: Po\ Plan11
solids. and curved solids, which are discussed 1n the following paragraphs. YheQr~I
(i) Polyhedral Solids: Polyhedral solids consis t of Atraight e dges
. · ft
cylinchical surface: box, wedge, com b inat10n o wo or more non-cylindrical bod· nfir.
' e.g a
Polvhedral
~ · · solids can have blind or through holes, . an d two or three-dimen s1onal . les,e~
f
with no dangling edges. A valid polyhedral abides by the Euler's equation h_attg_
' w tch
given as follows : ~
F - E + V - L = 2 (B - G)
where, F= Face
E = Edge
V= Vertices
L = Inner Loop
B = Bodies
G = Genus (Through holes) F =6 \
A simple polyhedral has no holes ; each face is bounde d E=12 \
V::8 i
by a single set of connected edges (bounded by one loop of
edges) . Euler's equation for a simple polyhe dral can b e
reduced to: F-E + V= 2. The example of simple polyhedral
is shown in Fig. 6.23, number of faces, edges and vertices Fig. 6.23. Box (Simple
polyhedral)
are also shown along with this Fig. 6.23 .
(ii) Curved solid: A curved solid is similar to a polyhedral object but it has curve
faces and edges. Spheres and cylinders are examples of curved solids. The applicati~
of Euler's equation to spheres and cylinders is shown explained with the help of Fit
6 .24 and Fig. 6.25.
--- tational sweep, a closed sketch 1s rotated around an axis. The generated model
In ro . R . 1 .
. lways axisymmetr1c. otat1ona sweep 1s shown in Fig. 6. 27 .
i. 1s a
' I
.,., ,;.,o.,
I;
~ Sweep direction
a .,., ., .,
Fig. 6.26. Linear sweep - Creating a box Fig. 6.27. Rotational sweep
by sweeping a rectangle
a, In addition to the two sweeps described above, a model can also be created by a
non-linear sweep. In this type of sweep, a closed sketch is sweeped along a non-linear
path.
6
4
X
4 5
z
(a) Voxel representation (b) Octree representation
Fig. 6.28.
' 6•5,S F t
· ea ure Based, Parametric
· ModeIs
, Feature-hased parametric solid modeling system represents the recent advance of
computer geometric
' modeling. It is used as t h e 1,oun
. da t·10n of' mo dern C1\ D svstems,
."
e.g Pr0/EN • f' t · d lir1g are d1scu::;sed
' b ·, GlNEER etc. Some important propertrns o parame r1c mo e ·
,
1
elow: '
C mputer Aided Design
1? 4; Fundamentals of O' • .- --- --;:_- ___
-· -· - -- ---
.':✓, j· -- • ~ · --
I I - - -- __ _ _ .__.
oo·tf.i
ieQ,l
,tro~
l~e~
Fig. 6.30. CMYK colour model: A subtractive model
ire(i
11•. In the RGB model, the convergence of the three primary additive colours produces
~JD: white. In the CMYK model, the conv~rgence of the three primary subtractive colours
produces black. Figure 6.31 shows unit cube representation for both colour schemes.
Blue = (0,0,1)
- - - - - - - - Cyan=(0,1,1)
Fig. 6.31 . Unit cube representation for RGB and CMYK models
Three dimensional graphics scenes contain many different kinds of objects, for example,
trees, glass, rock, water, etc . There is not any single method that can be used to describe objects
~hat will include all characteristics of these different materials. Polygon surfaces provide precise
escriptions for simple Euclidean objects such as polyhedrons and ellipsoids. It is one of the
most commonly used boundary representation techniques . A three dimensional graphics object
Y :an he.represented by a set of surface polygons. This simplifies and speeds up the surface rendering
~hd dir.; pla y of objects. All the polygon surfaces are described with linear equations . Quadric
••Urface d . . •
<·II' .8 arc . ef:lcnhed with second-degree equat10ns. The examples of quadric surfaces are spheres,
1
; ,_1PH <~JdA, tori, paraboloids and hyperboloids. Spheres and ellipsoids are common ele ments of
~·: tt!Jhic Ht<:n<~H. These ure the objects which do not maintain n fixed s hape. and usually change
l(: Jr Hba
r•r.• Pl! an<1 surface c:harncteri 8tics und er motwn· or w l1en c lose to some ot11er o1)Jects.
· l"'•or
· ,,unpl<•· rnc1I <!cu I ar Hlructuros, wutPr drople t~ , mo I tin~
· '- ·
ouJects · h umun l)O d y
, muse 1e :,; I1apes m
f computer Aided Design
~II Fund•_'."!~~~ ----= __ _
- --.- --- -- f ed to as blobby objects due to certain degree of th .
etr. Tl1ese .
obJerts are
h
re err • · b d d
cept that a physical obJect is oun e by a set off
e1r f1llidit~,, ,,
· . based on t e con . aces A. y~ 1
d1rme l t:i b' ·ncr primitives such as faces and con tams vertices, edges 1· solid ~ ·rep \
, ated by com uu " . f 1f . , ool\ ••1od I .
n e, . 1.d model The method 1s use u or creating 2 ½2 d' t-S, and b e is
--. , ing can create a so 1 · , . - llll . od·
;;::e: ener~ted models are axisymmetric and have umform thickness _(i.e., ext::1on lllod~;s. i
.
The space 1s por 1one
t· d 1·11to 1·ecions
o
called cells, and those cells are filled . h ed lllod s_
. . . W1t els)
·t te the ob3'ect being represented. Decompos1t10ns mto regula r·tnateriaj .
t herefore const : u . r, lXed-si anu
are called spatial enumerations. zeceJJs
f
Review Questions ._ ·_- -, ·==='='='~-"::--=::,-?---~~, ]
l. \Nbat do you mean by polygon surfaces. Draw one polygon surface. -----~ I
2.. Distinguish between quadric and superquadric surfaces.
3. Explain blobby objects with help of diagrams.
4.. Describe constructive solid geometry with suitable examples.
;:,. Explain boundary representation technique with examples.
6. 'i\nat do you mean by colour models. Explain different types of colour models.
.,
; . Explain help spaces. How this technique is different from constructive solid geometry. \