Rendering Pipeline and Graphics HardwareOverviewFramebuffersFramebuffers: True-ColorFramebuffers: Indexed-ColorFramebuffers: Hi-ColorSlide 7Slide 8The Rendering Pipeline: A TourThe Parts You KnowThe Rendering Pipeline2-D Rendering: RasterizationThe Rendering Pipeline: 3-DSlide 14Slide 15Slide 16Rendering: TransformationsSlide 18Slide 19Slide 20Slide 21Slide 22Slide 23Slide 24Rendering: LightingLighting SimulationSlide 27Slide 28Slide 29Rendering: ClippingSlide 31Slide 32Slide 33Modeling: The BasicsModeling: The Scene GraphSlide 36Slide 37Modeling: The CameraSlide 39Camera ModelsCamera ParametersSlide 42Visible Surface DeterminationRay CastingSlide 45Slide 46Rendering AlgorithmsSlide 48Graphical Hardware CompaniesA much older graphics pipelineSlide 51SummaryRendering Pipeline and Graphics HardwareAaron BloomfieldCS 445: Introduction to GraphicsFall 20062OverviewFramebuffersRendering PipelineTransformationsLightingClippingModelingCameraVisible Surface DeterminationHistoryHow is the rasterized scene kept in memory?How is the rasterized scene kept in memory?3FramebuffersSo far we’ve talked about the physical display deviceHow does the interface between the device and the computer’s notion of an image look?Framebuffer: A memory array in which the computer stores an imageOn most computers, separate memory bank from main memory (why?)Many different variations, motivated by cost of memory4Framebuffers: True-Color A true-color (aka 24-bit or 32-bit) framebuffer stores one byte each for red, green, and blueEach pixel can thus be one of 224 colorsPay attention toEndian-nessHow can 24-bit and 32-bit mean the same thing here?5Framebuffers: Indexed-ColorAn indexed-color (8-bit or PseudoColor) framebuffer stores one byte per pixel (also: GIF image format)This byte indexes into a color map: How many colorscan a pixel be?Still common on low-end displays (cell phones, PDAs,GameBoys)Cute trick: color-map animation6Framebuffers: Hi-ColorHi-Color was a popular PC SVGA standardPacks pixels into 16 bits:5 Red, 6 Green, 5 Blue (why would green get more?)Sometimes just 5,5,5Each pixel can be one of 216 colorsHi-color images can exhibit worse quantization artifacts than a well-mapped 8-bit image78OverviewFramebuffersRendering PipelineTransformationsLightingClippingModelingCameraVisible Surface DeterminationHistoryHow does the graphics hardware process the graphical display?How does the graphics hardware process the graphical display?9The Rendering Pipeline: A TourTransformIlluminateTransformClipProjectRasterizeModel & CameraModel & CameraParametersParametersRendering PipelineRendering PipelineFramebufferFramebufferDisplayDisplay10The Parts You KnowTransformIlluminateTransformClipProjectRasterizeModel & CameraModel & CameraParametersParametersRendering PipelineRendering PipelineFramebufferFramebufferDisplayDisplay11The Rendering PipelineTransformIlluminateTransformClipProjectRasterizeModel & CameraModel & CameraParametersParametersRendering PipelineRendering PipelineFramebufferFramebufferDisplayDisplay12We’ll talk about this soon…2-D Rendering: RasterizationTransformIlluminateTransformClipProjectRasterizeModel & CameraModel & CameraParametersParametersRendering PipelineRendering PipelineFramebufferFramebufferDisplayDisplay13The Rendering Pipeline: 3-DTransformIlluminateTransformClipProjectRasterizeModel & CameraModel & CameraParametersParametersRendering PipelineRendering PipelineFramebufferFramebufferDisplayDisplay14The Rendering Pipeline: 3-DModelingTransformsScene graphObject geometryLightingCalculationsViewingTransformClippingProjectionTransformResult:Result:• All vertices of scene in shared 3-D “world” coordinate All vertices of scene in shared 3-D “world” coordinate systemsystem• Vertices shaded according to lighting modelVertices shaded according to lighting model• Scene vertices in 3-D “view” or “camera” coordinate Scene vertices in 3-D “view” or “camera” coordinate systemsystem• Exactly those vertices & portions of polygons in view Exactly those vertices & portions of polygons in view frustumfrustum• 2-D screen coordinates of clipped vertices2-D screen coordinates of clipped vertices15The Rendering Pipeline: 3-DScene graphObject geometryLightingCalculationsClippingResult:Result:• All vertices of scene in shared 3-D “world” coordinate All vertices of scene in shared 3-D “world” coordinate systemsystem• Vertices shaded according to lighting modelVertices shaded according to lighting model• Scene vertices in 3-D “view” or “camera” coordinate Scene vertices in 3-D “view” or “camera” coordinate systemsystem• Exactly those vertices & portions of polygons in view Exactly those vertices & portions of polygons in view frustumfrustum• 2-D screen coordinates of clipped vertices2-D screen coordinates of clipped verticesModelingTransformsViewingTransformProjectionTransform16OverviewFramebuffersRendering PipelineTransformationsLightingClippingModelingCameraVisible Surface DeterminationHistoryHow do you transform the objects so they can be displayed?How do you transform the objects so they can be displayed?17Rendering: TransformationsSo far, discussion has been in screen spaceBut model is stored in model space(a.k.a. object space or world space)Three sets of geometric transformations:Modeling transformsViewing transformsProjection transforms18Rendering: TransformationsModeling transformsSize, place, scale, and rotate objects parts of the model w.r.t. each otherObject coordinates world coordinatesThe scene now has it’s origin at (0,0,0)ZXYXZY19Rendering: TransformationsViewing transformRotate & translate the world to lie directly in front of the cameraTypically place camera at originTypically looking down -Z axisWorld coordinates view coordinatesThe scene now has it’s origin at the camera20Rendering: TransformationsProjection transformApply perspective foreshorteningDistant = small: the pinhole camera modelView coordinates screen coordinatesThe scene is now in 2 dimensions21Rendering: TransformationsAll these transformations involve shifting coordinate systems (i.e., basis sets)Matrices do thatRepresent coordinates as vectors, transforms as
View Full Document