DOC PREVIEW
UCSD CSE 167 - Texture Mapping

This preview shows page 1-2-3-4-5-36-37-38-39-40-73-74-75-76-77 out of 77 pages.

Save
View full document
View full document
Premium Document
Do you want full access? Go Premium and unlock all 77 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 77 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 77 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 77 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 77 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 77 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 77 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 77 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 77 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 77 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 77 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 77 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 77 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 77 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 77 pages.
Access to all documents
Download any document
Ad free experience
Premium Document
Do you want full access? Go Premium and unlock all 77 pages.
Access to all documents
Download any document
Ad free experience

Unformatted text preview:

#12: Texture MappingOutline for todayLighting ReviewAdvanced Lighting & RenderingAdvanced LightingShadingFlat shadingGouraud ShadingPhong ShadingGouraud vs. Phong shadingNote: Perspective DistortionCartoon ShadingIllustrationProcedural ShadingProgrammable GPUsSlide 16TextureTexture dataTexture examplesSlide 20Texture MapTexture MappingTexture Coordinate AssignmentParametric MappingSlide 25Orthographic MappingPerspective MappingSpherical MappingCylindrical MappingSkin MappingsSolid TexturesDecalsTexture PackingSlide 34Texture InterpolationPerspective CorrectionTilingSlide 38ClampingMirroringMagnificationSlide 42Magnification: point samplingMagnification: Bilinear interpolationMinificationSlide 46Minification: point samplingSlide 48MipmappingMipmapsSlide 51Nearest mipmap, point-sampledNearest mipmap, bilinear interpolationTrilinear mipmappingSlide 55Mipmapping LimitationAnisotropic MipmappingEliptical Weighted AveragingSlide 59Procedural texturesProcedural Texturesnoise functionsPerlin NoiseWorley Cellular NoiseProcedural TextureSlide 66Fancy Texture EffectsEnvironment MappingSlide 69Slide 70Slide 71Bump MappingBump mappingDisplacement MappingSlide 75Other Texture EffectsDone#12: Texture MappingCSE167: Computer GraphicsInstructor: Ronen BarzelUCSD, Winter 20062Outline for todayLighting & Shading wrapupTexture MappingProcedural TexturesFancy Texture Effects3Lighting ReviewLocal Illumination Lighting ModelsAmbient •Normals don’t matterDiffuse (Lambert)•Angle between surface normal and lightPhong, Blinn•Surface normal, light, and viewpointWhat they capture:Direct illumination from light sourcesDiffuse and Specular reflections(Very) Approximate effects of global lightingCompute lighting on any point on a surfaceVertices in particular4Advanced Lighting & RenderingShadowsReflectionTranslucency, refractionCaustics (light focusing)Global Illumination (light “spilling” from one surface to another)Area light sources/emittersAtmospheric effects (fog, clouds)Motion blurDepth of fieldExposure & dynamic range…5Advanced LightingQuickTime™ and aTIFF (Uncompressed) decompressorare needed to see this picture.QuickTime™ and aTIFF (Uncompressed) decompressorare needed to see this picture.QuickTime™ and aTIFF (Uncompressed) decompressorare needed to see this picture.6ShadingChoosing the color for each pixelFor photorealism, typically shading==lightingBut can take shortcuts, or do other thingsVarious techniques:FlatGouraudPhongCartoonIllustrationProcedural7Flat shadingCompute shading at a representative point and apply to whole polygonOpenGL uses one of the verticesAdvantages: Fast - one shading computation per polygon, fill entire polygon with same colorDisadvantages:InaccurateFaceted8Gouraud ShadingLight each vertex with its own location and normalResult is a color at each vertexInterpolate the colors across each triangleDefault mode for most hardware Advantages:Fast: incremental calculations when rasterizingMuch smoother - use one normal per shared vertex to get continuity between facesDisadvantages:Don’t get smooth specular highlightsC1-discontinuities in colorcause Mach bands: perceptualillusions of edges9Phong ShadingWant to recompute lighting at every pixelNeed normal vector at each pixelInterpolate vertex normalsInterpolate the normals while scan-convertingTypically, bilinearly interpolate x,y,z; then renormalizeAlso interpolate or transform to get position in world/camera spaceKnown as Phong Shading or Phong InterpolationNot to be confused with Phong Lighting Model(though both are often used at the same time)Advantages:More accurateBetter imagesDisadvantages:SlowStill not completely accurateModern GPUs can perform Phong shading via pixel shaders10Gouraud vs. Phong shadingGouraud misses specular hilightssolution:tessellate more finely: use smaller trianglesthat would help with the polygonal artifacts on the silhouettes tooGouraud Phong11Linear interpolation in screen space doesn’t align with linear interpolation in world spaceSolutions:Do hyperbolic interpolation (see Buss)Break up into smaller triangles    Z – into the sceneImageplaneNote: Perspective Distortion12Cartoon ShadingGeneral approach:Compute simple lighting•diffuse (with shadows)Remap continuous intensityto two (or a few) levelsSome trickery to draw dark edgesQuickTime™ and aTIFF (Uncompressed) decompressorare needed to see this picture.13IllustrationUse lighting & shadow to define “tone”Not scan-conversion -- separate algorithms for drawing strokes(Winkenbach & Salesin, University of Washington)14Procedural ShadingSoftware or hardware renderer calls an arbitrary routine at every pixel (or sub-pixel)Routine is known as a shaderCan typically implement Phong or any other lighting modelUsed for patterns or other special effectsUsed for cartoon shadingShader typically written in a special-purpose shading languageRenderMan Shading Language (Pixar)Cg (Nvidia)HLSL (DirectX)C/C++ plugins, for software renderersShader: can get surface normal, position, material properties, light locations, …computes a color value (also a transparency value)can sometimes change the surface position! displacement shader15Programmable GPUsTwo kinds of shaders:vertex shaders: run once for each vertexpixel shaders: run for each pixelLimits onsize of programamount of memory availabletypes of memory and texture access (will talk about texture later)etc.Technology still improving, capabilities keep expanding16Outline for todayLighting & Shading wrapupTexture MappingProcedural TexturesFancy Texture Effects17TextureWe know how to model and render uniform smooth surfacesWant more interesting texture:variations in colorsmall-scale patterns, bumps, roughnessIn principle we could model everythingreally tiny trianglesper-vertex colorper-vertex material propertiesModeling everything unwieldy, impracticalToo much of the wrong kind of dataDon’t need that much fine-scale geometric data (triangle vertices)Just want surface data, separate from geometric data18Texture dataTexture data can come fromFiles: •Typically, 2D color


View Full Document

UCSD CSE 167 - Texture Mapping

Documents in this Course
Lighting

Lighting

38 pages

Review

Review

59 pages

Surfaces

Surfaces

22 pages

Review

Review

110 pages

Midterm

Midterm

4 pages

Lighting

Lighting

38 pages

Lighting

Lighting

71 pages

Review

Review

110 pages

Lighting

Lighting

71 pages

Load more
Download Texture Mapping
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 Texture Mapping 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 Texture Mapping 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?