Open In App

Wand flip() function in Python

Last Updated : 16 Oct, 2021
Comments
Improve
Suggest changes
Like Article
Like
Report

In this article we will learn what is flip() function. Basically this function returns a flipped image. Flip effect flips an image upside-down or creates an vertical reflection of image. No arguments are needed in this function.
 

Syntax : wand.image.flip()
Parameters : No Parameters in flip() function.


Source Image: 
 


Example 1: 
 

Python3
# Import Image from wand.image module
from wand.image import Image

# Read image using Image function
with Image(filename ="koala.jpeg") as img:
    with img.clone() as fimg:
        # flip image using flip() function
        fimg.flip()
        fimg.save(filename ='koalaflipped.jpeg')

Output: 
 


Example 2:
Source Image: 
 


 

Python3
from wand.image import Image

# Read image using Image function
with Image(filename ="man.jpeg") as img:
    with img.clone() as fimg:
        # flip image using flip() function
        fimg.flip()
        fimg.save(filename ='manflipped.jpeg')

Output: 
 


 


Article Tags :
Practice Tags :

Similar Reads

pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy