Cs 352:.


96 views
Uploaded on:
Description
Cs 352:. Intelligent. 3D. PC Design. This Class. Intuitive 3D Design Programming (with an essence of 2D illustrations, photorealistic, picture preparing, demonstrating, and client interfaces) Top-down methodology. Course Data Syllabus Approaches Stage Ventures.
Transcripts
Slide 1

Cs 352: Interactive 3D Computer Graphics

Slide 2

This Class Interactive 3D Graphics Programming (with an essence of 2D illustrations, photorealistic, picture handling, displaying, and client interfaces) Top-down methodology Course Information Syllabus Policies Platform Projects

Slide 3

Intelligence Chart

Slide 4

Comet Simulation COMET CRASH - Sandia supercomputer reproductions of an one-kilometer comet entering Earth\'s air, drawing closer the sea\'s surface, and affecting the sea, disfiguring the sea depths and making a titan high-weight steam blast ascending into the stratosphere. The blast launches comet vapor and water vapor into ballistic directions that spread far and wide. The New York City horizon is appeared for scale.

Slide 5

Ray-followed Image

Slide 6

Animation Interim Examples

Slide 7

Aspects of Graphics Design versus Programming Interactive versus Photorealistic 2D versus 3D Graphics versus picture preparing versus client interfaces

Slide 8

OpenGL Programming OpenGL : a broadly utilized, open API Old Procedural C versus C++ Accessible Support Need equipment support for top execution Drivers accompany Windows, Mac OS X (however Windows drivers weren’t quickened until Vista) Drivers accessible for Unix/Linux for a few representation cards (e.g. nvidia) Use lab PCs with design cards—or your own particular PC

Slide 9

OpenGL versus Direct3D: MS just Used more for recreations Latest adaptations are great OpenGL Used more for expert applications Cross-stage (for all intents and purposes all OSs, amusement supports) Latest forms: expansions, section programs (otherwise known as pixel shaders) OpenGL ES: for PDAs, and so on. We’ll utilize more fundamental components of OpenGL

Slide 10

Other programming we’ll use POV beam tracer ImageMagick picture control library QT 2D windowing library from Trolltech Cross-stage GUI toolbox: windowing, 2D and 3D representation Also backings organizing, interactive media, XML, … Used in KDE (“best GUI toolbox for UNIX”) Commercial and Open Source (GPL) variants 3D Modeling: Lightwave 3D?

Slide 11

Chapter 1: Graphics Systems and Models A Graphics System Processor Memory Frame Buffer Display Input Devices Output Devices

Slide 12

Graphics Architecture

Slide 13

Images Array of pixels Red , Green , Blue May likewise have an alpha worth (straightforwardness)

Slide 14

Pixels and the Frame Buffer Pixels: picture components 3 values: RGB, 0-255 or 0-65536 or 0.0-1.0 4 values: RGBA (Alpha = straightforwardness) Frame cushion Depth: bits per pixel Indexed versus genuine nature Uses quick, double ported VRAM Bandwidth required from VRAM to DAC (advanced to-simple converter)?

Slide 15

Frame Buffer, LUT and DAC Look-up table maps shading record - > full shading Digital to simple converter proselytes R, G, and B numbers to voltages

Slide 16

CRT Display

Slide 17

Shadow Mask

Slide 18

Display terms Electron weapon Scan line Resolution Horizontal and vertical re-follow Refresh, revive rate Interlace Phosphor Triad NTSC, PAL, S-feature, Composite, DV

Slide 19

LCD Display An unpowered LCD layer changes polarization of light

Slide 20

Other I/O gadgets Virtual Valuators Selectors Physical Mouse, console Buttons & Dials Fancy showcases VR gear

Slide 21

VR equipment

Slide 22

The Human Visual System Rods: night vision Cones: day vision Three sorts of cones, with diverse shading affectability We model and render for its abilities

Slide 23

Spectral Sensitivity Color range: 780 nm (blue)…350 nm (red)

Slide 24

Graphics Paradigms Modeling Rendering Photo-practical: Ray following Radiosity Interactive: Projection – camera model Transformations, cut-out Shading Texture mapping Rasterization

Slide 25

Ray Tracing Ray Tracing

Slide 26

Ray-followed blob

Slide 27

How does Ray-Tracing work? Displaying Build a 3D model of the world Geometric primitives Light sources Material properties Simulate the ricocheting of light beams Trace beam from eye through picture pixel to see what it hits From there, bob beam in reflection course, towards light source, and so forth. In this manner, model material science of outflow, reflection, transmission, and so on (in reverse)

Slide 28

Modeling the World camera { area <0, 5, - 5> look_at <0, 0, 0> edge 58 } light_source { <- 20, 30, - 25> shading red 0.6 green 0.6 blue 0.6 } blob { limit 0.5 circle { <- 2, 0, 0>, 1, 2 } chamber { <- 2, 0, 0>, <2, 0, 0>, 0.5, 1 } barrel { <0, 0, - 2>, <0, 0, 2>, 0.5, 1 } barrel { <0, - 2, 0>, <0, 2, 0>, 0.5, 1 } color { shading red 1 green 0 blue 0 } complete { encompassing 0.2 diffuse 0.8 phong 1 } pivot <0, 20, 0> }

Slide 29

Ray through pixel

Slide 30

Flat blob

Slide 31

Bounce toward lights

Slide 32

Shadows

Slide 33

Shaded blob

Slide 34

Blob with Highlights

Slide 35

Blob with ground plane

Slide 36

Blob with straightforwardness

Slide 37

Blob with refraction

Slide 38

Types of brightening Ambient – "light soup" that influences each point just as Diffuse – shading that relies on upon the surface\'s edge to the light source Specular – "highlights." Falls off pointedly far from the reflection course Example: lighting applet

Slide 39

What are these made of?

Slide 40

Material sorts Dielectrics (non-channels): In body reflection, light enters the surface and is influenced by material shade Highlights are the light\'s shade source Examples: paint, plastic, wood, … Conductors (metals) No light infiltrates the surface Highlight and "body" reflection are influenced just as by the material Same shading for diffuse and specular reflection

Slide 41

Finishes

Slide 42

Textures

Slide 43

Surface (Ripples)

Slide 44

POV-Ray Primitives

Slide 45

Constructive Solid Geometry

Slide 46

Sunsethf

Slide 47

How to beam trace… Transparency? Refraction? Reflection? Haze?

Slide 48

Drawbacks of beam following? Time: numerous beams are required per pixel… Up to 25 beams through every pixel Each beam may skip and split ordinarily Each beam tried for crossing point with numerous items E.g. 1M pixels * 25 beams for each pixel * 40 beams for each beam tree * 1000 items = 1 trillion article convergence tests… Hard lighting No delicate shadows, between article dissemination, and so on

Slide 49

POV-Ray An amazing, free beam tracer: POV-Ray We\'ll use for a brief introduction to beam following Runs on PC, Unix, Mac, Beowolf bunches, … Installed on the PCs in the Unix lab You may wish to introduce all alone PC First "lab": make a beam followed picture of four distinct sorts of primitives, one every plastic, glass, metal, and reflected, over checked floor

Slide 50

Radiosity Treat every patch as reflector and emitter of light Each patch influences each other patch contingent upon separation, introduction, impediment and so forth. Let light "bounce around" for a couple of emphasess to register the measure of light coming to a patch

Slide 51

Radiosity picture

Slide 52

Radiosity - table

Slide 53

Radiosity in POV-Ray

Slide 54

Radiosity illustration

Slide 55

Radiosity outline Radiosity gives sublime delicate shading But considerably slower than beam tracing… Can\'t do reflection, refraction, specular highlights with radiosity Can join beam following and radiosity for best of both universes (and double the time)

Slide 56

Interactive strategies Ray following and radiosity are too moderate We\'ll focus on intuitive methods What sort of rendering should be possible rapidly ?

Slide 57

Shutterbug - Orthographic

Slide 58

- Perspective

Slide 59

- Depth Cueing

Slide 60

- Depth Clipping

Slide 61

- Colored Edges

Slide 62

- Hidden line evacuation

Slide 63

- Hidden surface evacuation

Slide 64

- Flat shading

Slide 65

- Gouraud shading

Slide 66

- Gouraud/specular

Slide 67

- Gouraud/phong

Slide 68

- Curved surfaces

Slide 69

- Improved light

Slide 70

- Texture mapping

Slide 71

- Displacements, shadows

Slide 72

- Reflections

Slide 73

Synthetic camera Model the world and the camera Find the focuses on plane where world focuses show up ( projection ) One technique works like a pinhole camera Foundation of mod-ern 3D representation

Slide 74

Pinhole camera model We draw a line ( projector ) from picture point, through Center of Projection (COP), to picture (projection plane) x p = - x/(z/d), y p = - y/(z/d) -

Slide 75

Formulations of the pinhole model "Film" can be considered as behind or in front of COP

Slide 76

Camera Applet We can try different things with the camera model utilizing this camera applet

Slide 77

Clipping Any parts of the picture anticipating outside the unmistakable district are "clipped" (dispensed with)

Slide 78

Programmer\'s Interface The engineered camera model is the premise of well known APIs, for example, OpenGL, Direct3D, PHIGS, VRML, Java-3D

Slide 79

APIs API: application program interface. Protect program from equipment. The API must permit us to display the earth, as we did in beam following Need to model Objects (primitives) Material properties Viewer (camera) Lights

Slide 80

OpenGL Primitives A triangle glBegin(GL_POLYGON); glVertex3f(0.0, 0.0, 0.0); glVertex3f(0.0, 1.0, 0.0); glVertext3f(0.0, 0.0, 1.0); glEnd(); Vertices determined between glBegin/glEnd pair Primitives incorporate polygons, lines, content, bends, surfaces

Slide 81

OpenGL Camera OpenGL has an adaptable camera model Simple camera definition: gluLookAt(cop_x, cop_y, cop_z, at_x, at_y, at_z, …) glPerspective(field_of_view, …)

Slide 82

Rendering pipeline Transformations Clipping Projection Ras

Recommended
View more...