SlideShare a Scribd company logo
1 of 14
C. Graphics
Key Board
Flat Panel Display
Conversion Between HSV and
RGB
LCD, Plasma
LED
KEYBOARD
• Primary device for entering text string
• Input non-graphics data
• Features:- Cursor-Control, Function Keys
• Other features:- menu selection, graphics function, screen
coordinate
• Buttons, dials and switches are used to give the input to
graphic application
FLAT-PANEL DISPLAY
• Video devices with reduced volume, weight and power
• Portable
• Applications:- TV monitors, Calculators, laptops etc.
• Can hangs on walls and wear in wrists
• Two types
Emissive Display
Non-Emissive Display
LED
• Light Emitting Diode
• Matrix of diodes are arranged to form a display pattern
• Picture definition stored in refresh buffer
• Information are extracted from buffer and converted to voltage
level and applied to diode to produce light in the display
PLASMA
• Plasma is also called gas-discharge display.
• It is constructed by filling region between two glass plates with a
mixture of gases that usually include neon .
• The space between these two ribbon includes gases.
• when firing voltage is applied the effect of vertical and horizontal
ribbon causes the gas to break down that produce glowing plasma of
electron and ion.
• Picture definition is stored in refresh buffer and firing voltage is
applied to refresh the pixel position 60 times per second.
LCD
1. System that use LCD have less volume, less weight, less power consumption.
2. The term liquid crystal refers to the fact that these compound have crystalline arrangement of
molecules, yet they flow like liquid.
3. Flat panel display commonly use nematic liquid crystal compound that tend to keep the long axes of
rod-shaped molecules aligned.
4. LCD works with light.
5. There are few component in one pixel of LCD they are : Back Light, Polarizer(Horizontal, Vertical),
LCD, RGB.
6. At first the light transmit from back light to polarizer (Horizontal, Vertical) which filters vertical light if
it is horizontal polarizer and filters horizontal light if it is vertical polarizer.
7. Then the light transmit to LCD which changes from horizontal to vertical or vice-versa of which the
other end of polarizer is able to receive the light form transmitted by LCD.
LCD CONTD..
8. At the second polarizer it receives light , filters it and passes it next.
9. After that the light is received by RGB which gives the light according to the light received.
10. RGB has 256 values each from 0-255 which gives combination of several colors.
11. LCD it self contains three components . They are : Glass plate , Electrode, LCD molecules.
12. When electrode is inactive the form of light of changed.
13. When electrode is active the molecules changes its form which results that the LCD does not change
light from horizontal - vertical or vice versa .
14. After that the receiving polarizer cannot receive the light.
15. That results in RGB also not receiving the light where the value of RGB will be 0,0,0 which results in
forming the color black.
16. If the value of RGB will be 255,255,255 it forms white color
CONVERSION BETWEEN HSV AND
RGB
HSV TO RGB
void hsvTorgb( float *r, float *g, float *b, float h, float s, float v )
{
int i;
float f, p, q, t;
if( s == 0 ) { // achromatic (grey)
*r = *g = *b = v;
return;
}
h /= 60; // sector 0 to 5
i = ffloor( h );
f = h - i; // factorial part of h
p = v * ( 1 - s );
q = v * ( 1 - s * f );
t = v * ( 1 - s * ( 1 - f ) );
HSV TO RGB CONTD..
switch( i ) {
case 0:
*r = v;*g = t;*b = p;
break;
case 1:
*r = q;*g = v;*b = p;
break;
case 2:
*r = p;*g = v;*b = t;
break;
case 3:
*r = p;*g = q;*b = v;
break;
HSV TO RGB CONTD..
case 4:
*r = t;*g = p;*b = v;
break;
Case 5:
*r = v;*g = p;*b = q;
break;
}
}
RGB TO HSV
// r,g,b values are from 0 to 1
// h = [0,360], s = [0,1], v = [0,1]
void rgbTohsb( float r, float g, float b, float *h, float *s,
float *v )
{
float min, max, delta;
min = MIN( r, g, b );
max = MAX( r, g, b );
*v = max; // v
delta = max - min;
if( max != 0 )
*s = delta / max; // s
else {
// r = g = b = 0 // s = 0, v is undefined
*s = 0;
return;
}
RGB TO HSV CONTD..
if( r == max )
*h = ( g - b ) / delta; // between yellow & magenta
else if( g == max )
*h = 2 + ( b - r ) / delta; // between cyan & yellow
else
*h = 4 + ( r - g ) / delta; // between magenta & cyan
*h *= 60; // degrees
if( *h < 0 )
*h += 360;
}
THANK
YOU

More Related Content

Similar to Computer Graphics

Practical Spherical Harmonics Based PRT Methods
Practical Spherical Harmonics Based PRT MethodsPractical Spherical Harmonics Based PRT Methods
Practical Spherical Harmonics Based PRT Methods
Naughty Dog
 
project - Copy
project - Copyproject - Copy
project - Copy
piedaholic
 

Similar to Computer Graphics (20)

Persistence of Vision Display
Persistence of Vision DisplayPersistence of Vision Display
Persistence of Vision Display
 
Practical Spherical Harmonics Based PRT Methods
Practical Spherical Harmonics Based PRT MethodsPractical Spherical Harmonics Based PRT Methods
Practical Spherical Harmonics Based PRT Methods
 
project report
project reportproject report
project report
 
ARM instruction set
ARM instruction  setARM instruction  set
ARM instruction set
 
Digital clock workshop
Digital clock workshopDigital clock workshop
Digital clock workshop
 
Cg colg
Cg colgCg colg
Cg colg
 
Object counter
Object counterObject counter
Object counter
 
DLD_Lecture_notes2.ppt
DLD_Lecture_notes2.pptDLD_Lecture_notes2.ppt
DLD_Lecture_notes2.ppt
 
Digital Components
Digital ComponentsDigital Components
Digital Components
 
FPGA implementation of universal modulator using CORDIC algorithm for commun...
FPGA implementation of universal modulator using CORDIC  algorithm for commun...FPGA implementation of universal modulator using CORDIC  algorithm for commun...
FPGA implementation of universal modulator using CORDIC algorithm for commun...
 
Arduino - Ch 2: Sunrise-Sunset Light Switch
Arduino - Ch 2: Sunrise-Sunset Light SwitchArduino - Ch 2: Sunrise-Sunset Light Switch
Arduino - Ch 2: Sunrise-Sunset Light Switch
 
Making a peaking filter by Julio Marqués
Making a peaking filter by Julio MarquésMaking a peaking filter by Julio Marqués
Making a peaking filter by Julio Marqués
 
PIC Microcontroller
PIC MicrocontrollerPIC Microcontroller
PIC Microcontroller
 
project - Copy
project - Copyproject - Copy
project - Copy
 
Gcc 4 15-16
Gcc 4 15-16Gcc 4 15-16
Gcc 4 15-16
 
Paris Master Class 2011 - 05 Post-Processing Pipeline
Paris Master Class 2011 - 05 Post-Processing PipelineParis Master Class 2011 - 05 Post-Processing Pipeline
Paris Master Class 2011 - 05 Post-Processing Pipeline
 
Computer Organization And Architecture lab manual
Computer Organization And Architecture lab manualComputer Organization And Architecture lab manual
Computer Organization And Architecture lab manual
 
Manual QUBINO zmnhwd1
Manual QUBINO zmnhwd1Manual QUBINO zmnhwd1
Manual QUBINO zmnhwd1
 
Unit iv microcontrollers final
Unit iv microcontrollers finalUnit iv microcontrollers final
Unit iv microcontrollers final
 
Electronz_Chapter_4.pptx
Electronz_Chapter_4.pptxElectronz_Chapter_4.pptx
Electronz_Chapter_4.pptx
 

Recently uploaded

Salient Features of India constitution especially power and functions
Salient Features of India constitution especially power and functionsSalient Features of India constitution especially power and functions
Salient Features of India constitution especially power and functions
KarakKing
 

Recently uploaded (20)

HMCS Vancouver Pre-Deployment Brief - May 2024 (Web Version).pptx
HMCS Vancouver Pre-Deployment Brief - May 2024 (Web Version).pptxHMCS Vancouver Pre-Deployment Brief - May 2024 (Web Version).pptx
HMCS Vancouver Pre-Deployment Brief - May 2024 (Web Version).pptx
 
COMMUNICATING NEGATIVE NEWS - APPROACHES .pptx
COMMUNICATING NEGATIVE NEWS - APPROACHES .pptxCOMMUNICATING NEGATIVE NEWS - APPROACHES .pptx
COMMUNICATING NEGATIVE NEWS - APPROACHES .pptx
 
Kodo Millet PPT made by Ghanshyam bairwa college of Agriculture kumher bhara...
Kodo Millet  PPT made by Ghanshyam bairwa college of Agriculture kumher bhara...Kodo Millet  PPT made by Ghanshyam bairwa college of Agriculture kumher bhara...
Kodo Millet PPT made by Ghanshyam bairwa college of Agriculture kumher bhara...
 
Understanding Accommodations and Modifications
Understanding  Accommodations and ModificationsUnderstanding  Accommodations and Modifications
Understanding Accommodations and Modifications
 
This PowerPoint helps students to consider the concept of infinity.
This PowerPoint helps students to consider the concept of infinity.This PowerPoint helps students to consider the concept of infinity.
This PowerPoint helps students to consider the concept of infinity.
 
Single or Multiple melodic lines structure
Single or Multiple melodic lines structureSingle or Multiple melodic lines structure
Single or Multiple melodic lines structure
 
How to setup Pycharm environment for Odoo 17.pptx
How to setup Pycharm environment for Odoo 17.pptxHow to setup Pycharm environment for Odoo 17.pptx
How to setup Pycharm environment for Odoo 17.pptx
 
On_Translating_a_Tamil_Poem_by_A_K_Ramanujan.pptx
On_Translating_a_Tamil_Poem_by_A_K_Ramanujan.pptxOn_Translating_a_Tamil_Poem_by_A_K_Ramanujan.pptx
On_Translating_a_Tamil_Poem_by_A_K_Ramanujan.pptx
 
Interdisciplinary_Insights_Data_Collection_Methods.pptx
Interdisciplinary_Insights_Data_Collection_Methods.pptxInterdisciplinary_Insights_Data_Collection_Methods.pptx
Interdisciplinary_Insights_Data_Collection_Methods.pptx
 
FSB Advising Checklist - Orientation 2024
FSB Advising Checklist - Orientation 2024FSB Advising Checklist - Orientation 2024
FSB Advising Checklist - Orientation 2024
 
Salient Features of India constitution especially power and functions
Salient Features of India constitution especially power and functionsSalient Features of India constitution especially power and functions
Salient Features of India constitution especially power and functions
 
Mehran University Newsletter Vol-X, Issue-I, 2024
Mehran University Newsletter Vol-X, Issue-I, 2024Mehran University Newsletter Vol-X, Issue-I, 2024
Mehran University Newsletter Vol-X, Issue-I, 2024
 
HMCS Max Bernays Pre-Deployment Brief (May 2024).pptx
HMCS Max Bernays Pre-Deployment Brief (May 2024).pptxHMCS Max Bernays Pre-Deployment Brief (May 2024).pptx
HMCS Max Bernays Pre-Deployment Brief (May 2024).pptx
 
On National Teacher Day, meet the 2024-25 Kenan Fellows
On National Teacher Day, meet the 2024-25 Kenan FellowsOn National Teacher Day, meet the 2024-25 Kenan Fellows
On National Teacher Day, meet the 2024-25 Kenan Fellows
 
80 ĐỀ THI THỬ TUYỂN SINH TIẾNG ANH VÀO 10 SỞ GD – ĐT THÀNH PHỐ HỒ CHÍ MINH NĂ...
80 ĐỀ THI THỬ TUYỂN SINH TIẾNG ANH VÀO 10 SỞ GD – ĐT THÀNH PHỐ HỒ CHÍ MINH NĂ...80 ĐỀ THI THỬ TUYỂN SINH TIẾNG ANH VÀO 10 SỞ GD – ĐT THÀNH PHỐ HỒ CHÍ MINH NĂ...
80 ĐỀ THI THỬ TUYỂN SINH TIẾNG ANH VÀO 10 SỞ GD – ĐT THÀNH PHỐ HỒ CHÍ MINH NĂ...
 
Key note speaker Neum_Admir Softic_ENG.pdf
Key note speaker Neum_Admir Softic_ENG.pdfKey note speaker Neum_Admir Softic_ENG.pdf
Key note speaker Neum_Admir Softic_ENG.pdf
 
Basic Civil Engineering first year Notes- Chapter 4 Building.pptx
Basic Civil Engineering first year Notes- Chapter 4 Building.pptxBasic Civil Engineering first year Notes- Chapter 4 Building.pptx
Basic Civil Engineering first year Notes- Chapter 4 Building.pptx
 
General Principles of Intellectual Property: Concepts of Intellectual Proper...
General Principles of Intellectual Property: Concepts of Intellectual  Proper...General Principles of Intellectual Property: Concepts of Intellectual  Proper...
General Principles of Intellectual Property: Concepts of Intellectual Proper...
 
ICT role in 21st century education and it's challenges.
ICT role in 21st century education and it's challenges.ICT role in 21st century education and it's challenges.
ICT role in 21st century education and it's challenges.
 
How to Create and Manage Wizard in Odoo 17
How to Create and Manage Wizard in Odoo 17How to Create and Manage Wizard in Odoo 17
How to Create and Manage Wizard in Odoo 17
 

Computer Graphics

  • 1. C. Graphics Key Board Flat Panel Display Conversion Between HSV and RGB LCD, Plasma LED
  • 2. KEYBOARD • Primary device for entering text string • Input non-graphics data • Features:- Cursor-Control, Function Keys • Other features:- menu selection, graphics function, screen coordinate • Buttons, dials and switches are used to give the input to graphic application
  • 3. FLAT-PANEL DISPLAY • Video devices with reduced volume, weight and power • Portable • Applications:- TV monitors, Calculators, laptops etc. • Can hangs on walls and wear in wrists • Two types Emissive Display Non-Emissive Display
  • 4. LED • Light Emitting Diode • Matrix of diodes are arranged to form a display pattern • Picture definition stored in refresh buffer • Information are extracted from buffer and converted to voltage level and applied to diode to produce light in the display
  • 5. PLASMA • Plasma is also called gas-discharge display. • It is constructed by filling region between two glass plates with a mixture of gases that usually include neon . • The space between these two ribbon includes gases. • when firing voltage is applied the effect of vertical and horizontal ribbon causes the gas to break down that produce glowing plasma of electron and ion. • Picture definition is stored in refresh buffer and firing voltage is applied to refresh the pixel position 60 times per second.
  • 6. LCD 1. System that use LCD have less volume, less weight, less power consumption. 2. The term liquid crystal refers to the fact that these compound have crystalline arrangement of molecules, yet they flow like liquid. 3. Flat panel display commonly use nematic liquid crystal compound that tend to keep the long axes of rod-shaped molecules aligned. 4. LCD works with light. 5. There are few component in one pixel of LCD they are : Back Light, Polarizer(Horizontal, Vertical), LCD, RGB. 6. At first the light transmit from back light to polarizer (Horizontal, Vertical) which filters vertical light if it is horizontal polarizer and filters horizontal light if it is vertical polarizer. 7. Then the light transmit to LCD which changes from horizontal to vertical or vice-versa of which the other end of polarizer is able to receive the light form transmitted by LCD.
  • 7. LCD CONTD.. 8. At the second polarizer it receives light , filters it and passes it next. 9. After that the light is received by RGB which gives the light according to the light received. 10. RGB has 256 values each from 0-255 which gives combination of several colors. 11. LCD it self contains three components . They are : Glass plate , Electrode, LCD molecules. 12. When electrode is inactive the form of light of changed. 13. When electrode is active the molecules changes its form which results that the LCD does not change light from horizontal - vertical or vice versa . 14. After that the receiving polarizer cannot receive the light. 15. That results in RGB also not receiving the light where the value of RGB will be 0,0,0 which results in forming the color black. 16. If the value of RGB will be 255,255,255 it forms white color
  • 9. HSV TO RGB void hsvTorgb( float *r, float *g, float *b, float h, float s, float v ) { int i; float f, p, q, t; if( s == 0 ) { // achromatic (grey) *r = *g = *b = v; return; } h /= 60; // sector 0 to 5 i = ffloor( h ); f = h - i; // factorial part of h p = v * ( 1 - s ); q = v * ( 1 - s * f ); t = v * ( 1 - s * ( 1 - f ) );
  • 10. HSV TO RGB CONTD.. switch( i ) { case 0: *r = v;*g = t;*b = p; break; case 1: *r = q;*g = v;*b = p; break; case 2: *r = p;*g = v;*b = t; break; case 3: *r = p;*g = q;*b = v; break;
  • 11. HSV TO RGB CONTD.. case 4: *r = t;*g = p;*b = v; break; Case 5: *r = v;*g = p;*b = q; break; } }
  • 12. RGB TO HSV // r,g,b values are from 0 to 1 // h = [0,360], s = [0,1], v = [0,1] void rgbTohsb( float r, float g, float b, float *h, float *s, float *v ) { float min, max, delta; min = MIN( r, g, b ); max = MAX( r, g, b ); *v = max; // v delta = max - min; if( max != 0 ) *s = delta / max; // s else { // r = g = b = 0 // s = 0, v is undefined *s = 0; return; }
  • 13. RGB TO HSV CONTD.. if( r == max ) *h = ( g - b ) / delta; // between yellow & magenta else if( g == max ) *h = 2 + ( b - r ) / delta; // between cyan & yellow else *h = 4 + ( r - g ) / delta; // between magenta & cyan *h *= 60; // degrees if( *h < 0 ) *h += 360; }