Introduction to Computer Graphics Knowledge basic concepts 2D and 3D computer graphics
1 Introduction 2 Basic math 3 2D transformations 4 3D transformations 5 Viewing 6 Primitives 7 Geometry 8 Shading 9 Splines 10 Texture 11 Hidden surfaces 12 Ray-tracing Donald Hearn, M. Pauline Baker, Warren Carithers. Computer Graphics with OpenGL, 4 th edition, Pearson Prentice Hall, paperback
Why computer graphics? Visual system offers: Parallel input Parallel processing Computer graphics: ideal for humancomputer communication
Applications Graphs and charts Computer-Aided Design Virtual Reality Data Visualization Education and training Computer Art Movies Games Graphical User Interfaces
Business graphics
Computer-Aided Design AutoDesk IAME 2-stroke race kart engine
Computer Aided Design 8
Scientific Visualisation To view below and above our visual range 9
expression Movies depth of field fracture water motion reflection hair
Hardware Fast development History Now: Graphics Processing Unit (GPU), LCD-screen
Generating graphics Special-purpose programs Photoshop, Powerpoint, AutoCAD, StudioMax, Maya, Blender, PovRay, General graphics libraries and standards Windows API, OpenGL, Direct3D,
Python modeller for POV-Ray
Blender
Beyond the laptop screen Microsoft Surface Apple ipad
Beyond the laptop screen Reality Deck Stony Brook University 416 2560 1440 27 monitors
Beyond the laptop screen Oculus Rift
CG standards Set of graphics functions, to be called from programming language Access to and abstract from hardware Standardization Fortran, Pascal, Display Input dev. C, C++, Java, Delphi, Display CG API Drivers 1975 2000 Input dev.
PHIGS -OpenGL Programmer's Hierarchical Interactive Graphics System) : an API standard for rendering 3D computer graphics, 3D graphics standard for the 1980s through the early 1990s., A combination of features : the rise of OpenGL the most popular professional 3D API of the mid to late 1990s.
Software standards GKS (Graphical Kernel System), PHIGS(Programmer's Hierarchical Interactive Graphics System), PHIGS+ (1980-) GL (Graphics Library, SGI) OpenGL (early 1990s) Direct3D (MS), Java3D, VRML,
OpenGL 3D (and 2D) Fast Hardware, language, OS, company independent OpenGL architecture review board Broad support Standard graphics terminology
Functions Graphics Output Primitives Line, polygon, sphere, Attributes Color, line width, texture, Geometric transformations Modeling, Viewing Shading and illumination Input functions
More info on OpenGL http://www.opengl.org, http://www.opengl.org/sdk/docs/man2/ The Red Book: http://www.glprogramming.com/red/ Many other web-sites
Schematic Model Display Image interaction User
Schematic Computer Graphics Model Image Pattern Recognition Image Processing
From model to image Model World View NDC Display Graphics pipeline Coordinates and transformations
From model to image Model World View NDC Display Cylinder: x 2 + y 2 = r 2 0 z h Local or modeling coordinates Geometric modeling
From model to image Model World View NDC Display Position cylinders in scene: World coordinates
From model to image Model World View NDC Display Look at cylinders, project on virtual screen Viewing coordinates Visible surfaces, shading
From model to image Model World View NDC Display Display: 1 Normalized Device Coordinates 0 1
From model to image Model World View NDC Display 0 1024 Display on screen: Device Coordinates 768 Interaction
Geometry Stage Modeling: shapes Model Transformation Transformation: viewing Hidden Surface Elimination Shading: reflection and lighting Rasterization Stage 32
Rasterization Stage Geometry Stage Rasterization and Sampling Texture Mapping Image Composition Intensity and Colour Quantization Framebuffer/Display
An example thro the pipeline The scene we are trying to represent: Images courtesy of Picture Inc.
Preparing Shape Models Designed by polygons, parametric curves/surfaces, implicit surfaces and etc. Defined in its own coordinate system
Model Transformation Objects put into the scene by applying translation, scaling and rotation Linear transformation called homogeneous transformation is used The location of all the vertices are updated by this transformation
Perspective Projection We want to create a picture of the scene viewed from the camera We apply a perspective transformation to convert the 3D coordinates to 2D coordinates of the screen Objects far away appear smaller, closer objects appear bigger
Hidden Surface Removal Objects occluded by other objects must not be drawn
Rasterization Converts the vertex information output by the geometry pipeline into pixel information needed by the video display Aliasing: distortion artifacts produced when representing a high-resolution signal at a lower resolution. Anti-aliasing : technique to remove aliasing
Anti-aliasing Aliased polygons (jagged edges) Anti-aliased polygons