Welcome To 6.837 Computer Graphics - MIT

2y ago
11 Views
3 Downloads
2.53 MB
82 Pages
Last View : 1m ago
Last Download : 3m ago
Upload by : Grant Gall
Transcription

Welcome to6.837 Computer GraphicsWojciech MatusikMIT CSAILPicture: Alexis Rufatt– DurandImage courtesy of Nicolas Desprez6.837on Wikipedia.License: CC-BY-SA. This content is excluded fromour Creative Commons license. For more information, see http://ocw.mit.edu/help/faq-fair-use/.

Luxo Jr. Pixar Animation Studios, 1986 Director: John LasseterImage of Pixar's Luxo Jr. removed due to copyright restrictions -- please o-jr/ for further details.2

Plan Overview of computer graphicsAdministriviaOverview of the semesterOverview of assignmentsIntro to OpenGL & assignment 03

What are the applications of graphics?4

Movies/special effectsImages removed due to copyright restrictions.5

More than you would expectVideo clip removed due to copyright restrictions -- pleasesee http://vimeo.com/9553622 for further details.6

Video GamesImages removed due to copyright restrictions.7

SimulationImages removed due to copyright restrictions.8

CAD-CAM & DesignImages removed due to copyright restrictions.9

ArchitectureImages removed due to copyright restrictions.10

Video removed due to copyright restrictions -- please see "The Light of Mies van der Rohe"for further details, available at http://graphics.ucsd.edu/ henrik/animations/.11

Virtual RealityImages removed due to copyright restrictions.12

VisualizationImages removed due to copyright restrictions.13

Medical ImagingImages removed due to copyright restrictions.14

EducationImage removed due to copyright restrictions.15

Geographic Info Systems & GPSImage removed due to copyright restrictions.16

Any display Computers go through OpenGL and DirectX todisplay anything 2D graphics, Illustrator, Flash, FontsImage removed due to copyright restrictions.17

What do you expect to learn? And why?18

What you will learn in 6.837 Fundamentals of computer graphics algorithms– Will give a pretty good idea of how to implement lotsof the things just shown We will concentrate on 3D,not 2D illustration or image processing Basics of real-time renderingand graphics hardware Basic OpenGL– Not the focus, though: Means, not the end. You will get C programming experience19

What you will NOT learn in 6.837 OpenGL and DirectX hacks– Most become obsolete every 18 months anyway!– Does not really matter either: Graphics is becoming allsoftware again (OpenCL, Larrabee, etc.) Software packages– CAD-CAM, 3D Studio MAX, Maya– Photoshop and other painting tools Artistic skills Game design20

How much Math? Lots of simple linear algebra– Get it right, it will help you a lot! Some more advanced concepts– Homogeneous coordinates– Ordinary differential equations (ODEs)and their numerical solution– Sampling, antialiasing (some gentle Fourier analysis)– Monte-Carlo integration Always in a concrete and visual context21

Beyond computer graphics Many of the mathematical and algorithmic toolsare useful in other engineering and scientificcontext Linear algebra Splines Differential equations Monte-Carlo integration 22

Questions?23

Plan Overview of computer graphicsAdministriviaOverview of the semesterOverview of assignmentsIntro to OpenGL & assignment 024

Team Instructor– Wojciech Matusik25

Administrivia: Website, Staff Email Course website– Announcements– Slides (posted soon after each lecture)– Assignments, both instructions and turn-in Message Board Staff Email– Reaches all of us, preferred method of communication26

Administrivia: Grading Policy Assignments: 75%– Two-week programming assignments– Must be completed individually– No final project Quiz: 10%– in class Final Exam: 10%– TBA during finals week Participation: 5%27

Administrivia: Prerequisites Not strictly enforced All assignments are in C – Optional review/introductory session Calculus, Linear Algebra– Solving equations, derivatives, integral– vectors, matrices, basis, solving systems of equations– Optional review/introductory session28

Administrivia: Assignments Turn in code and executable (Linux) Always turn in a README file– Describe problems, explain partially-working codeSay how long the assignment took Coding style important– Some assignments are cumulative Collaboration policy:– You can chat, but code on your own– Acknowledge your collaboration! (in readme file) Late policy:––––The deadline is absolute: 0 if not on timeDue Wednesday @ 8pmExtensions only considered if requested 1 week before due dateMedical problems must be documented29

The deadline is absolute I mean it. I do regularly give 0 for,– an assignment turned in half an hour late– turning in the wrong file Submit early, even before you might be fullydone30

Collaboration policy You can chat, but code on your own(we use automated plagiarism detectionsoftware!) Use Piazza message board Help others on Piazza message board (will helpyour grade!) Acknowledge your collaboration (in README) Talk to each other, get a community going– Graphics is fun!31

Administrivia: Assignments The assignments are a lot of work. Really.– Start early!32

Assignments0: Warm up (mesh display with OpenGL)1: Curves & surfaces2: Hierarchical modeling, skinning3: Physically-based simulation4: Ray casting5: Ray tracing(more in later slides)33

Textbooks No textbook is required Recommendations– 3D Computer Graphics (Watt)– 3D Computer Graphics: A MathematicalIntroduction with OpenGL (Buss) There is a free online version availablefrom Books24x7– Real-Time Rendering, 3rd ed. (AkenineMöller, Haines, Hoffman)– Fundamentals of Computer Graphics, 3rded. (Shirley, Marschner)34

Questions?35

Plan Overview of computer graphicsAdministriviaOverview of the semesterOverview of assignmentsIntro to OpenGL & assignment 036

How do you make this picture?– Geometry– Materials– Lights Animation– Make it move RenderingSemester Modeling– I.e., draw the picture!– Lighting, shadows, textures. Remedy Enterainment. All rights reserved. This content is excluded from our CreativeCommons license. For more information, see http://ocw.mit.edu/help/faq-fair-use/.37

Questions?38

Overview of the Semester Modeling, TransformationsAnimation, ColorRay Casting / Ray TracingThe Graphics PipelineTextures, ShadowsSampling, Global Illumination39

Transformations Yep, good old linear algebra Homogeneous coordinates– (Adding dimensions to make life harder) Perspective40

Modeling Curves and surfaces Subdivision surfaces41

Animation: KeyframingACM 1987 “Principles of traditional animationapplied to 3D computer animation” ACM. All rights reserved. This content is excluded from our Creative Commonslicense. For more information, see http://ocw.mit.edu/help/faq-fair-use/.42

Character Animation: Skinning Animate simple “skeleton” Attach “skin” to skeleton– Skin deforms smoothly with skeleton Used everywhere (games, movies)Image removed due tocopyright restrictions.Ilya Baran Ilya Baran. All rights reserved. This content is excluded from our Creative Commonslicense. For more information, see http://ocw.mit.edu/help/faq-fair-use/.43

Particle system (PDE) ACM. All rights reserved. This content is excluded from our Creative Commonslicense. For more information, see http://ocw.mit.edu/help/faq-fair-use/.44

“Physics” (ODEs) Fire, smoke Cloth Quotes becausewe do “visualsimulation” David E. Breen. All rights reserved. This content is excluded from our CreativeCommons license. For more information, see http://ocw.mit.edu/help/faq-fair-use/.45

ColorsaturationCourtesy of Victor Ostromoukhov.hue46

Ray Casting For every pixelconstruct a ray from the eye– For every object in the scene Find intersection with the ray Keep if closest47

Ray Tracing Shade (interaction of light and material) Secondary rays (shadows, reflection, refraction)48

Ray Tracing Original Ray-tracedimage by Whitted Image computed usingthe Dali ray tracer byHenrik Wann Jensen Environment map byPaul Debevec source unknown. All rights reserved. This content is excluded from our CreativeCommons license. For more information, see http://ocw.mit.edu/help/faq-fair-use/.Courtesy of Henrik Wann Jensen. Used with permission.49

Textures and ShadingCourtesy of Jeremy Birn.50

Sampling & Antialiasing source unknown. All rights reserved. This content is excluded from our CreativeCommons license. For more information, see http://ocw.mit.edu/help/faq-fair-use/. 51

Shadows source unknown. All rights reserved. This content is excluded from our CreativeCommons license. For more information, see http://ocw.mit.edu/help/faq-fair-use/.52

Traditional Ray TracingCourtesy of Henrik Wann Jensen. Used with permission.53

Global IlluminationCourtesy of Henrik Wann Jensen. Used with permission.54

The Graphics PipelineRay CastingFor each pixelFor each objectSend pixels to sceneRendering PipelineFor each triangleFor each projected pixelProject scene to pixels55

The Graphics Pipeline Transformations Clipping Rasterization Visibility56

Questions?57

Plan Overview of computer graphicsAdministriviaOverview of the semesterOverview of assignmentsIntro to OpenGL & assignment 058

Assignment 1: curves & surfacesBezier curvesSurfaces of revolutionSweep surfaces59

Assignment 2: hierarchical modeling Animate character skeletonas tree of transformations Skinning: smooth surface deformation60

Assignment 3: physics Simulate cloth as a mass-spring network– ODE integration61

Assignment 4: ray casting Cast rays from the viewpoint Intersect with scene primitives62

Assignment 5: ray tracing Shadows, reflection, refraction flexible extension63

Questions?64

Plan Overview of computer graphicsAdministriviaOverview of the semesterOverview of assignmentsIntro to OpenGL & assignment 065

Simple 3D with OpenGL OpenGL is an API that allows you to sendcommands to the graphics card to draw 2D or 3Dscenes At the beginning of the semester, we will useOpenGL as a black box to display 3D content Later, we will see what is under the hood66

Assignment 0 Read a file with triangle mesh data– Including mesh normals Display it using OpenGL– Colors, simple movement Due next Wednesday!67

Simple 3D with OpenGL Scene represented astriangles– A triangle is a set of 3 vertices– A vertex is a set of 3 floatingpoint numbers (x, y, z) We will use OpenGL to sendthis to the graphics card(GPU)– The GPU will do its magic todisplay the scene from thecurrent viewpoint (Later, wewill get to see how thishappens)68

How to Draw? You need to tell OpenGL– The geometry of the objectModelviewObject coordinatesWorld coordinatesView coordinatesImage coordinatesProjection Vertex positions Vertex normals 3 x vertex makes a triangle!– Camera parameters Field of view, aspect ratio, (depth range) The “projection matrix”69

Questions?70

OpenGL high-level pseudocode Initialize– (get graphics context, etc.) For each frame– Manage UI– Set appropriate viewpoint– Set light source directions– For each triangleFor i 0 to 2Send vertex data71

OpenGL Example: Viewing// Current matrix affects objects positionsglMatrixMode( GL MODELVIEW );// Initialize to the identityglLoadIdentity();// Position the camera at [0,0,5], looking at// [0,0,0], with [0,1,0] as the up direction.gluLookAt(0.0, 0.0, 5.0,0.0, 0.0, 0.0,0.0, 1.0, 0.0);// Rotate by -20 degrees about [0,1,0]glRotated(-20.0, 0.0, 1.0, 0.0);// Draw a teapot.glutSolidTeapot(1.0);72

Vertex data What information do we need at each vertex?–––––Coordinates (3 floats)Color (optional, 3 floats)Normal information (optional, 3 floats)Transparency (optional, 1 float)More to come (texture information, shininess)73

Why normals? To compute color as a function of light direction Simplest: Diffuse or Lambert model– Intensity dot product (normal, light direction)NormalLightsourceLight directionSurface74

OpenGL CodeglBegin(GL TRIANGLES); //what follows describes trianglesglColor3d (1,1,0); //red, green and blue components (yellow)glNormal3d (0, 0, 1); //normal pointing upglVertex3d (2,3,3); //3D position x, y, zglColor3d (1,0,0);glNormal3d (0, 0, 1);glVertex3d (5,3,3);glColor3d (1,0,1);glNormal3d (0, 0, 1);glVertex3d (3,6,3);glEnd();75

OpenGL high-level pseudocode Initialize– (get graphics context, etc.) For each frame– Manage UI– Set appropriate viewpoint– Set light source directions– For each triangleFor i 0 to 2Send vertex data76

OpenGL is a state machine Each command changes the state– But glVertex also “pushes” data For example, glColor3f changes the current color.– The color remains valid until we call glColorxx again– Use it before each vertex to get per-vertex color. Other state to manage lighting and otherrendering aspects Can make it hard to debug (Note: This is conceptually simple, but not quite how you writeefficient code these days.)77

Assignment 0 Read a file with triangle mesh data– Including mesh normals Display it using OpenGL– Colors, simple movement Due next Wednesday!78

What is missing? ShadowsShininessTextureEtc. Be patient, you will have plenty enough79

Linear Algebra is Everywhere Vertices are 3-vectors Normals are 3-vectors– Orthogonal to surface tangent plane– Cross product Colors are 3-vectors Diffuse shading is a dot product A non-bending object moving in a sceneundergoes a rigid transformation Changing the viewpoint is a linear transformationof the scene coordinate Brush up in the review session!80

What Makes Graphics Fun? Very interdisciplinary– Within CS: systems, compilers,languages, computer architecture,algorithms, numerical techniques– Math, physics, art, perception,architecture, manufacturing Helps you understand why theworld looks the way it does You can “see” the resultImage removed due to copyright restrictions.visualparadox.com81

MIT OpenCourseWarehttp://ocw.mit.edu6.837 Computer GraphicsFall 2012For information about citing these materials or our Terms of Use, visit: http://ocw.mit.edu/terms.

– 3D Computer Graphics (Watt) – 3D Computer Graphics: A Mathematical Introduction with OpenGL (Buss) There is a free online version. available from Books24x7 – Real-Time Rendering, 3rd ed. (Akenine-Möller, Haines, Hoffman) – Fundamentals of Computer Graphics, 3rd

Related Documents:

EDI Basics - The X12 837 Format. 9. X12 837 5010 Format X12 - National set of inter-industry electronic data interchange (EDI) standards for insurance transactions 837 - Health Care Claim transactions 5010 - Version of 837 transactions - Professional/DME X12N/005010X222 837-P

Shirley, Fundamentals of Computer Graphics MIT EECS 6.837, Durand and Cutler Cubic BSplines MIT EECS 6.837, Durand and Cutler Cubic BSplines can be chained together better control locally (windowing) MIT EECS 6.837, Durand and Cutler Bézier is not the same as BSpline Relat

de fr nl it en www.krups.com espresso automatic series ea9000 www.krups.com xxxxxxx - réalisation : espace graphique de hotline: de: 0212 387 400 - at: 01 866 70 299 00 - ch: 044 837 18 40 fr hotline : b : 32 70 23 31 59 - f : 09 74 50 10 61 - ch : 044 837 18 40 nl hotline: nl: 0318 58 24 24 it servizio consumatori: it: 199207701 - ch: 044 837 18 40 en hotline: uk: 0845 330 6460 - roi: 01 677 .

Oswego Oswego Senior Center 156 E. Washington Street Oswego, Illinois 60543 630-554-5602 . Bushnell, Colchester, and Macomb McDonough County YMCA 400 East Calhoun Street Macomb, Illinois 61455 309-837-5733 309-837-5734 Fax: 309-837-5755 . 16338 N. IL Hwy 37 Mt. Vernon, Illinois 6286

Aug 01, 2021 · Auto Repair Shop Family Owned Since 1952 www.solutionsforpayroll.com 608-837-2590 www.mbecpa.com 608-837-2584 INSURE CAREFULLY, DREAM FEARLESSLY. CALL (608) 837-6607 TODAY TO SEE HOW I CAN HELP PROTECT WHAT MATTERS MOST. Larry Anderson, Agent 695 S Grand Ave #204 Sun

ANSI 837 Electronic Claims Data Entry Note: Entering the following data will result in ANSI 837 errors! Do not use words such as "Same" "None" or "N/A". Use only valid data in fields. Do not use MR., MS. or other prefixes. Do not use DR. MD, OD etc. A provider is identified by their NPI or Provider number.

4 P a g e Click Upload. Select Browse to locate the 837 batch and choose 837 Claim from the File Type menu. After selecting the X12 837 file enter notes for agency and board reference as needed. Click Upload to transfer the batch. View the file upload status in the following screen.

DB2 Database technical information. 837 Overview of the DB2 technical information. 837 Documentation feedback. . 837 DB2 technical library in hardcopy or PDF . SET INTEGRITY statement. v "SQL statements allowed in