JpegImageFile Class

Inheritance diagram of JpegImageFile

class JpegImageFile(fp=None, filename=None)

Methods

__init__([fp, filename])
convert([mode, data, dither, palette, colors]) Convert to other pixel format
copy() Copy raster data
crop([box]) Crop region from image
draft(mode, size)
filter(filter) Apply environment filter to image
fromstring(data[, decoder_name]) Load data to image from binary string
getbands() Get band names
getbbox() Get bounding box of actual data (non-zero pixels) in image
getcolors([maxcolors]) Get colors from image, up to given limit
getdata([band]) Get image data as sequence object.
getextrema() Get min/max value
getim() Get PyCObject pointer to internal image memory
getpalette() Get palette contents.
getpixel(xy) Get pixel value
getprojection() Get projection to x and y axes
histogram([mask, extrema]) Take histogram of image
load() Load image data based on tile list
load_djpeg()
load_end()
load_prepare()
offset(xoffset[, yoffset]) (deprecated) Offset image in horizontal and/or vertical direction
paste(im[, box, mask]) Paste other image into region
point(lut[, mode]) Map image through lookup table
putalpha(alpha) Set alpha layer
putdata(data[, scale, offset]) Put data from a sequence object into an image.
putpalette(data[, rawmode]) Put palette data into an image.
putpixel(xy, value) Set pixel value
quantize([colors, method, kmeans, palette])
resize(size[, resample]) Resize image
rotate(angle[, resample, expand]) Rotate image.
save(fp[, format]) Save image to file or stream
seek(frame) Seek to given frame in sequence file
show([title, command]) Display image (for debug purposes only)
split() Split image into bands
tell() Return current frame number
thumbnail(size[, resample]) Create thumbnail representation (modifies image in place)
tobitmap([name]) Return image as an XBM bitmap
tostring([encoder_name]) Return image as a binary string
transform(size, method[, data, resample, fill]) Transform image
transpose(method) Transpose image (flip or rotate in 90 degree steps)
verify() Check file integrity

Attributes

format str(object) -> string
format_description str(object) -> string

Descriptions

class JpegImageFile

Method details

draft(mode, size)
load_djpeg()

Attribute details

format = 'JPEG'
format_description = 'JPEG (ISO 10918)'

Inherited member details

__init__(fp=None, filename=None)
convert(mode=None, data=None, dither=None, palette=0, colors=256)

Convert to other pixel format

copy()

Copy raster data

crop(box=None)

Crop region from image

filter(filter)

Apply environment filter to image

fromstring(data, decoder_name='raw', *args)

Load data to image from binary string

getbands()

Get band names

getbbox()

Get bounding box of actual data (non-zero pixels) in image

getcolors(maxcolors=256)

Get colors from image, up to given limit

getdata(band=None)

Get image data as sequence object.

getextrema()

Get min/max value

getim()

Get PyCObject pointer to internal image memory

getpalette()

Get palette contents.

getpixel(xy)

Get pixel value

getprojection()

Get projection to x and y axes

histogram(mask=None, extrema=None)

Take histogram of image

load()

Load image data based on tile list

load_end()
load_prepare()
offset(xoffset, yoffset=None)

(deprecated) Offset image in horizontal and/or vertical direction

paste(im, box=None, mask=None)

Paste other image into region

point(lut, mode=None)

Map image through lookup table

putalpha(alpha)

Set alpha layer

putdata(data, scale=1.0, offset=0.0)

Put data from a sequence object into an image.

putpalette(data, rawmode='RGB')

Put palette data into an image.

putpixel(xy, value)

Set pixel value

quantize(colors=256, method=0, kmeans=0, palette=None)
resize(size, resample=0)

Resize image

rotate(angle, resample=0, expand=0)

Rotate image. Angle given as degrees counter-clockwise.

save(fp, format=None, **params)

Save image to file or stream

seek(frame)

Seek to given frame in sequence file

show(title=None, command=None)

Display image (for debug purposes only)

split()

Split image into bands

tell()

Return current frame number

thumbnail(size, resample=0)

Create thumbnail representation (modifies image in place)

tobitmap(name='image')

Return image as an XBM bitmap

tostring(encoder_name='raw', *args)

Return image as a binary string

transform(size, method, data=None, resample=0, fill=1)

Transform image

transpose(method)

Transpose image (flip or rotate in 90 degree steps)

verify()

Check file integrity

Table Of Contents

Previous topic

i32

Next topic

APP