public class WindowsImageCapture extends ImageCapture
PROPERTY_IMAGE_SOURCE
PROPERTY_CAPTURE_AREA, PROPERTY_CAPTURE_TRANSPARENT_WINDOWS, PROPERTY_INCLUDE_CURSOR
Constructor and Description |
---|
WindowsImageCapture() |
Modifier and Type | Method and Description |
---|---|
void |
copyToClipboard()
Copies this capture to the system clipboard as a bitmap.
|
static void |
enableDwmComposition(boolean enable)
Allows to enable or disable Desktop Window Manager (DWM) composition.
|
java.awt.image.BufferedImage |
getImage()
Returns a Java image of this image capture.
|
static boolean |
isDwmCompositionEnabled()
Allows to check if Desktop Window Manager (DWM) composition is enabled.
|
void |
release()
Releases all resources of this image capture.
|
ImageCapture |
resize(java.awt.Dimension dimensions,
InterpolationMode interpolation)
Resizes this image capture to new dimensions using the specified interpolation mode.
|
boolean |
save(java.io.File file,
ImageFormat format,
CompressionQuality quality)
Saves this image capture to a file with the specified image format.
|
ImageCapture |
takeSnapshot()
Takes a snapshot of a specified capture area.
|
create, create, create, getImageSource, resize, save, setImageSource, toBufferedImage
addPropertyChangeListener, addPropertyChangeListener, getCaptureArea, getPropertyChangeSupport, isCaptureTransparentWindows, isIncludeCursor, removePropertyChangeListener, setCaptureArea, setCaptureTransparentWindows, setIncludeCursor
public static void enableDwmComposition(boolean enable)
enable
- true - enables composition; false disables itpublic static boolean isDwmCompositionEnabled()
public ImageCapture takeSnapshot()
ImageCapture
ImageCapture.resize(java.awt.Dimension, InterpolationMode)
method,
or saved to the file using the ImageCapture.save(java.io.File, com.teamdev.jxcapture.image.ImageFormat, CompressionQuality)
method, or just returned as Java image using
the ImageCapture.getImage()
method.takeSnapshot
in class ImageCapture
public java.awt.image.BufferedImage getImage()
ImageCapture
Before calling this method you should invoke the ImageCapture.takeSnapshot()
method first.
getImage
in class ImageCapture
public ImageCapture resize(java.awt.Dimension dimensions, InterpolationMode interpolation)
ImageCapture
Before calling this method you should invoke the ImageCapture.takeSnapshot()
method first.
resize
in class ImageCapture
dimensions
- specifies new dimensionsinterpolation
- specifies interpolation modepublic boolean save(java.io.File file, ImageFormat format, CompressionQuality quality)
ImageCapture
Before calling this method you should invoke the ImageCapture.takeSnapshot()
method first.
save
in class ImageCapture
file
- destination fileformat
- required image formatquality
- required compression quality of resulting imagepublic void copyToClipboard()
ImageCapture
copyToClipboard
in class ImageCapture
public void release()
ImageCapture
release
in class ImageCapture