[PYTHON IMAGE-SIG] Any comments on PIL 0.0?

Fredrik Lundh fredrik_lundh@ivab.se
Tue, 2 Apr 1996 13:55:45 +0200

(The silence on this list is overwhelming...)

Have anyone more than Jack and David even tried out the release?
Doesn't anyone have any comments, bugs, suggestions, flames???

I've added quite a few things to the library, on my way to a second
release, but I do need some feedback to see if I'm still on the track.

+ What's missing in the library?

+ Can you live with the PIL/IMG marriage for a while, or should
  I complete the ImageIO portions before doing anything else?

+ Was the handbook ok?  Can you handle Postscript files, or is
  some other format preferred?

+ What's needed before we can announce it to the world?
  (i.e. comp.lang.python)

Regards	/F


For latecomers, the current distribution should still be available



And here's a summary of the current status.  The most notable addition
is the channel operations ("chops"), but the point method is not a bad
one either...

	j = i.point(lambda a: a * 1.2) # lighten up

Python Imaging Library (PIL)

Current status (~0.08)

*** Module Image

class Image:
    "A raster image"
    mode -- number of bands, pixel type ["L", "RGB", "RGBA", "CMYK"]
    palette -- colour table, for "P" type images *NOTYET*
    size -- image size in pixels
    info -- associated data (dictionary)
    def convert(mode)
    def copy()
    def crop(box)
    def filter(kernel)
    def histogram()
    def load()
    def paste(image, box, [alpha])
    def point(table) *NEW*
    def point(function) *NEW*
    def resize(size)
    def rotate(angle)
    def save(filename, [format])
    def show() -- currently for unix only
    def split()
    def transpose(operation)
    def transform(size, AFFINE, matrix)

def new(mode, size)
def open(filename)
def blend(image, image, ratio)
def composite(image, image, mask) *NEW* (equivalent to copy+paste(mask))
def eval(function, images...) *NEW* (equivalent to point(function))
def merge(mode, bands) *RENAMED*

*** Module ImageChops (*BETTER NAME NEEDED!*)

def constant(image, value) *NEW*
def duplicate(image) *NEW*
def invert(image) *NEW*
def lighter(image1, image2) *NEW*
def darker(image1, image2) *NEW*
def difference(image1, image2) *NEW*
def multiply(image1, image2) *NEW*
def screen(image1, image2) *NEW*
def add(image1, image2, [scale, offset]) *NEW*
def subtract(image1, image2, [scale, offset]) *NEW*
def blend(image1, image2, alpha)
def composite(image1, image2, mask)

(Note that for full math support, you should use the Numerical Python
 extension instead.  An interface will be provided later!)

*** Module ImageEnhance

class Color
class Contrast
class Brightness
class Sharpness

*** Module ImageFile

class ImageFile(Image):
    "A raster image read from file or stream"
    def load(file)

class XxxImageFile(ImageFile):
    "Read/write XXX file" (see below)

*** Module ImageFilter

class ImageFilter():
    "Represents an environment filtering operation"

class ImageSimpleKernel(ImageFilter):
    "Simple 3x3 and 5x5 integer convolutions"

*** Module ImageISOFilter

~20 standard impulse filters from ISO 12087-2

*** Module ImagePalette

class ImagePalette():
    "A colour lookup table for palette images"

def negative()
def random()
def wedge()

*** File format support

format		supported operations
------		--------------------
BMP		open/read/write *NOTYET*
EPS		open (1)
FLI (FLC)	open (1)
GBR		open/read *NOTYET*
GIF		open/read *IMG*
JPEG (JFIF)	open/read/write (3) *IMG*
MSP		open (1)
PBM (PGM/PPM)	open/read/write
PCX		open/read *NOTYET*
PSD		open (1) *NOTYET*
SGI		read *IMG*
TIFF		open/read (2) *IMG*

(1) file is identified (mode, size, info), but not decoded.
(2) restricted, not full baseline support.
(3) requires IJG JPEG support library (libjpeg)

IMAGE-SIG - SIG on Image Processing with Python

send messages to: image-sig@python.org
administrivia to: image-sig-request@python.org