Quantcast
Channel: WP快站
Viewing all articles
Browse latest Browse all 233

how can i add padding to my gif image using wand library python

$
0
0

Right now i am creating a blank background image and compositing the original image over the blank image to give effect of padding. but it is returning only a single frame after composite function.

   with Image(width=required_width, height=new_height+margin,        background=value) as padded_img:                padded_img.composite(img, top=margin//2)                padded_img.save(filename='mypath')

the image i am getting in return is not gif image(the image is not animated and only one frame is showing) how can i composite gif images such that i get all of my frames or is there any alternative to this.


Viewing all articles
Browse latest Browse all 233

Trending Articles