Presentation is loading. Please wait.

Presentation is loading. Please wait.

I N T R O D U C T I O N T O C O M P U T E R G R A P H I C S Andries van Dam October 1, 2002 Introduction to Computer Graphics 1/82 Constructive Solid Geometry.

Similar presentations


Presentation on theme: "I N T R O D U C T I O N T O C O M P U T E R G R A P H I C S Andries van Dam October 1, 2002 Introduction to Computer Graphics 1/82 Constructive Solid Geometry."— Presentation transcript:

1 I N T R O D U C T I O N T O C O M P U T E R G R A P H I C S Andries van Dam October 1, 2002 Introduction to Computer Graphics 1/82 Constructive Solid Geometry (CSG), Volume Graphics, and Color Basics, concluded

2 I N T R O D U C T I O N T O C O M P U T E R G R A P H I C S Andries van Dam October 1, 2002 Introduction to Computer Graphics 2/82 English-language names –ambiguous and subjective Numeric coordinates in color space with slide dials: Interactive Specification of Color (1/2) Left: Lab color picker from Adobe Photoshop for Windows Below: RGB color picker from Adobe Photoshop for Mac OS

3 I N T R O D U C T I O N T O C O M P U T E R G R A P H I C S Andries van Dam October 1, 2002 Introduction to Computer Graphics 3/82 Interact with visual representation of the color space Important for user to see actual display with new color Beware of surround effect! Interactive Specification of Color (2/2) HSB color picker from Adobe Photoshop HSV color picker from Mac OS X’s Finder

4 I N T R O D U C T I O N T O C O M P U T E R G R A P H I C S Andries van Dam October 1, 2002 Introduction to Computer Graphics 4/82 Interpolation needed for: –Gouraud shading –antialiasing –blending images together in a fade-in, fade-out sequence Results depend on the color model used: –RGB, CMY, YIQ, CIE are related by affine transformations, hence straight line (i.e., interpolation paths) are maintained during mapping –not so for HSV, HLS; for example, interpolation between red and green in RGB: –interpolating in HSV: midpoint values in RGB differ by 0.5 from same interpolation in HSV: (60º, 1, 0.5)  (60º, 1, 1) Interpolating in Color Space (1/2) red = (0 º, 1, 1); green = (120 º, 1, 1) midpoint = (60 º, 1, 1) RGB_to_HSV = (60 º, 1, 0.5) red = (1, 0, 0), green = (0, 1, 0) midpoint = (0.5, 0.5, 0)

5 I N T R O D U C T I O N T O C O M P U T E R G R A P H I C S Andries van Dam October 1, 2002 Introduction to Computer Graphics 5/82 RGB, red is (1, 0, 0) and cyan is (0, 1, 1) which interpolate to (0.5, 0.5, 0.5), gray –in HSV, that is (UNDEFINED, 0, 0.5) In HSV, red is (0º, 1, 1) and cyan is (180º, 1, 1) which interpolates to (90º, 1, 1) –new hue at maximum value and saturation, whereas the “right” result of combining equal amounts of complementary colors is a gray value Thus, interpolating, transforming transforming, interpolating For Gouraud shading (see Rendering unit), use any of the models because interpolants are generally so close together that interpolation paths are close together For blending two images, as in fade-in fade-out sequence or for antialiasing, colors may be quite distant –use additive model, such as RGB If interpolating between two colors of fixed hue (or saturation), maintain fixed hue (saturation) for all interpolated colors by HSV or HLS –note fixed-saturation interpolation in HSV or HLS is not seen as having exactly fixed saturation by viewer! Interpolating in Color Space (2/2)

6 I N T R O D U C T I O N T O C O M P U T E R G R A P H I C S Andries van Dam October 1, 2002 Introduction to Computer Graphics 6/82 Aesthetic uses: –establish a tone or mood –promote realism Highlight Code numeric quantities –temperature across the U.S. –vegetation and mineral concentrations on Earth, moon, and planets (LandSat, Mars missions) –speed of fluids in computational fluid dynamics (streamlines) Using Color in Computer Graphics

7 I N T R O D U C T I O N T O C O M P U T E R G R A P H I C S Andries van Dam October 1, 2002 Introduction to Computer Graphics 7/82 Careless use of color is perilous –in experiment, color reduced user performance by one-third Decorative use of color subservient to functional use: –test with real users –provide “best judgment” defaults –allow user to override defaults –design first for a monochrome display (color use is redundant in monochrome displays and for color-blind users) Using Color in Computer Graphics: Functionality

8 I N T R O D U C T I O N T O C O M P U T E R G R A P H I C S Andries van Dam October 1, 2002 Introduction to Computer Graphics 8/82 Color harmony: –select colors according to some method, typically by traversing a smooth path in a color model –restrict colors to planes or hexcones in a color space –space colors at equal perceptual distances –light-dark contrast more important than hue contrast Specifics: –if a chart contains just a few colors, the complement of one of the colors should be used as the background –use neutral (gray) background for an image with many colors –separate non-harmonious colors by thin black border Coding: –be redundant (“dual coding”) –show reference scale –color can carry unintended meanings: bright, saturated colors stand out (may give unintended emphasis) display elements of same color may incorrectly be associated by user Using Color in Computer Graphics Approach

9 I N T R O D U C T I O N T O C O M P U T E R G R A P H I C S Andries van Dam October 1, 2002 Introduction to Computer Graphics 9/82 Eye is more sensitive to spatial variation –fine detail should vary from the background not just in chromaticity, but in brightness Blue and black, yellow and white are particularly bad combinations –don’t use blue for text For color-blind users, avoid reds and greens with low saturation and luminance Color of small objects less than 20-40 minutes of arc are not distinguishable Using Color in Computer Graphics: Physiological Rules (1/2) This is hard to read. So is this. And this, too! Yikes!

10 I N T R O D U C T I O N T O C O M P U T E R G R A P H I C S Andries van Dam October 1, 2002 Introduction to Computer Graphics 10/82 Difficult to perceive color when used with small objects => don’t use color coding for them Perceived color of object is affected by color of surrounding area Strongly saturated colors produce after images Color affects perceived size –red seen as larger than green –colors refract differently through our lens: appear at different depths, e.g., red (closer) vs. blue (farther) strongest effect Apply color conservatively, not gratuitously – “color-itis” as bad as “font-itis” Using Color in Computer Graphics: Physiological Rules (2/2)

11 I N T R O D U C T I O N T O C O M P U T E R G R A P H I C S Andries van Dam October 1, 2002 Introduction to Computer Graphics 11/82 To describe the character of light (ignoring phase) requires an infinity of amplitude – wavelength data – light spectra lie in an infinite-dimensional space Human perception, below certain intensity levels, is not at all linear At reasonable levels light perception is log-linear; displays also not linear, influences color-table design “Less is More” in judicious use of color – use some simple guidelines based on aesthetics and psychophysics Take Away Ideas If you are interested in learning more about color, check out Anne Morgan Spalter’s book, The Computer in the Visual Arts, available on Amazon.com

12 I N T R O D U C T I O N T O C O M P U T E R G R A P H I C S Andries van Dam October 1, 2002 Introduction to Computer Graphics 12/82 For more on color, check out the following web sites: Color Matters –http://www.colormatters.comhttp://www.colormatters.com Educational Color Applets –http://www.cs.rit.edu/~ncs/color/http://www.cs.rit.edu/~ncs/color/ Gamma FAQ and Color FAQ –http://www.inforamp.net/~poynton/Poynton-colour.htmlhttp://www.inforamp.net/~poynton/Poynton-colour.html More Frequently Asked Questions about color –http://www.ergogero.com/FAQ/cfaqhome.htmlhttp://www.ergogero.com/FAQ/cfaqhome.html –info on color blindness and the way we interpret color Comprehensive List of Color Models –http://www.colorsystem.com/http://www.colorsystem.com/ Online book on color –http://www.colorvoodoo.com/cvoodoo4.htmlhttp://www.colorvoodoo.com/cvoodoo4.html Map Coloring –http://www.personal.psu.edu/faculty/c/a/cab38/http://www.personal.psu.edu/faculty/c/a/cab38/ Get your own color cube!!! –http://www.colorcube.com/intro.htmhttp://www.colorcube.com/intro.htm Excerpt from Thomas Young’s paper –http://kiptron.psyc.virginia.edu/steve_boker/ColorVision2/node5.htmlhttp://kiptron.psyc.virginia.edu/steve_boker/ColorVision2/node5.html For More Information


Download ppt "I N T R O D U C T I O N T O C O M P U T E R G R A P H I C S Andries van Dam October 1, 2002 Introduction to Computer Graphics 1/82 Constructive Solid Geometry."

Similar presentations


Ads by Google