Package magick
Class MagickProducer
java.lang.Object
magick.Magick
magick.MagickProducer
- All Implemented Interfaces:
ImageProducer
This class implements the ImageProducer class.
It reads the pixels off a MagickImage and sends
the pixels to the specified ImageConsumer.
- Author:
- Eric Yeo
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoid
addConsumer
(ImageConsumer consumer) This method is used to register an ImageConsumer with the ImageProducer for access to the image data during a later reconstruction of the Image.boolean
isConsumer
(ImageConsumer consumer) This method determines if a given ImageConsumer object is currently registered with this ImageProducer as one of its consumers.void
removeConsumer
(ImageConsumer consumer) This method removes the given ImageConsumer object from the list of consumers currently registered to receive image data.void
requestTopDownLeftRightResend
(ImageConsumer consumer) This method is used by an ImageConsumer to request that the ImageProducer attempt to resend the image data one more time in TOPDOWNLEFTRIGHT order so that higher quality conversion algorithms which depend on receiving pixels in order can be used to produce a better output version of the image.void
startProduction
(ImageConsumer consumer) This method both registers the given ImageConsumer object as a consumer and starts an immediate reconstruction of the image data which will then be delivered to this consumer and any other consumer which may have already been registered with the producer.Methods inherited from class magick.Magick
parseImageGeometry, queryFonts
-
Constructor Details
-
MagickProducer
Constructor.- Parameters:
image
- the MagickImage to produce an Image from
-
-
Method Details
-
addConsumer
This method is used to register an ImageConsumer with the ImageProducer for access to the image data during a later reconstruction of the Image.- Specified by:
addConsumer
in interfaceImageProducer
- Parameters:
consumer
- to register with the producer
-
isConsumer
This method determines if a given ImageConsumer object is currently registered with this ImageProducer as one of its consumers.- Specified by:
isConsumer
in interfaceImageProducer
- Parameters:
consumer
- to consumer to register with the producer
-
removeConsumer
This method removes the given ImageConsumer object from the list of consumers currently registered to receive image data. It is not considered an error to remove a consumer that is not currently registered.- Specified by:
removeConsumer
in interfaceImageProducer
- Parameters:
consumer
- the consumer to check for registration
-
startProduction
This method both registers the given ImageConsumer object as a consumer and starts an immediate reconstruction of the image data which will then be delivered to this consumer and any other consumer which may have already been registered with the producer.- Specified by:
startProduction
in interfaceImageProducer
- Parameters:
consumer
- to be registered before producing the image
-
requestTopDownLeftRightResend
This method is used by an ImageConsumer to request that the ImageProducer attempt to resend the image data one more time in TOPDOWNLEFTRIGHT order so that higher quality conversion algorithms which depend on receiving pixels in order can be used to produce a better output version of the image.- Specified by:
requestTopDownLeftRightResend
in interfaceImageProducer
- Parameters:
consumer
- the consumer to register before producing the image
-