SlideShare ist ein Scribd-Unternehmen logo
1 von 14
Window to viewport
Transformation
&
Matrix Representation of
Homogeneous Coordinates
What is window?
• A world-coordinate area
selected for display is called
a window.
• You can define the window
to be larger than, the same
size as, or smaller than the
actual range of data values,
depending on whether you
want to show all of the data
or only part of the data.
• Window defines what is to
be viewed.
What is viewport?
• An area on a display device
to which a window Is
mapped is called a viewport.
• The rectangular portion of
the interface window that
defines where the image will
actually appear.
• Viewport defines where the
window to be displayed.
If we are changing the position of window by keeping the
viewport location constant, then the different part of the object
is displayed at the same position on the display device.
If we change the location of viewport then we will see the same
part of the object drawn at different places on screen.
Window-to-Viewport
Transformation
• Window-to-Viewport transformation is the process of
mapping or transforming a two-dimensional, world-
coordinate scene to device coordinates.
• In particular, objects inside the world or clipping window
are mapped to the viewport.
• The clipping window is used to select the part of the scene
that is to be displayed. The viewport then positions the
scene on the output device.
Steps for Window to
Viewport Transformation
• Step 1: Translate window towards origin. To shift
window towards origin, translation factor will become
negative (-tx,-ty).
• Step 2: Resize window to the size of view port.
• Step 3: Translate window (position of window must be
same as position of view port).
Homogeneous Coordinates
• Being homogeneous means a uniform representation
of rotation, translation, scaling and other
transformations.
• Homogeneous coordinates are widely used in
computer graphics because they enable effective,
simple manipulations of transformations in a specific
way.
Why Homogeneous?
• We have to use 3×3 transformation matrix instead of 2×2
transformation matrix. To convert a 2×2 matrix to 3×3 matrix,
we have to add an extra dummy coordinate W.
• In this way, we can represent the point by 3 numbers instead of
2 numbers, which is called Homogenous Coordinate system.
• In this system, we can represent all the transformation
equations in matrix multiplication. Any Cartesian point P(X, Y)
can be converted to homogenous coordinates by P’ (Xh, Yh, h).
Window to viewport transformation&matrix representation of homogeneous coordinates

Weitere ähnliche Inhalte

Was ist angesagt?

Two dimensional viewing
Two dimensional viewingTwo dimensional viewing
Two dimensional viewing
Mohd Arif
 
Window to viewport transformation
Window to viewport transformationWindow to viewport transformation
Window to viewport transformation
Ankit Garg
 

Was ist angesagt? (20)

Clipping
ClippingClipping
Clipping
 
Two dimensional viewing
Two dimensional viewingTwo dimensional viewing
Two dimensional viewing
 
Output primitives in Computer Graphics
Output primitives in Computer GraphicsOutput primitives in Computer Graphics
Output primitives in Computer Graphics
 
Clipping computer graphics
Clipping  computer graphicsClipping  computer graphics
Clipping computer graphics
 
line attributes.pptx
line attributes.pptxline attributes.pptx
line attributes.pptx
 
Window to viewport transformation
Window to viewport transformationWindow to viewport transformation
Window to viewport transformation
 
Frame buffer
Frame bufferFrame buffer
Frame buffer
 
sutherland- Hodgeman Polygon clipping
sutherland- Hodgeman Polygon clippingsutherland- Hodgeman Polygon clipping
sutherland- Hodgeman Polygon clipping
 
2D viewing & clipping
2D viewing & clipping2D viewing & clipping
2D viewing & clipping
 
Reflection transformation
Reflection transformationReflection transformation
Reflection transformation
 
3D transformation in computer graphics
3D transformation in computer graphics3D transformation in computer graphics
3D transformation in computer graphics
 
Computer Graphics: Visible surface detection methods
Computer Graphics: Visible surface detection methodsComputer Graphics: Visible surface detection methods
Computer Graphics: Visible surface detection methods
 
Attributes of output primitive(line attributes)
Attributes of output primitive(line attributes)Attributes of output primitive(line attributes)
Attributes of output primitive(line attributes)
 
3 d display methods
3 d display methods3 d display methods
3 d display methods
 
3D Transformation
3D Transformation3D Transformation
3D Transformation
 
Video display devices
Video display devicesVideo display devices
Video display devices
 
3d transformation computer graphics
3d transformation computer graphics 3d transformation computer graphics
3d transformation computer graphics
 
Quadric surfaces
Quadric surfacesQuadric surfaces
Quadric surfaces
 
3 d viewing
3 d viewing3 d viewing
3 d viewing
 
Hidden surface removal
Hidden surface removalHidden surface removal
Hidden surface removal
 

Ähnlich wie Window to viewport transformation&matrix representation of homogeneous coordinates

Window to Viewport Transformation in Computer Graphics with.pptx
Window to Viewport Transformation in Computer Graphics with.pptxWindow to Viewport Transformation in Computer Graphics with.pptx
Window to Viewport Transformation in Computer Graphics with.pptx
Dolchandra
 
UNIT_3-Two-Dimensional-Geometric-Transformations.pdf
UNIT_3-Two-Dimensional-Geometric-Transformations.pdfUNIT_3-Two-Dimensional-Geometric-Transformations.pdf
UNIT_3-Two-Dimensional-Geometric-Transformations.pdf
VivekKumar148171
 
Computer Graphics lecture.pptx
Computer Graphics lecture.pptxComputer Graphics lecture.pptx
Computer Graphics lecture.pptx
NishkaSharma5
 
module 3 ppt2 (1).pptx
module 3 ppt2 (1).pptxmodule 3 ppt2 (1).pptx
module 3 ppt2 (1).pptx
RADHIKAB20
 

Ähnlich wie Window to viewport transformation&matrix representation of homogeneous coordinates (20)

Window to Viewport Transformation in Computer Graphics with.pptx
Window to Viewport Transformation in Computer Graphics with.pptxWindow to Viewport Transformation in Computer Graphics with.pptx
Window to Viewport Transformation in Computer Graphics with.pptx
 
Window to Viewport Transformation in Computer Graphics with.pptx
Window to Viewport Transformation in Computer Graphics with.pptxWindow to Viewport Transformation in Computer Graphics with.pptx
Window to Viewport Transformation in Computer Graphics with.pptx
 
Clipping CG ppt.pptx
Clipping CG ppt.pptxClipping CG ppt.pptx
Clipping CG ppt.pptx
 
Graphics_3D viewing
Graphics_3D viewingGraphics_3D viewing
Graphics_3D viewing
 
4. THREE DIMENSIONAL DISPLAY METHODS
4.	THREE DIMENSIONAL DISPLAY METHODS4.	THREE DIMENSIONAL DISPLAY METHODS
4. THREE DIMENSIONAL DISPLAY METHODS
 
UNIT_3-Two-Dimensional-Geometric-Transformations.pdf
UNIT_3-Two-Dimensional-Geometric-Transformations.pdfUNIT_3-Two-Dimensional-Geometric-Transformations.pdf
UNIT_3-Two-Dimensional-Geometric-Transformations.pdf
 
UNIT-III
UNIT-IIIUNIT-III
UNIT-III
 
Windows to viewport transformation
Windows to viewport transformationWindows to viewport transformation
Windows to viewport transformation
 
Introduction to Real Time Rendering
Introduction to Real Time RenderingIntroduction to Real Time Rendering
Introduction to Real Time Rendering
 
Unit 4 notes
Unit 4 notesUnit 4 notes
Unit 4 notes
 
Lec08112004.pdf
Lec08112004.pdfLec08112004.pdf
Lec08112004.pdf
 
affine transformation for computer graphics
affine transformation for computer graphicsaffine transformation for computer graphics
affine transformation for computer graphics
 
Bhavesh window clipping slidshare
Bhavesh window clipping slidshareBhavesh window clipping slidshare
Bhavesh window clipping slidshare
 
Computer Graphics lecture.pptx
Computer Graphics lecture.pptxComputer Graphics lecture.pptx
Computer Graphics lecture.pptx
 
3D Math Primer: CocoaConf Chicago
3D Math Primer: CocoaConf Chicago3D Math Primer: CocoaConf Chicago
3D Math Primer: CocoaConf Chicago
 
ch4.pptx
ch4.pptxch4.pptx
ch4.pptx
 
Notes04.pdf
Notes04.pdfNotes04.pdf
Notes04.pdf
 
3 d graphics with opengl part 2
3 d graphics with opengl  part 23 d graphics with opengl  part 2
3 d graphics with opengl part 2
 
module 3 ppt2 (1).pptx
module 3 ppt2 (1).pptxmodule 3 ppt2 (1).pptx
module 3 ppt2 (1).pptx
 
3D transformation and viewing
3D transformation and viewing3D transformation and viewing
3D transformation and viewing
 

Mehr von Mani Kanth

The sutherland hodgeman polygon clipping algorithm
The sutherland hodgeman polygon clipping algorithmThe sutherland hodgeman polygon clipping algorithm
The sutherland hodgeman polygon clipping algorithm
Mani Kanth
 
Raster and random scan display types of input devices
Raster and random scan display types of input devicesRaster and random scan display types of input devices
Raster and random scan display types of input devices
Mani Kanth
 
Polygon clipping with sutherland hodgeman algorithm and scan line fill algorithm
Polygon clipping with sutherland hodgeman algorithm and scan line fill algorithmPolygon clipping with sutherland hodgeman algorithm and scan line fill algorithm
Polygon clipping with sutherland hodgeman algorithm and scan line fill algorithm
Mani Kanth
 

Mehr von Mani Kanth (20)

White box testing
White box testing White box testing
White box testing
 
Unit testing
Unit testing Unit testing
Unit testing
 
System testing
System testingSystem testing
System testing
 
management of maintainance
management of maintainancemanagement of maintainance
management of maintainance
 
Se (techniques for black box testing ppt)
Se (techniques for black box testing ppt)Se (techniques for black box testing ppt)
Se (techniques for black box testing ppt)
 
Reverse engineering in software engineering vaibhav
Reverse engineering in software engineering vaibhavReverse engineering in software engineering vaibhav
Reverse engineering in software engineering vaibhav
 
Mutation testing 1
Mutation testing 1Mutation testing 1
Mutation testing 1
 
Mutation testing
Mutation testingMutation testing
Mutation testing
 
Guideline for euivalence class testing
Guideline for euivalence class testingGuideline for euivalence class testing
Guideline for euivalence class testing
 
Equivalence class testing
Equivalence  class testingEquivalence  class testing
Equivalence class testing
 
Deployment
DeploymentDeployment
Deployment
 
unit testing
unit testingunit testing
unit testing
 
The sutherland hodgeman polygon clipping algorithm
The sutherland hodgeman polygon clipping algorithmThe sutherland hodgeman polygon clipping algorithm
The sutherland hodgeman polygon clipping algorithm
 
Seed filling algorithm
Seed filling algorithmSeed filling algorithm
Seed filling algorithm
 
Scaling and shearing
Scaling and shearingScaling and shearing
Scaling and shearing
 
Raster and random scan display types of input devices
Raster and random scan display types of input devicesRaster and random scan display types of input devices
Raster and random scan display types of input devices
 
Projection
ProjectionProjection
Projection
 
Polygon clipping with sutherland hodgeman algorithm and scan line fill algorithm
Polygon clipping with sutherland hodgeman algorithm and scan line fill algorithmPolygon clipping with sutherland hodgeman algorithm and scan line fill algorithm
Polygon clipping with sutherland hodgeman algorithm and scan line fill algorithm
 
Mid point circle algorithm
Mid point circle algorithmMid point circle algorithm
Mid point circle algorithm
 
Graphics software and standards
Graphics software and standardsGraphics software and standards
Graphics software and standards
 

Kürzlich hochgeladen

Integrated Test Rig For HTFE-25 - Neometrix
Integrated Test Rig For HTFE-25 - NeometrixIntegrated Test Rig For HTFE-25 - Neometrix
Integrated Test Rig For HTFE-25 - Neometrix
Neometrix_Engineering_Pvt_Ltd
 
FULL ENJOY Call Girls In Mahipalpur Delhi Contact Us 8377877756
FULL ENJOY Call Girls In Mahipalpur Delhi Contact Us 8377877756FULL ENJOY Call Girls In Mahipalpur Delhi Contact Us 8377877756
FULL ENJOY Call Girls In Mahipalpur Delhi Contact Us 8377877756
dollysharma2066
 
Top Rated Call Girls In chittoor 📱 {7001035870} VIP Escorts chittoor
Top Rated Call Girls In chittoor 📱 {7001035870} VIP Escorts chittoorTop Rated Call Girls In chittoor 📱 {7001035870} VIP Escorts chittoor
Top Rated Call Girls In chittoor 📱 {7001035870} VIP Escorts chittoor
dharasingh5698
 
VIP Call Girls Palanpur 7001035870 Whatsapp Number, 24/07 Booking
VIP Call Girls Palanpur 7001035870 Whatsapp Number, 24/07 BookingVIP Call Girls Palanpur 7001035870 Whatsapp Number, 24/07 Booking
VIP Call Girls Palanpur 7001035870 Whatsapp Number, 24/07 Booking
dharasingh5698
 
Call Girls In Bangalore ☎ 7737669865 🥵 Book Your One night Stand
Call Girls In Bangalore ☎ 7737669865 🥵 Book Your One night StandCall Girls In Bangalore ☎ 7737669865 🥵 Book Your One night Stand
Call Girls In Bangalore ☎ 7737669865 🥵 Book Your One night Stand
amitlee9823
 
Call Girls in Netaji Nagar, Delhi 💯 Call Us 🔝9953056974 🔝 Escort Service
Call Girls in Netaji Nagar, Delhi 💯 Call Us 🔝9953056974 🔝 Escort ServiceCall Girls in Netaji Nagar, Delhi 💯 Call Us 🔝9953056974 🔝 Escort Service
Call Girls in Netaji Nagar, Delhi 💯 Call Us 🔝9953056974 🔝 Escort Service
9953056974 Low Rate Call Girls In Saket, Delhi NCR
 
Standard vs Custom Battery Packs - Decoding the Power Play
Standard vs Custom Battery Packs - Decoding the Power PlayStandard vs Custom Battery Packs - Decoding the Power Play
Standard vs Custom Battery Packs - Decoding the Power Play
Epec Engineered Technologies
 

Kürzlich hochgeladen (20)

(INDIRA) Call Girl Bhosari Call Now 8617697112 Bhosari Escorts 24x7
(INDIRA) Call Girl Bhosari Call Now 8617697112 Bhosari Escorts 24x7(INDIRA) Call Girl Bhosari Call Now 8617697112 Bhosari Escorts 24x7
(INDIRA) Call Girl Bhosari Call Now 8617697112 Bhosari Escorts 24x7
 
Thermal Engineering -unit - III & IV.ppt
Thermal Engineering -unit - III & IV.pptThermal Engineering -unit - III & IV.ppt
Thermal Engineering -unit - III & IV.ppt
 
Integrated Test Rig For HTFE-25 - Neometrix
Integrated Test Rig For HTFE-25 - NeometrixIntegrated Test Rig For HTFE-25 - Neometrix
Integrated Test Rig For HTFE-25 - Neometrix
 
(INDIRA) Call Girl Meerut Call Now 8617697112 Meerut Escorts 24x7
(INDIRA) Call Girl Meerut Call Now 8617697112 Meerut Escorts 24x7(INDIRA) Call Girl Meerut Call Now 8617697112 Meerut Escorts 24x7
(INDIRA) Call Girl Meerut Call Now 8617697112 Meerut Escorts 24x7
 
FULL ENJOY Call Girls In Mahipalpur Delhi Contact Us 8377877756
FULL ENJOY Call Girls In Mahipalpur Delhi Contact Us 8377877756FULL ENJOY Call Girls In Mahipalpur Delhi Contact Us 8377877756
FULL ENJOY Call Girls In Mahipalpur Delhi Contact Us 8377877756
 
Top Rated Call Girls In chittoor 📱 {7001035870} VIP Escorts chittoor
Top Rated Call Girls In chittoor 📱 {7001035870} VIP Escorts chittoorTop Rated Call Girls In chittoor 📱 {7001035870} VIP Escorts chittoor
Top Rated Call Girls In chittoor 📱 {7001035870} VIP Escorts chittoor
 
COST-EFFETIVE and Energy Efficient BUILDINGS ptx
COST-EFFETIVE  and Energy Efficient BUILDINGS ptxCOST-EFFETIVE  and Energy Efficient BUILDINGS ptx
COST-EFFETIVE and Energy Efficient BUILDINGS ptx
 
Introduction to Serverless with AWS Lambda
Introduction to Serverless with AWS LambdaIntroduction to Serverless with AWS Lambda
Introduction to Serverless with AWS Lambda
 
VIP Call Girls Palanpur 7001035870 Whatsapp Number, 24/07 Booking
VIP Call Girls Palanpur 7001035870 Whatsapp Number, 24/07 BookingVIP Call Girls Palanpur 7001035870 Whatsapp Number, 24/07 Booking
VIP Call Girls Palanpur 7001035870 Whatsapp Number, 24/07 Booking
 
2016EF22_0 solar project report rooftop projects
2016EF22_0 solar project report rooftop projects2016EF22_0 solar project report rooftop projects
2016EF22_0 solar project report rooftop projects
 
Unleashing the Power of the SORA AI lastest leap
Unleashing the Power of the SORA AI lastest leapUnleashing the Power of the SORA AI lastest leap
Unleashing the Power of the SORA AI lastest leap
 
22-prompt engineering noted slide shown.pdf
22-prompt engineering noted slide shown.pdf22-prompt engineering noted slide shown.pdf
22-prompt engineering noted slide shown.pdf
 
(INDIRA) Call Girl Aurangabad Call Now 8617697112 Aurangabad Escorts 24x7
(INDIRA) Call Girl Aurangabad Call Now 8617697112 Aurangabad Escorts 24x7(INDIRA) Call Girl Aurangabad Call Now 8617697112 Aurangabad Escorts 24x7
(INDIRA) Call Girl Aurangabad Call Now 8617697112 Aurangabad Escorts 24x7
 
Call Girls In Bangalore ☎ 7737669865 🥵 Book Your One night Stand
Call Girls In Bangalore ☎ 7737669865 🥵 Book Your One night StandCall Girls In Bangalore ☎ 7737669865 🥵 Book Your One night Stand
Call Girls In Bangalore ☎ 7737669865 🥵 Book Your One night Stand
 
chapter 5.pptx: drainage and irrigation engineering
chapter 5.pptx: drainage and irrigation engineeringchapter 5.pptx: drainage and irrigation engineering
chapter 5.pptx: drainage and irrigation engineering
 
VIP Model Call Girls Kothrud ( Pune ) Call ON 8005736733 Starting From 5K to ...
VIP Model Call Girls Kothrud ( Pune ) Call ON 8005736733 Starting From 5K to ...VIP Model Call Girls Kothrud ( Pune ) Call ON 8005736733 Starting From 5K to ...
VIP Model Call Girls Kothrud ( Pune ) Call ON 8005736733 Starting From 5K to ...
 
Unit 2- Effective stress & Permeability.pdf
Unit 2- Effective stress & Permeability.pdfUnit 2- Effective stress & Permeability.pdf
Unit 2- Effective stress & Permeability.pdf
 
Unit 1 - Soil Classification and Compaction.pdf
Unit 1 - Soil Classification and Compaction.pdfUnit 1 - Soil Classification and Compaction.pdf
Unit 1 - Soil Classification and Compaction.pdf
 
Call Girls in Netaji Nagar, Delhi 💯 Call Us 🔝9953056974 🔝 Escort Service
Call Girls in Netaji Nagar, Delhi 💯 Call Us 🔝9953056974 🔝 Escort ServiceCall Girls in Netaji Nagar, Delhi 💯 Call Us 🔝9953056974 🔝 Escort Service
Call Girls in Netaji Nagar, Delhi 💯 Call Us 🔝9953056974 🔝 Escort Service
 
Standard vs Custom Battery Packs - Decoding the Power Play
Standard vs Custom Battery Packs - Decoding the Power PlayStandard vs Custom Battery Packs - Decoding the Power Play
Standard vs Custom Battery Packs - Decoding the Power Play
 

Window to viewport transformation&matrix representation of homogeneous coordinates

  • 1. Window to viewport Transformation & Matrix Representation of Homogeneous Coordinates
  • 2. What is window? • A world-coordinate area selected for display is called a window. • You can define the window to be larger than, the same size as, or smaller than the actual range of data values, depending on whether you want to show all of the data or only part of the data. • Window defines what is to be viewed. What is viewport? • An area on a display device to which a window Is mapped is called a viewport. • The rectangular portion of the interface window that defines where the image will actually appear. • Viewport defines where the window to be displayed.
  • 3. If we are changing the position of window by keeping the viewport location constant, then the different part of the object is displayed at the same position on the display device. If we change the location of viewport then we will see the same part of the object drawn at different places on screen.
  • 4. Window-to-Viewport Transformation • Window-to-Viewport transformation is the process of mapping or transforming a two-dimensional, world- coordinate scene to device coordinates. • In particular, objects inside the world or clipping window are mapped to the viewport. • The clipping window is used to select the part of the scene that is to be displayed. The viewport then positions the scene on the output device.
  • 5.
  • 6. Steps for Window to Viewport Transformation • Step 1: Translate window towards origin. To shift window towards origin, translation factor will become negative (-tx,-ty). • Step 2: Resize window to the size of view port. • Step 3: Translate window (position of window must be same as position of view port).
  • 7.
  • 8.
  • 9.
  • 10.
  • 11.
  • 12. Homogeneous Coordinates • Being homogeneous means a uniform representation of rotation, translation, scaling and other transformations. • Homogeneous coordinates are widely used in computer graphics because they enable effective, simple manipulations of transformations in a specific way.
  • 13. Why Homogeneous? • We have to use 3×3 transformation matrix instead of 2×2 transformation matrix. To convert a 2×2 matrix to 3×3 matrix, we have to add an extra dummy coordinate W. • In this way, we can represent the point by 3 numbers instead of 2 numbers, which is called Homogenous Coordinate system. • In this system, we can represent all the transformation equations in matrix multiplication. Any Cartesian point P(X, Y) can be converted to homogenous coordinates by P’ (Xh, Yh, h).