Csci 1020 February 27, 2019 Program Assignment 7

Create or download an image, then create a transparent background in .gif format. Email your two images to: ted@fdltcc.edu

(This is a 1-day week, so we will look at Python strings next week along with a richer Python GUI problem.)

Install Imagemagick on your machine. You can find a Windows binary by searching for: windows imagemagick

Download or create your image to work with, say a cat head or a smiley face. For use on Python tkinter Canvas, you need a transparent background--the border around the head or face--so that it will not block other imagery on the canvas. Say this is saved as head.png on the Desktop.

Using MS Paint or another raster image editing program, create a solid black (RGB = 000000) boundary surrounding the head or face. This black will be the transparent background. Any color would work, but black is usually easiest. Save your image with this black boundary, and save it to Desktop, say head2.png

Open a terminal/command prompt under Windows >> System. Issue these commands in the command shell window. These are command lines, so you hit the Enter key to run each command for each line.

cd  Desktop
magick  head2.png -transparent black head.gif

Imagemagick uses the program name magick for this convert operation. (It is called convert in Linux, but Windows uses "convert" for something else, hence the rename to magick for use in Windows.)

There are a great many things one can do with Imagemagick on images, and a Windows install of Imagemagick can also install ffmpeg which can then be used to create and work with movie formats.


Content is neither approved nor reviewed by FDLTCC.