Graphics Hardware

Download Report

Transcript Graphics Hardware

Display Technologies

A TYPICAL GRAPHICS SYSTEM

A Typical graphics system consists of  Processor  Memory  Frame Buffer  Output Devices  Input Devices Prepared by Narendra V G CSE MIT 4/27/2020 7:47 PM 2

A TYPICAL GRAPHICS SYSTEM

keyboard processor Frame buffer mouse memory Drawing tablet 4/27/2020 7:47 PM Prepared by Narendra V G CSE MIT 3

VECTOR GRAPHICS SYSTEMS

Vector (or stroke, line drawing or calligraphic) displays were developed in mid-sixties and were in common use until mid-eighties.

 In these devices , everything is displayed as a

combination of lines

(even characters)  Typically it consists of

display processor

connected as an

I/O peripheral to CPU

,

a display buffer memory and a CRT

. The buffer stores the computer-produced display list or display program; it contains point, line character plotting commands (opcodes) Prepared by Narendra V G CSE MIT 4 4/27/2020 7:47 PM

ARCHITECTURE OF A VECTOR DISPLAY

.

Move 10 15 Line 400 300 Char Lu Cy Line .

.

.

JMP Refresh buffer 4/27/2020 7:47 PM Interface with host computer (display commands) (interaction data) Display controller(DC) Lucy Prepared by Narendra V G CSE MIT 5

Output Technology (1/3)

 Calligraphic Displays  also called vector, stroke or line drawing graphics  lines drawn directly on phosphor  display processor directs electron beam according to list of lines defined in a "

display list

“  phosphors glow for only a few micro-seconds so lines must be redrawn or

refreshed

constantly  deflection speed limits # of lines that can be drawn without flicker.

Prepared by Narendra V G CSE MIT 6 4/27/2020 7:47 PM

Output Technology (2/3)

 Raster Display  Display

primitives

(lines, shaded regions, characters) stored as pixels in

refresh buffer

(or

frame buffer

)  Electron beam scans a regular pattern of horizontal raster lines connected by horizontal retraces and vertical retrace  Video controller coordinates the repeated scanning  Pixels are individual dots on a raster line Prepared by Narendra V G CSE MIT 7 4/27/2020 7:47 PM

Output Technology (cont)

 Bitmap is the collection of pixels  Frame buffer stores the bitmap  Raster display store the display primitives (line, characters, and solid shaded or patterned area)  Frame buffers  are composed of

VRAM

(video RAM).  VRAM is dual-ported memory capable of  Random access  Simultaneous high-speed serial output: built-in

serial shift register

can output entire

scanline

at high rate synchronized to

pixel clock.

8

Pros and Cons

 Advantages to Raster Displays  lower cost  filled regions/shaded images  Disadvantages to Raster Displays  a discrete representation, continuous primitives must be

scan-converted

(i.e. fill in the appropriate scan lines) 

Aliasing

or "

jaggies

" Arises due to sampling error when converting from a continuous to a discrete representation Prepared by Narendra V G CSE MIT 4/27/2020 7:47 PM 9

Basic Definitions

 Raster: A rectangular array of points or dots.

 Pixel (Pel): One dot or picture element of the raster  Scan line: A row of pixels Video raster devices display an image by sequentially drawing out the pixels of the scan lines that form the raster.

Prepared by Narendra V G CSE MIT 10 4/27/2020 7:47 PM

Resolution

 Maximum number of points that can be displayed without overlap on a CRT monitor  Dependent on 

Type of phosphor m

Intensity to be displayed m

Focusing and deflection systems m

 REL SGI O2 monitors: 1280 x 1024 Prepared by Narendra V G CSE MIT 11 4/27/2020 7:47 PM

Example

   

Television

 

NTSC GA-HDTV Workstations

 

Bitmapped display Color workstation 640x480x8b 1920x1080x8b 960x1152x1b 1280x1024x24b 1/4 MB ~2 MB ~1 Mb 5 MB Laserprinters

 

300 dpi 2400 dpi (8.5”x300)(11”x300) 1.05 MB (8.5”x2400)(11”x2400) ~64 MB Film (line pairs/mm)

35mm (diagonal) slide (ASA25~125 lp/mm) = 3000 3000 x 2000 x 3 x 12b ~27 MB

Prepared by Narendra V G CSE MIT 4/27/2020 7:47 PM 12

Aspect Ratio

Frame aspect ratio (FAR) = horizontal/vertical size TV 4:3 16:9 HDTV Page 35mm Panavision Vistavision 3:2 8.5:11 ~ 3/4 2.35:1 (2:1 anamorphic) 2.35:1 (1.5 anamorphic) Pixel aspect ratio (PAR) = FAR vres/hres Nuisance in graphics if not 1 Prepared by Narendra V G CSE MIT 4/27/2020 7:47 PM 13

Physical Size

 Physical size: Length of the screen diagonal (typically 12 to 27 inches)  REL SGI O2 monitors: 19 inches 4/27/2020 7:47 PM Prepared by Narendra V G CSE MIT 14

Refresh Rates and Bandwidth

 Frames per second (FPS)  Film (double framed) 24 FPS  TV (interlaced) 30 FPS x 1/4 = 8 MB/s  Workstation (non-interlaced) 75 FPS x 5 = 375 MB/s 4/27/2020 7:47 PM Prepared by Narendra V G CSE MIT 15

Interlaced Scanning

 Scan frame 30 times per second  To reduce flicker, divide frame into two fields odd scan lines.

—one consisting of the even scan lines and the other of the  Even and odd fields are scanned out alternately to produce an interlaced image.

1/60 SEC FIELD 1 1/30 SEC 1/60 SEC FIELD 2 FRAME

4/27/2020 7:47 PM

1/60 SEC FIELD 1 1/30 SEC

Prepared by Narendra V G CSE MIT

FRAME 1/60 SEC FIELD 2

16

Frame Buffer

   A frame buffer is characterized by is size, x, y, and pixel depth.

the

resolution

of a frame buffer is the number of pixels in the display. e.g. 1024x1024 pixels.

Bit Planes or Bit Depth is the number of bits corresponding to each pixel. This determines the

color resolution

of the buffer.

4/27/2020 7:47 PM

Bilevel

or

monochrome

displays have 1 bit/pixel (128Kbytes of RAM) 8bits/pixel -> 256 simultaneous colors 24bits/pixel -> 16 million simultaneous colors Prepared by Narendra V G CSE MIT 17

Specifying Color

8

 direct color :  each pixel directly specifies a color value  e.g., 24bit : 8bits(R) + 8bits(G) + 8 bits(B)  palette-based color : indirect specification  use palette (CLUT)  e.g., 8 bits pixel can represent 256 colors 4/27/2020 7:47 PM

8 8

24 bits plane, 8 bits per color gun.

2 24 = 16,777,216 Prepared by Narendra V G CSE MIT

Red Green Blue

18

Lookup Tables

 Video controller often uses a lookup table to allow indirection of display values in frame buffer.

    Allows flexible use of colors without lots of frame-buffer memory.

Allows change of display without remapping underlying data double buffering .

Permits simple animation.

Common sizes: 8 x 12; 8 x 24; 12 x 24.

4/27/2020 7:47 PM Prepared by Narendra V G CSE MIT 19

Color Look-Up Table

y Frame Buffer 0 CLUT 127 x 127 2083 00000000 00000100 00010011 to red gun to green gun to blue gun 255 Prepared by Narendra V G CSE MIT 4/27/2020 7:47 PM 20

Pseudo Color

255 254 RED GREEN BLUE 256 colors chosen from a palette of 16,777,216. Each entry in the color map LUT can be user defined.

4/27/2020 7:47 PM

3 2 1 0

Prepared by Narendra V G CSE MIT 21

RASTER GRAPHICS SYSTEM

One of the important achievements in graphics is the development of

raster graphics

early seventies in Raster displays store the display primitives (points, lines etc.) in refresh buffer in terms of their

component pixels

Prepared by Narendra V G CSE MIT 22 4/27/2020 7:47 PM

ARCHITECTURE OF A RASTER DISPLAY

INTERFACE WITH HOST COMPUTER (DIPSLAY COMMANDS) (INTERACTION DATA) DISPLAY CONTROLLER(DC) KEYBOARD MOUSE 000000000000000000000000000000 000000000000000000000111000000 000000000000000000001100000000 000000000000000000000001100000 000000000011110000000000000000 000000011111111110000000000000 000111111111111111111000000000 000111110000000011111000000000 000111111111111111111000000000 000111111110001111111000000000 000111111110001111111000000000 000111111110001111111000000000 000111111111111111111000000000 000000000000000000000000000000 VIDEO CONTROLLER Prepared by Narendra V G CSE MIT 23

RASTER SCAN AND ADVANTAGES

Scan line Horizontal retrace Vertical retrace 4/27/2020 7:47 PM Raster Scan Advantages : Lower cost ability to display solid colors and patterns independent of texture and complexity Disadvantages: discrete nature of pixel representation(jagged edges) need scan conversion need raster Prepared by Narendra V G CSE MIT 24

4/27/2020 7:47 PM Prepared by Narendra V G CSE MIT 25

Basic video controller refresh operations

Raster Scan generator Horizontal and vertical deflection voltages X register Y register Memory address Pixel register intensity Frame Buffer Prepared by Narendra V G CSE MIT 4/27/2020 7:47 PM 26

Comparing Raster and Vector (1/2)

 advantages of vector:  very fine detail of line drawings (sometimes curves), whereas raster suffers from jagged edge problem due to pixels (aliasing, quantization errors)  geometry objects (lines) whereas raster only handles pixels  eg. 1000 line plot: vector disply computes 2000 endpoints  raster display computes all pixels on each line 27

Comparing Raster and Vector (2/2)

 advantages of raster:  cheaper  colours, textures, realism  unlimited complexity of picture: whatever you put in refresh buffer, whereas vector complexity limited by refresh rate 28

Cathode ray tube

 Foremost requirement of a graphics hardware is that the screen should be dynamic.

 Refresh rate for raster scan displays is usually 60 frames per second (independent of picture complexity)  Note that in vector display, refresh rate depends directly on the picture complexity. Greater the complexity, greater the refresh cycle.

Prepared by Narendra V G CSE MIT 29 4/27/2020 7:47 PM

 Cathode Ray Tubes (CRTs)  Most common display device today  Evacuated glass bottle (last of the vacuum tubes)  Heating element (filament)  Electrons pulled towards anode focusing cylinder  Vertical and horizontal deflection plates  Beam strikes phosphor coating on front of tube 30

Deflections achieved by adjusting current through the coils.

4/27/2020 7:47 PM Prepared by Narendra V G CSE MIT 31

4/27/2020 7:47 PM Prepared by Narendra V G CSE MIT 32

4/27/2020 7:47 PM Prepared by Narendra V G CSE MIT 33

 Black and white television: an oscilloscope with a fixed scan pattern: left to right, top to bottom  Paint entire screen 30 times/sec   Actually, TVs paint top-to-bottom 60 times/sec, alternating between even and odd

scanlines

This is called

interlacing

. It’s a hack.

Why do it?

 To paint the screen, computer needs to synchronize with the scanning pattern of raster  Solution: special memory to buffer image with scan-out synchronous to the raster. We call this the

framebuffer

.

CRT facts

    15,000 to 20,000 volts is the voltage used to accelerate the electron beam Control grid determines how many electrons are in the beam, thus controlling intensity. (The more negative the control-grid voltage is, the fewer the electrons that pass through the grid) The spot is “focused” in order to cancel the divergence due to repulsion.

Spot is Gaussian distributed (no sharp edge) and is 0.005 inches in diameter.

Prepared by Narendra V G CSE MIT 35 4/27/2020 7:47 PM

Fluorescence Vs Phosphorescence

  Electron beam hits the phosphor-coated screen with a kinetic energy that is proportional to the acceleration voltage.

Phosphors are characterized by   color(usually red, green and blue) persistence, which is the time for the emitted light to decay to 10% of the initial intensity. High persistence is good for low refresh rates, but bad for animation (“trail” is left behind with moving objects).

Prepared by Narendra V G CSE MIT 36 4/27/2020 7:47 PM

Fluorescence Vs Phosphorescence

(cont)    When electron beam hits the screen….

After some dissipation due to heat, rest of the energy is transferred to electrons of the phosphor atoms, making them jump to higher quantum energy levels.

The excited electrons then return to their previous quantum levels by giving up extra energy in the form of light, at frequencies predicted by quantum theory.

37 4/27/2020 7:47 PM Prepared by Narendra V G CSE MIT

Fluorescence Vs Phosphorescence

(cont)     Any given phosphor has several different quantum levels to an unexcited state. Further, electrons on some levels are less stable and return to the unexcited state more rapidly than others. A phosphor’s Fluorescence

unstable electrons lose their excess energy while phosphor is being struck by electrons.

is the light emitted as these very Phosphorescence is the light given off by the return of relatively

more stable excited electrons to their unexcited state once the electron beam excitation is removed.

Typically, most of the light emitted is phosphorescence, since the excitation and the fluorescence usually just lasts a fraction

of a microsecond.

Prepared by Narendra V G CSE MIT 38 4/27/2020 7:47 PM

Flat-Panel Displays

     Class of video devices that have reduced volume, weight, and power requirements compared to a CRT. They are significantly thinner.

Flat panels: i) emissive, ii) nonemissive.

Emissive displays (or emitters) are devices that convert electrical energy into light. Ex. Plasma panels, thin-film electoluminescent displays, Light Emitting Diodes (LEDs).

(note: Flat CRTs have also been designed but not popular/successful) Nonemissive flat-panel displays use optical effects to convert sunlight or light from some other source into graphics patterns. Ex. Liquid-crystal device.

Prepared by Narendra V G CSE MIT 39 4/27/2020 7:47 PM

4/27/2020 7:47 PM Prepared by Narendra V G CSE MIT 40

Plasma panels

 Constructed by filling the region between glass plates with a mixture of gases, usually including neon.

 A series of vertical conducting ribbons is placed on one glass panel, horizontal on the other.

 Voltages are fired to an intersecting pair to break down a glowing plasma of electrons and ions. Refresh rate is 60 frames per sec.

Prepared by Narendra V G CSE MIT 4/27/2020 7:47 PM 41

4/27/2020 7:47 PM Prepared by Narendra V G CSE MIT 42

Display Technology: LCD

 Liquid Crystal Displays (LCDs)  Liquid crystal – these compounds have a crystalline arrangement of molecules, yet they flow like a liquid  LCSs are commonly used in small systems such as laptops, calculators  LCDs: organic molecules, naturally in crystalline state, that liquify when excited by heat or E field  Crystalline state twists polarized light 90º Prepared by Narendra V G CSE MIT 43 4/27/2020 7:47 PM

LCD..

    Produces a picture by passing polarized light from the surroundings or from an internal light source through a liquid-crystal material that can either block or transmit the light.

The intersection of the two conductors defines a pixel position.

Polarized light is twisted as it passes through the opposite polarizer. The light is then reflected back to the viewer.

To turn off the pixel, voltage is applied to the two intersecting conductors to align the molecules so that the light is not twisted.

Prepared by Narendra V G CSE MIT 44 4/27/2020 7:47 PM

4/27/2020 7:47 PM Prepared by Narendra V G CSE MIT 45

Color

   Color is achieved by having three electron guns mixing the colors red , green and blue (RGB).

White is perceived when all are illuminated and when all are off its black.

Typically each color is specified by an 8-bit value . Thus 8*3=24 bits are needed to represent a color pixel(also called true color).

4/27/2020 7:47 PM Prepared by Narendra V G CSE MIT 46

Color

(cont)

256 entry 8bits 24 bits

 Storing say 24 bits of information for each pixel of a (say), 1000*1000 screen eats up 3 Megabytes of memory. Thus low end graphics workstations use a more economical approach. They use 8 bits per pixel where each 8-bit entry is an index into a 256-entry color map. Each entry in the color map is a 24-bit value containing R,G,B components of the color. This is color-Indexing.

4/27/2020 7:47 PM Prepared by Narendra V G CSE MIT 47

Display Technology: Color CRTs

 Color CRTs are

much

more complicated  Requires manufacturing very precise geometry  Uses a pattern of color phosphors on the screen: Delta electron gun arrangement In-line electron gun arrangement 

Why red, green, and blue phosphors?

4/27/2020 7:47 PM Prepared by Narendra V G CSE MIT 49

 Color CRTs have  Three electron guns  A metal

shadow mask

beams to differentiate the

 Raster CRT pros:  Allows solids, not just wireframes  Leverages low-cost CRT technology (i.e., TVs)  Bright! Display

emits

light  Cons:  Requires screen-size memory array  Discreet sampling (pixels)  Practical limit on size (call it 40 inches)  Bulky  Finicky (convergence, warp, etc)

Frame Buffer

 A frame buffer is a large contiguous piece of computer memory.

 At a minimum, there is one memory bit for each pixel (picture element) in the raster; this amount of memory is called bit plane   A 1024 * 1024 element square raster requires 2 20 or 1,048,576 ( 2 display).

10 *2 10 ) memory bits in a single bit plane. Each bit has 2 states (monochrome Conversion from digital to analog is done by DAC

(digital-to-analog converter).

Prepared by Narendra V G CSE MIT 52 4/27/2020 7:47 PM

Frame Buffer raster CRT device

1

Register

DAC

Electron Gun Frame Buffer CRT Raster

A single-bit-plane(1 bit per pixel) Black and White frame buffer raster CRT graphics device 4/27/2020 7:47 PM Prepared by Narendra V G CSE MIT 53

Color and Gray levels

   Color or gray levels are incorporated into a frame buffer by adding additional bit planes.

The binary value from each of the N bit planes is loaded into corresponding positions into a register. The resulting binary number is interpreted as an intensity level between 0 (dark) and 2

N -1(full intensity)

A Raster with 3 bit planes generates 8 (2 3,145,728 ( 3 * 1024 * 1024) memory bits.

3 ) intensity levels. In this case, the frame buffer should have Prepared by Narendra V G CSE MIT 4/27/2020 7:47 PM 54

An N bit gray level frame buffer

Register

N N

0 Frame Buffer 0 1 0 1 0 2 2 N DAC N=3 2 N levels Electron gun CRT Raster

55 4/27/2020 7:47 PM Prepared by Narendra V G CSE MIT

3

Simple color frame buffer

0 1 0 0 1 0 DAC DAC DAC Frame Buffer

4/27/2020 7:47 PM Prepared by Narendra V G CSE MIT

CRT RASTER

56

3 Bit plane frame buffer color combinations

Black Red Green Blue Yellow Cyan White 4/27/2020 7:47 PM Red 0 1 0 Green 0 0 1 0 1 0 1 0 1 1 1 Prepared by Narendra V G CSE MIT Blue 0 0 0 1 0 1 1 57

8 8

A 24 Bit plane color frame buffer

registers 0 1 0 0 1 0 1 1 Blue 75 3 bit DAC Color Guns 8 1 0 1 0 1 1 0 0 Green 172 3 bit DAC 0 0 0 0 1 0 1 0 Red 10 3 bit DAC Frame Buffer

4/27/2020 7:47 PM Prepared by Narendra V G CSE MIT

CRT Raster

58

Gray Level Frame Buffer with Look Up table

1 0 0 1 0 2 1 0 1 0 10 2w DAC Electron Gun 0 2 N entries Frame Buffer N=3 Lookup tables W=4 An N Bit plane Gray Level frame buffer, with W-bit-wide lookup table CRT Raster

59 4/27/2020 7:47 PM Prepared by Narendra V G CSE MIT

Color frame buffer(24 bit plane) with lookup tables(10 Bit wide)

W=10 N=8 2 N entries

4/27/2020 7:47 PM

W=10 W=10 W bit DAC W bit DAC CRT Raster

60

Resolution

   

Resolution

 The Maximum number of points that are displayed without overlap.  This is usually given as the number of horizontal points versus the number of vertical points. These points are called pixels or picture elements.

The maximum resolution may be determined by the characteristics of the monitor for a random scan system or by a combination of monitor and graphics card memory for a raster scan system. Typical resolution on high-quality systems is 1280 by 1024, higher also available.

Physical size of the graphics monitor is measured as length of the screen diagonal which generally varies from 12 in. to 27in.

Prepared by Narendra V G CSE MIT 61 4/27/2020 7:47 PM

Aspect Ratio

  

Aspect Ratio

 The aspect ratio is the ratio of horizontal dimension/vertical dimension.

Example

 If the monitor dimensions are 8 inches by 6 inches, the aspect ratio is 8/6 which is equal 1.33.

 If the resolution of the screen is 640 by 480, the length of the pixel is 640/8 equal to 80 pixels per inch. Similarly height is 480/6 equal to 80 pixels per inch. Thus the pixel is a square.

If the horizontal size of a pixel is not equal to the vertical size, then it must be corrected for image display else the image will appear distorted.

Prepared by Narendra V G CSE MIT 62 4/27/2020 7:47 PM

Image resolutions in practice

   WORKSTATIONS   Bitmapped display 960 * 1152* 1b approx 1MB Color Display 1280* 1024*24b approx 5MB TELEVISION   NTSC 640*480*8b approx ¼ MB HDTV 1980*1080*8b approx 2 MB LASER PRINTERS   300 dpi (8.5*300)(11*300) approx 1.05 MB 2400 dpi (8.5*2400)(11*2400) approx 64MB Prepared by Narendra V G CSE MIT 4/27/2020 7:47 PM 63

Speed requirements and scanning rates

  Speed requirements for memory access  1024*768*8 = 768 Kbytes= 786,432 bytes  Read 786*10

3

60) for 60 HZ.

bytes in 1600*10

-5

secs (inverse of Rough estimation of scanning rates.  Frequency X number of vertical lines (note scan always means a full horizontal scan)   Example: for an IBM VGA 60*480 = 30 HZ For 1024 * 768 = 46 Khz Prepared by Narendra V G CSE MIT 4/27/2020 7:47 PM 64

Dot size and Addressability

The image quality achievable with display devices depends on both the addressability and the dot size of the device.

Dot (spot) size is the diameter of the single dot created on the device.

 

Addressability is the number of individual dots per inch that can be created; it may differ in horizontal and vertical directions.

Addressability in x is the reciprocal of the distance between the centers of dots at addresses (x,y) and (x+1,y). Similarly the other direction is calculated. Prepared by Narendra V G CSE MIT 65 4/27/2020 7:47 PM

Interdot distance

  Interdot distance is the reciprocal of addressability It is usually desirable that the dot size be somewhat greater than the interdot distance, so that smooth shapes can be created.

66 4/27/2020 7:47 PM Prepared by Narendra V G CSE MIT