modeling 3d objects with polygons - virginia techcs4204/lectures/polygonal... · 2008. 3. 26. ·...

16
Modeling 3D objects with polygons

Upload: others

Post on 23-Feb-2021

9 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: Modeling 3D objects with polygons - Virginia Techcs4204/lectures/polygonal... · 2008. 3. 26. · Most 3D graphics algorithms assume a polygon-based scene Common polygon algorithms

1

Modeling 3D objects withpolygons

Page 2: Modeling 3D objects with polygons - Virginia Techcs4204/lectures/polygonal... · 2008. 3. 26. · Most 3D graphics algorithms assume a polygon-based scene Common polygon algorithms

2

(C) Doug Bowman, Virginia Tech, 2008 2

Why polygons? Simple mathematical description Standard 3D graphics primitive All graphics packages optimized for polygon

throughput Most 3D graphics algorithms assume a

polygon-based scene Common polygon algorithms implemented in

hardware In the end, everything (well, almost

everything) is a polygon

Page 3: Modeling 3D objects with polygons - Virginia Techcs4204/lectures/polygonal... · 2008. 3. 26. · Most 3D graphics algorithms assume a polygon-based scene Common polygon algorithms

3

(C) Doug Bowman, Virginia Tech, 2008 3

Terminology

Polygon soup: ageneral set ofunstructured polygonsused to define a scene

Polygonal mesh: a setof connected polygonsthat together form asurface

Page 4: Modeling 3D objects with polygons - Virginia Techcs4204/lectures/polygonal... · 2008. 3. 26. · Most 3D graphics algorithms assume a polygon-based scene Common polygon algorithms

4

(C) Doug Bowman, Virginia Tech, 2008 4

More terminology

3D polygonal model: a 3D object madeup entirely of polygons

3D polygonal modeling: the process ofbuilding a 3D object by specifying thepolygons that make up that object NOTE: you can build a 3D polygonal model

without using 3D polygonal modeling!

Page 5: Modeling 3D objects with polygons - Virginia Techcs4204/lectures/polygonal... · 2008. 3. 26. · Most 3D graphics algorithms assume a polygon-based scene Common polygon algorithms

5

(C) Doug Bowman, Virginia Tech, 2008 5

Methods of creating polygonalmeshes

Build mesh by hand

Page 6: Modeling 3D objects with polygons - Virginia Techcs4204/lectures/polygonal... · 2008. 3. 26. · Most 3D graphics algorithms assume a polygon-based scene Common polygon algorithms

6

(C) Doug Bowman, Virginia Tech, 2008 6

Methods of creating polygonalmeshes

Tesselate atheoretical smoothsurface Tesselation: the

process of creating apolygonalapproximation froma smooth surface

Page 7: Modeling 3D objects with polygons - Virginia Techcs4204/lectures/polygonal... · 2008. 3. 26. · Most 3D graphics algorithms assume a polygon-based scene Common polygon algorithms

7

(C) Doug Bowman, Virginia Tech, 2008 7

Methods of creating polygonalmeshes

Extrude a 2Dpolygon, curve,etc. Extrusion: the

process of movinga 2D cross-sectionthrough space tocreate a 3D solid

Page 8: Modeling 3D objects with polygons - Virginia Techcs4204/lectures/polygonal... · 2008. 3. 26. · Most 3D graphics algorithms assume a polygon-based scene Common polygon algorithms

8

(C) Doug Bowman, Virginia Tech, 2008 8

Methods of creating polygonalmeshes

Revolve/sweep a 2Dpolygon or curve Revolution: the

process of rotating a2D cross-section aboutan axis to create a 3Dsolid

Page 9: Modeling 3D objects with polygons - Virginia Techcs4204/lectures/polygonal... · 2008. 3. 26. · Most 3D graphics algorithms assume a polygon-based scene Common polygon algorithms

9

(C) Doug Bowman, Virginia Tech, 2008 9

Problems with polygonalmodels

They approximate smoothly curvingsurfaces

Tradeoff between realism and efficiency Lots of polygons: good approximation,

slow to process Few polygons: fast processing, poor

approximation

Page 10: Modeling 3D objects with polygons - Virginia Techcs4204/lectures/polygonal... · 2008. 3. 26. · Most 3D graphics algorithms assume a polygon-based scene Common polygon algorithms

10

(C) Doug Bowman, Virginia Tech, 2008 10

Polygonal simplification Decrease the number of polygons without

sacrificing visual quality (meet polygonbudget)

30944 triangles 2502 triangles 621 triangles 251 triangles

Page 11: Modeling 3D objects with polygons - Virginia Techcs4204/lectures/polygonal... · 2008. 3. 26. · Most 3D graphics algorithms assume a polygon-based scene Common polygon algorithms

11

(C) Doug Bowman, Virginia Tech, 2008 11

Level of detail (LOD)techniques

LOD: change thecomplexity of themodel/imagedynamically tomaintain real-timeperformance

Ex: use simplifiedmodels when objectsare at a great distance

“Popping” problem

Page 12: Modeling 3D objects with polygons - Virginia Techcs4204/lectures/polygonal... · 2008. 3. 26. · Most 3D graphics algorithms assume a polygon-based scene Common polygon algorithms

12

(C) Doug Bowman, Virginia Tech, 2008 12

Texture substitution Textures

(“imposters”) cancause objects toappear much moredetailed than theyactually are

Problem: when theuser is close

Page 13: Modeling 3D objects with polygons - Virginia Techcs4204/lectures/polygonal... · 2008. 3. 26. · Most 3D graphics algorithms assume a polygon-based scene Common polygon algorithms

13

(C) Doug Bowman, Virginia Tech, 2008 13

Rendering polygonal meshes Simply use traditional raster graphics

techniques Proper lighting depends on proper

normals Face normal: the normal to the plane in which

a polygon lies Vertex normal: the normal to the underlying

surface (being approximated by a polygonalmesh) at a particular vertex

Page 14: Modeling 3D objects with polygons - Virginia Techcs4204/lectures/polygonal... · 2008. 3. 26. · Most 3D graphics algorithms assume a polygon-based scene Common polygon algorithms

14

(C) Doug Bowman, Virginia Tech, 2008 14

Face normals vs. vertexnormals

Page 15: Modeling 3D objects with polygons - Virginia Techcs4204/lectures/polygonal... · 2008. 3. 26. · Most 3D graphics algorithms assume a polygon-based scene Common polygon algorithms

15

(C) Doug Bowman, Virginia Tech, 2008 15

Practical polygonal modeling

Modeling tools 3D Studio Max Maya AutoCAD …

File formats OBJ, DXF, 3DS, FLT, DWG, …

Page 16: Modeling 3D objects with polygons - Virginia Techcs4204/lectures/polygonal... · 2008. 3. 26. · Most 3D graphics algorithms assume a polygon-based scene Common polygon algorithms

16

(C) Doug Bowman, Virginia Tech, 2008 16

Alternatives to polygonalmodeling As we noted, almost everything is a polygon

eventually, but the modeling process doesnot have to be based on polygons

Instead, we can model objects using smoothhigher-order surfaces, and only convert topolygons in order to render

Also, we can model volumes instead ofsurfaces

Next: modeling with curves/surfaces