SlideShare una empresa de Scribd logo
1 de 9
WINDOWING AND CLIPPING
Polygon clipping:-

For Polytechnic Diploma in Computer Enggineering
/Computer Technology/PGDCA/BCA Students.




                               Created By:
                               Krishna Jadhav RLPC
                               Buldana(kparth.jadhav@gmail.com)
Sutherland-Hodgeman Polygon Clipping:
•We can clip polygon by considering whole polygon against each
boundary edge of the window.
•We know that represent a polygon we need set of vertices.
•We will pass this set of vertices or a polygon to a procedure which
will clip the polygon against left edge.
1. This left procedure generates new set of vertices which indicates
   left clipped polygon.
2. Again we will get new set of vertices is passed to the right
   boundary clipper procedure.
3. Then we will pass this new set of vertices to bottom boundary
   clipper and lastly to top boundary clipper procedure.




                                                Krishna Jadhav RLPC
                                                Buldana(kparth.jadhav@gmail.com)
Sutherland-Hodgeman Polygon Clipping:
     •At the end of every clipping stage a new set of vertices is
     generated and this new set of vertices(Modified polygon) is
     passed to the next clipping stage.
     Following fig. shows four diff. stages which are require to clip a
     polygon.


                  Left                Right             Bottom

                  Clip                Clip              Clip

Polygon      Window
                                     Top

                                     Clip



                                                     Krishna Jadhav RLPC
                                                     Buldana(kparth.jadhav@gmail.com)
Sutherland-Hodgeman Polygon Clipping:
•When we are clipping a polygon with respect to any particular
edge of the window at that time we have to consider following
diff. cases.
•Case1: If the vertex is outside the window boundary and the
second vertex is inside the window, then the intersection point of
polygon with boundary edge of window and the vertex which is
inside the window is stored in q output list. For Edge AB instead of
storing vertex A and B we are storing P1 & B in o/p vertex list.


        P1
A              B                Store P1 and B in Output Vertex list.


               C

    D
    Polygon        Window                       Krishna Jadhav RLPC
                                                Buldana(kparth.jadhav@gmail.com)
Sutherland-Hodgeman Polygon Clipping:
•Case2: If Both, First and second vertex of a polygon are lying
inside the window, then we have to store the second vertex only
output vertex list.




                             Store only C in Output Vertex list.




                                               Krishna Jadhav RLPC
                                               Buldana(kparth.jadhav@gmail.com)
Sutherland-Hodgeman Polygon Clipping:
•Case3: If the first vertex is inside the window and second vertex is
outside the window(opposite to Case 1), then we have to store only
intersection point of that edge of polygon with window in output
vertex list.


                              Store only P2 in Output Vertex list.




      P2




                                               Krishna Jadhav RLPC
                                               Buldana(kparth.jadhav@gmail.com)
Sutherland-Hodgeman Polygon Clipping:
•Case4: If both first and second vertex of polygon are lying outside
the window then no vertex is stored in output window.




                             Nothing stored in output vertex list.




                                               Krishna Jadhav RLPC
                                               Buldana(kparth.jadhav@gmail.com)
Sutherland-Hodgeman Polygon Clipping:
        Once all vertices have been considered for one clip window
        boundary, the output list of vertices is clipped against the next
        window boundary.

          So the Block diagram for this algorithm.




Input                                      Bottom            Top                 Clipped
              Left           Right
              Clip           Clip          Clip              Clip                Polygon
Polygon




                                                         Krishna Jadhav RLPC
                                                         Buldana(kparth.jadhav@gmail.com)
CHAPTER 5
  CURVES AND FRACTALS:-
Curve generation method:-


                Under Construction…….




                            Krishna Jadhav RLPC
                            Buldana(kparth.jadhav@gmail.com)

Más contenido relacionado

La actualidad más candente

Visual realism -HIDDEN REMOVAL METHODS
Visual realism -HIDDEN REMOVAL METHODSVisual realism -HIDDEN REMOVAL METHODS
Visual realism -HIDDEN REMOVAL METHODSviswaaswaran
 
Unit 3 visual realism
Unit 3 visual realismUnit 3 visual realism
Unit 3 visual realismJavith Saleem
 
The sutherland hodgeman polygon clipping algorithm
The sutherland hodgeman polygon clipping algorithmThe sutherland hodgeman polygon clipping algorithm
The sutherland hodgeman polygon clipping algorithmMani Kanth
 
Computer graphics - bresenham line drawing algorithm
Computer graphics - bresenham line drawing algorithmComputer graphics - bresenham line drawing algorithm
Computer graphics - bresenham line drawing algorithmRuchi Maurya
 
Computer graphics curves and surfaces (1)
Computer graphics curves and surfaces (1)Computer graphics curves and surfaces (1)
Computer graphics curves and surfaces (1)RohitK71
 
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 algorithmMani Kanth
 
Mid point circle algorithm
Mid point circle algorithmMid point circle algorithm
Mid point circle algorithmMani Kanth
 
Bezeir curve na B spline Curve
Bezeir curve na B spline CurveBezeir curve na B spline Curve
Bezeir curve na B spline CurvePooja Dixit
 
Two dimensional geometric transformations
Two dimensional geometric transformationsTwo dimensional geometric transformations
Two dimensional geometric transformationsMohammad Sadiq
 
Solid modeling-Sweep Representation and B-representation
Solid modeling-Sweep Representation and B-representationSolid modeling-Sweep Representation and B-representation
Solid modeling-Sweep Representation and B-representationDestro Destro
 
Wireframe models
Wireframe modelsWireframe models
Wireframe modelsMohd Arif
 
Bezier Curve and Spline Curve
Bezier Curve and Spline CurveBezier Curve and Spline Curve
Bezier Curve and Spline CurveAsifShahariar1
 
Clipping computer graphics
Clipping  computer graphicsClipping  computer graphics
Clipping computer graphicsShaishavShah8
 
HOMOGENEOUS CO-ORDINATES IN COMPUTER GRAPHICS PPT
HOMOGENEOUS CO-ORDINATES IN COMPUTER GRAPHICS PPTHOMOGENEOUS CO-ORDINATES IN COMPUTER GRAPHICS PPT
HOMOGENEOUS CO-ORDINATES IN COMPUTER GRAPHICS PPTAhtesham Ullah khan
 
Windowing clipping
Windowing   clippingWindowing   clipping
Windowing clippingShweta Shah
 

La actualidad más candente (20)

Visual realism -HIDDEN REMOVAL METHODS
Visual realism -HIDDEN REMOVAL METHODSVisual realism -HIDDEN REMOVAL METHODS
Visual realism -HIDDEN REMOVAL METHODS
 
Unit 3 visual realism
Unit 3 visual realismUnit 3 visual realism
Unit 3 visual realism
 
Curves and surfaces
Curves and surfacesCurves and surfaces
Curves and surfaces
 
The sutherland hodgeman polygon clipping algorithm
The sutherland hodgeman polygon clipping algorithmThe sutherland hodgeman polygon clipping algorithm
The sutherland hodgeman polygon clipping algorithm
 
Computer graphics - bresenham line drawing algorithm
Computer graphics - bresenham line drawing algorithmComputer graphics - bresenham line drawing algorithm
Computer graphics - bresenham line drawing algorithm
 
Bezier curve computer graphics
Bezier curve computer graphicsBezier curve computer graphics
Bezier curve computer graphics
 
Computer graphics curves and surfaces (1)
Computer graphics curves and surfaces (1)Computer graphics curves and surfaces (1)
Computer graphics curves and surfaces (1)
 
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
 
BRESENHAM’S LINE DRAWING ALGORITHM
BRESENHAM’S  LINE DRAWING ALGORITHMBRESENHAM’S  LINE DRAWING ALGORITHM
BRESENHAM’S LINE DRAWING ALGORITHM
 
Bezeir curve na B spline Curve
Bezeir curve na B spline CurveBezeir curve na B spline Curve
Bezeir curve na B spline Curve
 
Two dimensional geometric transformations
Two dimensional geometric transformationsTwo dimensional geometric transformations
Two dimensional geometric transformations
 
Clipping ( Cohen-Sutherland Algorithm )
Clipping ( Cohen-Sutherland Algorithm )Clipping ( Cohen-Sutherland Algorithm )
Clipping ( Cohen-Sutherland Algorithm )
 
Solid modeling-Sweep Representation and B-representation
Solid modeling-Sweep Representation and B-representationSolid modeling-Sweep Representation and B-representation
Solid modeling-Sweep Representation and B-representation
 
Wireframe models
Wireframe modelsWireframe models
Wireframe models
 
Bezier Curve and Spline Curve
Bezier Curve and Spline CurveBezier Curve and Spline Curve
Bezier Curve and Spline Curve
 
Clipping computer graphics
Clipping  computer graphicsClipping  computer graphics
Clipping computer graphics
 
HOMOGENEOUS CO-ORDINATES IN COMPUTER GRAPHICS PPT
HOMOGENEOUS CO-ORDINATES IN COMPUTER GRAPHICS PPTHOMOGENEOUS CO-ORDINATES IN COMPUTER GRAPHICS PPT
HOMOGENEOUS CO-ORDINATES IN COMPUTER GRAPHICS PPT
 
Clipping
ClippingClipping
Clipping
 
Windowing clipping
Windowing   clippingWindowing   clipping
Windowing clipping
 

Destacado

Segments in Graphics
Segments in GraphicsSegments in Graphics
Segments in GraphicsRajani Thite
 
Clipping Algorithm In Computer Graphics
Clipping Algorithm In Computer GraphicsClipping Algorithm In Computer Graphics
Clipping Algorithm In Computer Graphicsstudent(MCA)
 
Computer graphics 9068
Computer graphics  9068Computer graphics  9068
Computer graphics 90681061992
 
Computer graphics
Computer graphicsComputer graphics
Computer graphicsbhaveshbunk
 
Bresenham's line algo.
Bresenham's line algo.Bresenham's line algo.
Bresenham's line algo.Mohd Arif
 
Two dimensionaltransformations
Two dimensionaltransformationsTwo dimensionaltransformations
Two dimensionaltransformationsNareek
 
Computer Graphics Notes
Computer Graphics NotesComputer Graphics Notes
Computer Graphics NotesGurpreet singh
 
Quadric surfaces
Quadric surfacesQuadric surfaces
Quadric surfacesAnkur Kumar
 
Cohen and Sutherland Algorithm for 7-8 marks
Cohen and Sutherland Algorithm for 7-8 marksCohen and Sutherland Algorithm for 7-8 marks
Cohen and Sutherland Algorithm for 7-8 marksRehan Khan
 
Hidden surfaces
Hidden surfacesHidden surfaces
Hidden surfacesMohd Arif
 

Destacado (20)

Clipping
ClippingClipping
Clipping
 
Segments in Graphics
Segments in GraphicsSegments in Graphics
Segments in Graphics
 
Clipping Algorithm In Computer Graphics
Clipping Algorithm In Computer GraphicsClipping Algorithm In Computer Graphics
Clipping Algorithm In Computer Graphics
 
unit-1-intro
 unit-1-intro unit-1-intro
unit-1-intro
 
Computer graphics 9068
Computer graphics  9068Computer graphics  9068
Computer graphics 9068
 
Windowing in apex
Windowing in apexWindowing in apex
Windowing in apex
 
clipping
clippingclipping
clipping
 
Computer graphics
Computer graphicsComputer graphics
Computer graphics
 
Bresenham's line algo.
Bresenham's line algo.Bresenham's line algo.
Bresenham's line algo.
 
Two dimensionaltransformations
Two dimensionaltransformationsTwo dimensionaltransformations
Two dimensionaltransformations
 
Segmentation Techniques -I
Segmentation Techniques -ISegmentation Techniques -I
Segmentation Techniques -I
 
Clipping
ClippingClipping
Clipping
 
Bezier Curve
Bezier Curve Bezier Curve
Bezier Curve
 
3 d viewing
3 d viewing3 d viewing
3 d viewing
 
Computer Graphics Notes
Computer Graphics NotesComputer Graphics Notes
Computer Graphics Notes
 
Quadric surfaces
Quadric surfacesQuadric surfaces
Quadric surfaces
 
Cohen and Sutherland Algorithm for 7-8 marks
Cohen and Sutherland Algorithm for 7-8 marksCohen and Sutherland Algorithm for 7-8 marks
Cohen and Sutherland Algorithm for 7-8 marks
 
visible surface detection
visible surface detectionvisible surface detection
visible surface detection
 
06 clipping
06 clipping06 clipping
06 clipping
 
Hidden surfaces
Hidden surfacesHidden surfaces
Hidden surfaces
 

Último

Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...apidays
 
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot TakeoffStrategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoffsammart93
 
presentation ICT roal in 21st century education
presentation ICT roal in 21st century educationpresentation ICT roal in 21st century education
presentation ICT roal in 21st century educationjfdjdjcjdnsjd
 
Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...apidays
 
Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024The Digital Insurer
 
Polkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin WoodPolkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin WoodJuan lago vázquez
 
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024The Digital Insurer
 
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...DianaGray10
 
2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...Martijn de Jong
 
Understanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdfUnderstanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdfUK Journal
 
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...Neo4j
 
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data DiscoveryTrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data DiscoveryTrustArc
 
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationFrom Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationSafe Software
 
HTML Injection Attacks: Impact and Mitigation Strategies
HTML Injection Attacks: Impact and Mitigation StrategiesHTML Injection Attacks: Impact and Mitigation Strategies
HTML Injection Attacks: Impact and Mitigation StrategiesBoston Institute of Analytics
 
Top 5 Benefits OF Using Muvi Live Paywall For Live Streams
Top 5 Benefits OF Using Muvi Live Paywall For Live StreamsTop 5 Benefits OF Using Muvi Live Paywall For Live Streams
Top 5 Benefits OF Using Muvi Live Paywall For Live StreamsRoshan Dwivedi
 
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc
 
GenAI Risks & Security Meetup 01052024.pdf
GenAI Risks & Security Meetup 01052024.pdfGenAI Risks & Security Meetup 01052024.pdf
GenAI Risks & Security Meetup 01052024.pdflior mazor
 
Strategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a FresherStrategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a FresherRemote DBA Services
 
Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)wesley chun
 

Último (20)

Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
 
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot TakeoffStrategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
 
presentation ICT roal in 21st century education
presentation ICT roal in 21st century educationpresentation ICT roal in 21st century education
presentation ICT roal in 21st century education
 
Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...
 
Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024
 
Polkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin WoodPolkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin Wood
 
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
 
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
 
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
 
2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...
 
Understanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdfUnderstanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdf
 
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
 
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data DiscoveryTrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
 
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationFrom Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
 
HTML Injection Attacks: Impact and Mitigation Strategies
HTML Injection Attacks: Impact and Mitigation StrategiesHTML Injection Attacks: Impact and Mitigation Strategies
HTML Injection Attacks: Impact and Mitigation Strategies
 
Top 5 Benefits OF Using Muvi Live Paywall For Live Streams
Top 5 Benefits OF Using Muvi Live Paywall For Live StreamsTop 5 Benefits OF Using Muvi Live Paywall For Live Streams
Top 5 Benefits OF Using Muvi Live Paywall For Live Streams
 
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
 
GenAI Risks & Security Meetup 01052024.pdf
GenAI Risks & Security Meetup 01052024.pdfGenAI Risks & Security Meetup 01052024.pdf
GenAI Risks & Security Meetup 01052024.pdf
 
Strategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a FresherStrategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a Fresher
 
Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)
 

Windowing and clipping final1

  • 1. WINDOWING AND CLIPPING Polygon clipping:- For Polytechnic Diploma in Computer Enggineering /Computer Technology/PGDCA/BCA Students. Created By: Krishna Jadhav RLPC Buldana(kparth.jadhav@gmail.com)
  • 2. Sutherland-Hodgeman Polygon Clipping: •We can clip polygon by considering whole polygon against each boundary edge of the window. •We know that represent a polygon we need set of vertices. •We will pass this set of vertices or a polygon to a procedure which will clip the polygon against left edge. 1. This left procedure generates new set of vertices which indicates left clipped polygon. 2. Again we will get new set of vertices is passed to the right boundary clipper procedure. 3. Then we will pass this new set of vertices to bottom boundary clipper and lastly to top boundary clipper procedure. Krishna Jadhav RLPC Buldana(kparth.jadhav@gmail.com)
  • 3. Sutherland-Hodgeman Polygon Clipping: •At the end of every clipping stage a new set of vertices is generated and this new set of vertices(Modified polygon) is passed to the next clipping stage. Following fig. shows four diff. stages which are require to clip a polygon. Left Right Bottom Clip Clip Clip Polygon Window Top Clip Krishna Jadhav RLPC Buldana(kparth.jadhav@gmail.com)
  • 4. Sutherland-Hodgeman Polygon Clipping: •When we are clipping a polygon with respect to any particular edge of the window at that time we have to consider following diff. cases. •Case1: If the vertex is outside the window boundary and the second vertex is inside the window, then the intersection point of polygon with boundary edge of window and the vertex which is inside the window is stored in q output list. For Edge AB instead of storing vertex A and B we are storing P1 & B in o/p vertex list. P1 A B Store P1 and B in Output Vertex list. C D Polygon Window Krishna Jadhav RLPC Buldana(kparth.jadhav@gmail.com)
  • 5. Sutherland-Hodgeman Polygon Clipping: •Case2: If Both, First and second vertex of a polygon are lying inside the window, then we have to store the second vertex only output vertex list. Store only C in Output Vertex list. Krishna Jadhav RLPC Buldana(kparth.jadhav@gmail.com)
  • 6. Sutherland-Hodgeman Polygon Clipping: •Case3: If the first vertex is inside the window and second vertex is outside the window(opposite to Case 1), then we have to store only intersection point of that edge of polygon with window in output vertex list. Store only P2 in Output Vertex list. P2 Krishna Jadhav RLPC Buldana(kparth.jadhav@gmail.com)
  • 7. Sutherland-Hodgeman Polygon Clipping: •Case4: If both first and second vertex of polygon are lying outside the window then no vertex is stored in output window. Nothing stored in output vertex list. Krishna Jadhav RLPC Buldana(kparth.jadhav@gmail.com)
  • 8. Sutherland-Hodgeman Polygon Clipping: Once all vertices have been considered for one clip window boundary, the output list of vertices is clipped against the next window boundary. So the Block diagram for this algorithm. Input Bottom Top Clipped Left Right Clip Clip Clip Clip Polygon Polygon Krishna Jadhav RLPC Buldana(kparth.jadhav@gmail.com)
  • 9. CHAPTER 5 CURVES AND FRACTALS:- Curve generation method:- Under Construction……. Krishna Jadhav RLPC Buldana(kparth.jadhav@gmail.com)