350 likes | 590 Views
CS32310 - Lecture 01. Reyer Zwiggelaar rrz@aber.ac.uk. In This Lecture. Three-dimensional objects Representation and modelling Polygons. Representation. Representation. Representation. Representation. Representation. General approach unsolved Machine or renderer Polygon mesh
E N D
CS32310 - Lecture 01 Reyer Zwiggelaar rrz@aber.ac.uk
In This Lecture • Three-dimensional objects • Representation and modelling • Polygons
Representation • General approach unsolved • Machine or renderer • Polygon mesh • User or user interface • Bi-cubic parametric patches • Constructive solid geometry • Conversion to polygon mesh for rendering
Representation • Polygonal • Constructive solid geometry (CSG) • Spatial subdivision techniques • Implicit representation • Bi-cubic parametric patches • Lectures 2 and 3
Representation • Polygonal • Constructive solid geometry (CSG) • Spatial subdivision techniques • Implicit representation
Polygonal Representation http://www.infosun.fmi.uni-passau.de/st/staff/breu/studium/cg/teapot.html
Polygonal Representation • Classic representation in 3D graphics • Linked list of 3D coordinates • Polygon vertices • Object => surfaces => polygons => edges/vertices
Polygonal Representation Object => surfaces => polygons => edges/vertices
Polygon Mesh Attributes • Polygon attributes • Triangular or not • Area • Normal to the plane • Plane coefficients: Ax+By+Cz+D=0 • Convex or not • Containing holes or not
Polygon Mesh Attributes • Edge attributes • Length • Between two polygons or two surfaces • Polygons on each side
Polygon Mesh Attributes • Vertex attributes • Polygons that contribute to it • Normal: average of polygons that contribute to it • Texture coordinates
Creating Polygonal Objects • 3D digitiser or manual approach • Utah beetle (1974) • Laser ranger • Mathematical description • Computer Aided Design • Sweeping • Rotational invariant • Allows user interaction
Representation • Polygonal • Constructive solid geometry (CSG) • Spatial subdivision techniques • Implicit representation
CSG Representation • User representation • Needs conversion (to polygon mesh) • Building with primitives • Spheres, cones, cylinders, rectangles • Using linear transformations • Combined using Boolean set operators
CSG Representation Subtract Cylinder Union Block 1 Block 2
Representation • Polygonal • Constructive solid geometry (CSG) • Spatial subdivision techniques • Implicit representation
Space Subdivision Representation • Basis element is a voxel • 3D version of pixel in an image • Trade-off between storage and accuracy
Organising Voxel Data • Octree (3D) • Quadtree (2D) • Binary space partitioning (BSP) tree
Quadtree e r b e c r c e b b c e b e b c b c e c r r c r c r c e
BSP Tree y = 1023 3 4 y < 512 y >= 512 1 2 y = 0 x = 1023 1 2 3 4 x = 0 Quadtree x < 512 x >= 512 x < 512 x >= 512 1 2 3 4 BSP tree
Representation • Polygonal • Constructive solid geometry (CSG) • Spatial subdivision techniques • Implicit representation
Implicit Representation • Simple objects • Spheres • Bounding Volumes
Scene Management • Number of polygons versus field of view • Few levels • Details appear and disappear • Bi-cubic parametric patches • Detail can be scene related and gradual • Lectures 2 and 3
In This Lecture • Three-dimensional objects • Representation and modelling • Polygons
In The Next Lecture • Three-dimensional objects • Bezier curves and patches