DOC PREVIEW
MIT 6 837 - Clipping and other geometric algorithms

This preview shows page 1-2-3-4-5-6-42-43-44-45-46-47-85-86-87-88-89-90 out of 90 pages.

Save
View full document
View full document
Premium Document
Do you want full access? Go Premium and unlock all 90 pages.
Access to all documents
Download any document
Ad free experience
View full document
Premium Document
Do you want full access? Go Premium and unlock all 90 pages.
Access to all documents
Download any document
Ad free experience
View full document
Premium Document
Do you want full access? Go Premium and unlock all 90 pages.
Access to all documents
Download any document
Ad free experience
View full document
Premium Document
Do you want full access? Go Premium and unlock all 90 pages.
Access to all documents
Download any document
Ad free experience
View full document
Premium Document
Do you want full access? Go Premium and unlock all 90 pages.
Access to all documents
Download any document
Ad free experience
View full document
Premium Document
Do you want full access? Go Premium and unlock all 90 pages.
Access to all documents
Download any document
Ad free experience
View full document
Premium Document
Do you want full access? Go Premium and unlock all 90 pages.
Access to all documents
Download any document
Ad free experience
View full document
Premium Document
Do you want full access? Go Premium and unlock all 90 pages.
Access to all documents
Download any document
Ad free experience
View full document
Premium Document
Do you want full access? Go Premium and unlock all 90 pages.
Access to all documents
Download any document
Ad free experience
View full document
Premium Document
Do you want full access? Go Premium and unlock all 90 pages.
Access to all documents
Download any document
Ad free experience
View full document
Premium Document
Do you want full access? Go Premium and unlock all 90 pages.
Access to all documents
Download any document
Ad free experience
View full document
Premium Document
Do you want full access? Go Premium and unlock all 90 pages.
Access to all documents
Download any document
Ad free experience
View full document
Premium Document
Do you want full access? Go Premium and unlock all 90 pages.
Access to all documents
Download any document
Ad free experience
View full document
Premium Document
Do you want full access? Go Premium and unlock all 90 pages.
Access to all documents
Download any document
Ad free experience
View full document
Premium Document
Do you want full access? Go Premium and unlock all 90 pages.
Access to all documents
Download any document
Ad free experience
View full document
Premium Document
Do you want full access? Go Premium and unlock all 90 pages.
Access to all documents
Download any document
Ad free experience
View full document
Premium Document
Do you want full access? Go Premium and unlock all 90 pages.
Access to all documents
Download any document
Ad free experience
View full document
Premium Document
Do you want full access? Go Premium and unlock all 90 pages.
Access to all documents
Download any document
Ad free experience
Premium Document
Do you want full access? Go Premium and unlock all 90 pages.
Access to all documents
Download any document
Ad free experience

Unformatted text preview:

Clipping and other geometric algorithmsFinal projectsReview of last time?Last timeZ interpolationInteger z-bufferPlanThe Graphics PipelineModeling TransformationsIllumination (Shading) (Lighting)Viewing TransformationClippingClipping – modern hardwareProjectionPerspective ProjectionWhen to clip?Scan Conversion (Rasterization)Visibility / DisplayRendering Pipeline vs. ray castingSlide 20GamesFlight simulationMoviesCAD-CAM & designArchitectureVirtual realityVisualization:Medical imaging: cf. visualizationQuestions?The infamous half pixelSlide 31Slide 32Polygon clippingSlide 34Slide 35Polygon clipping is complexPolygon clipping is nastyNaïve polygon clipping?Weiler-Atherton ClippingSlide 40Slide 41Slide 42Walking rulesSlide 44Slide 45Slide 46Slide 47Slide 48Slide 49Slide 50Slide 51Robustness, precision, degeneraciesSlide 53Constructive Solid Geometry (CSG)Slide 55Slide 56Line segment intersectionMaximum complexity?Intersection between 2 segmentsNaïve algorithmTaking advantage of coherence 1Slide 62Slide 63What have we achieved?Can we do better?Maintain segments sorted in yNew segmentEnd of segmentIntersectionSweep algorithmSlide 71Slide 72Slide 73Slide 74Slide 75Slide 76Output sensitiveOther strategy?RefSlide 80Slide 81Scan Line rasterizationScan Line : PrinciplePrecompute: Edge TableInitialization: eventsWhen Does AEL Change State?Slide 87Scanline algorithm summaryOther sweep algorithmsSlide 90MIT EECS 6.837, Cutler and Durand 1Clipping and other geometric algorithmsMIT EECS 6.837Frédo Durand and Barb CutlerMIT EECS 6.837, Cutler and Durand 2Final projects•Rest of semester–Weekly meetings with TAs–Office hours on appointment•This week, with TAs–Refine timeline–Define high-level architecture•Project should be a whole, but subparts should be identified with regular merging of codeMIT EECS 6.837, Cutler and Durand 3Review of last time?MIT EECS 6.837, Cutler and Durand 4Last time•Polygon scan conversion–Smart•Take advantage of coherence•Good for big triangles–back to brute force•Incremental edge equation•Good for small triangles•Simpler clipping•Visibility–Painer: complex ordering–Z buffer: simple, memory cost•Hyperbolic z interpolationMIT EECS 6.837, Cutler and Durand 5Z interpolation•X’=x/z•Hyperbolic variation•Z cannot be linearly interpolatedz0z1ximagex’MIT EECS 6.837, Cutler and Durand 6Integer z-buffer•Use 1/z to have more precision in the foreground•Set a near and far plane–1/z values linearly encoded between 1/near and 1/far•Careful, test direction is reversedxfarnearMIT EECS 6.837, Cutler and Durand 7Plan•Review of rendering pipeline•2D polygon clipping•Segment intersection•Scanline rendering overviewMIT EECS 6.837, Cutler and Durand 8The Graphics PipelineModeling TransformationsIllumination(Shading)Viewing Transformation(Perspective / Orthographic)ClippingProjection (to Screen Space)Scan Conversion(Rasterization)Visibility / DisplayMIT EECS 6.837, Cutler and Durand 9Modeling TransformationsModeling TransformationsIllumination(Shading)Viewing Transformation(Perspective / Orthographic)ClippingProjection (to Screen Space)Scan Conversion(Rasterization)Visibility / DisplayObject space World spacex'y'z'1=xyz1aei0bfj0cgk0dhl1MIT EECS 6.837, Cutler and Durand 10Illumination (Shading) (Lighting)•Vertices lit (shaded) according to material properties, surface properties (normal) and light•Local lighting model (Diffuse, Ambient, Phong, etc.)Modeling TransformationsIllumination(Shading)Viewing Transformation(Perspective / Orthographic)ClippingProjection (to Screen Space)Scan Conversion(Rasterization)Visibility / Display2 4 )()()()(dkkkLsqsdar rvlnMIT EECS 6.837, Cutler and Durand 11Viewing Transformation•Viewing position is transformed to origin & direction is oriented along some axis (usually z)Modeling TransformationsIllumination(Shading)Viewing Transformation(Perspective / Orthographic)ClippingProjection (to Screen Space)Scan Conversion(Rasterization)Visibility / DisplayEye spaceWorld spaceYet another 4x4 matrixx'y'z'1=xyz1aei0bfj0cgk0dhl1MIT EECS 6.837, Cutler and Durand 12Clipping•Portions of the object outside the view volume (view frustum) are removedModeling TransformationsIllumination(Shading)Viewing Transformation(Perspective / Orthographic)ClippingProjection (to Screen Space)Scan Conversion(Rasterization)Visibility / DisplayMIT EECS 6.837, Cutler and Durand 13Clipping – modern hardware•Only to the near planeModeling TransformationsIllumination(Shading)Viewing Transformation(Perspective / Orthographic)ClippingProjection (to Screen Space)Scan Conversion(Rasterization)Visibility / Display(eyex, eyey, eyez)image planez axis"clip" geometry to near planeMIT EECS 6.837, Cutler and Durand 14Projection•Projective transformModeling TransformationsIllumination(Shading)Viewing Transformation(Perspective / Orthographic)ClippingProjection (to Screen Space)Scan Conversion(Rasterization)Visibility / DisplayMIT EECS 6.837, Cutler and Durand 15Perspective Projection•2 conceptual steps:–4x4 matrix–Homogenize•In fact not always needed•Mordern graphics hardware performs most operations in 2D homogeneous coordinatesxy1z / d=xyz1100001000001/d0010x * d / zy * d / zd/z1=homogenizeMIT EECS 6.837, Cutler and Durand 16When to clip?•Before perspective transform in 3D space–Use the equation of 6 planes–Natural, not too degenerate•In homogeneous coordinates after perspective transform (Clip space)–Before perspective divide (4D space, weird w values)–Canonical,independent of camera–The simplest to implement in fact•In the transformed 3D screen space after perspective division–Problem: objects in the plane of the cameraMIT EECS 6.837, Cutler and Durand 17Scan Conversion (Rasterization)•Incremental edge equations•Interpolate values as we go (color, depth, etc.)•Screen-space bbox clippingModeling TransformationsIllumination(Shading)Viewing Transformation(Perspective / Orthographic)ClippingProjection (to Screen Space)Scan Conversion(Rasterization)Visibility / DisplayMIT EECS 6.837, Cutler and Durand 18Visibility / Display•Each pixel remembers the closest object (depth buffer)Modeling TransformationsIllumination(Shading)Viewing Transformation(Perspective / Orthographic)ClippingProjection (to Screen Space)Scan Conversion(Rasterization)Visibility / DisplayxfarnearMIT EECS 6.837, Cutler and Durand 19Rendering Pipeline vs. ray castingRay CastingFor each pixelFor each


View Full Document

MIT 6 837 - Clipping and other geometric algorithms

Documents in this Course
Shadows

Shadows

64 pages

Animation

Animation

37 pages

Radiosity

Radiosity

25 pages

Color

Color

86 pages

InterArch

InterArch

14 pages

Color

Color

15 pages

Animation

Animation

61 pages

Luxo Jr

Luxo Jr

14 pages

Animation

Animation

52 pages

Radiosity

Radiosity

37 pages

Load more
Download Clipping and other geometric algorithms
Our administrator received your request to download this document. We will send you the file to your email shortly.
Loading Unlocking...
Login

Join to view Clipping and other geometric algorithms and access 3M+ class-specific study document.

or
We will never post anything without your permission.
Don't have an account?
Sign Up

Join to view Clipping and other geometric algorithms 2 2 and access 3M+ class-specific study document.

or

By creating an account you agree to our Privacy Policy and Terms Of Use

Already a member?