lib
Class Compressor
java.lang.Object
java.util.Observable
lib.Compressor
public class Compressor
- extends java.util.Observable
fractal compressor instance. combines the tiler and
comparator classes to create a fractal image model
Methods inherited from class java.util.Observable |
addObserver, clearChanged, countObservers, deleteObserver, deleteObservers, hasChanged, notifyObservers, notifyObservers, setChanged |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Compressor
public Compressor(ScaleTransform scaleTransform,
Tiler<java.awt.image.BufferedImage> tiler,
Distanceator<java.awt.image.BufferedImage> comparator,
java.util.Set<ImageTransform> transforms,
java.util.Observer observer)
throws java.lang.NullPointerException
- Parameters:
scaleTransform
- the scale difference between the ranges and the domainstiler
- the tiler used to tile the imagecomparator
- the comparator used to compare the tiles of the imagetransforms
- a list of transform to apply to the tiles of the imageobserver
- an observer receiving progress results for the compression - allowed to be null
- Throws:
java.lang.NullPointerException
- if any field is null- See Also:
compress(java.awt.image.BufferedImage)
,
Observable
,
Observer.update(java.util.Observable, java.lang.Object)
Compressor
public Compressor(ScaleTransform scaleTransform,
Tiler<java.awt.image.BufferedImage> tiler,
Distanceator<java.awt.image.BufferedImage> comparator,
java.util.Set<ImageTransform> transforms,
java.util.Set<java.awt.image.BufferedImageOp> filters,
java.util.Observer observer)
throws java.lang.NullPointerException
- Parameters:
scaleTransform
- the scale difference between the ranges and the domainstiler
- the tiler used to tile the imagecomparator
- the comparator used to compare the tiles of the imagetransforms
- a set of transform to apply to the tiles of the imagefilters
- a set of filters to apply to the image for normalizationobserver
- an observer receiving progress results from compress
- allowed to be null
- Throws:
java.lang.NullPointerException
- if any field is null- See Also:
compress(java.awt.image.BufferedImage)
,
Observable
,
Observer.update(java.util.Observable, java.lang.Object)
compress
public FractalModel compress(java.awt.image.BufferedImage image)
- Compress a given image. Compressions takes place as a mapping of
small images and transforms to points. Applying the transforms
to the images and placing the resulted transformed images
to the mapped points, the original image is reassembled.
- Parameters:
image
- the image to compress
- Returns:
- a mapping of points to images and transforms.