JpegDevice
Inheritance: java.lang.Object, com.aspose.pdf.devices.Device, com.aspose.pdf.devices.PageDevice, com.aspose.pdf.devices.ImageDevice
public final class JpegDevice extends ImageDevice
Represents image device that helps to save pdf document pages into jpeg.
Constructors
Constructor | Description |
---|---|
JpegDevice() | Initializes a new instance of the JpegDevice class with default resolution and maximum quality. |
JpegDevice(Resolution resolution) | Initializes a new instance of the JpegDevice class. |
JpegDevice(int quality) | Initializes a new instance of the JpegDevice class. |
JpegDevice(Resolution resolution, int quality) | Initializes a new instance of the JpegDevice class. |
JpegDevice(int width, int height) | Initializes a new instance of the JpegDevice class with provided image dimensions, default resolution (=150) and maximum quality. |
JpegDevice(PageSize pageSize) | Initializes a new instance of the JpegDevice class with provided page size, default resolution (=150) and maximum quality. |
JpegDevice(int width, int height, Resolution resolution) | Initializes a new instance of the JpegDevice class with provided image dimensions, resolution and maximum quality. |
JpegDevice(PageSize pageSize, Resolution resolution) | Initializes a new instance of the JpegDevice class with provided page size, resolution and maximum quality. |
JpegDevice(int width, int height, Resolution resolution, int quality) | Initializes a new instance of the JpegDevice class with provided image dimensions, resolution and quality. |
JpegDevice(PageSize pageSize, Resolution resolution, int quality) | Initializes a new instance of the JpegDevice class with provided page size, resolution and quality. |
Methods
Method | Description |
---|---|
processInternal(Page page, System.IO.Stream output) | Converts the page into jpeg and saves it in the output stream. |
process(Page page, OutputStream output) | Converts the page into jpeg and saves it in the output stream. |
JpegDevice()
public JpegDevice()
Initializes a new instance of the JpegDevice class with default resolution and maximum quality.
JpegDevice(Resolution resolution)
public JpegDevice(Resolution resolution)
Initializes a new instance of the JpegDevice class.
Parameters:
Parameter | Type | Description |
---|---|---|
resolution | Resolution | Resolution for the result image file, see Resolution class. |
JpegDevice(int quality)
public JpegDevice(int quality)
Initializes a new instance of the JpegDevice class.
Parameters:
Parameter | Type | Description |
---|---|---|
quality | int | Specifies the level of compression for an image. The range of useful values for the quality is from 0 to 100. The lower the number specified, the higher the compression and therefore the lower the quality of the image. Zero would give you the lowest quality image and 100 the highest. |
JpegDevice(Resolution resolution, int quality)
public JpegDevice(Resolution resolution, int quality)
Initializes a new instance of the JpegDevice class.
Parameters:
Parameter | Type | Description |
---|---|---|
resolution | Resolution | Resolution for the result image file, see Resolution class. |
quality | int | Specifies the level of compression for an image. The range of useful values for the quality is from 0 to 100. The lower the number specified, the higher the compression and therefore the lower the quality of the image. Zero would give you the lowest quality image and 100 the highest. |
JpegDevice(int width, int height)
public JpegDevice(int width, int height)
Initializes a new instance of the JpegDevice class with provided image dimensions, default resolution (=150) and maximum quality.
Parameters:
Parameter | Type | Description |
---|---|---|
width | int | Image output width. |
height | int | Image output height. |
JpegDevice(PageSize pageSize)
public JpegDevice(PageSize pageSize)
Initializes a new instance of the JpegDevice class with provided page size, default resolution (=150) and maximum quality.
Parameters:
Parameter | Type | Description |
---|---|---|
pageSize | PageSize | Page size of the output image. |
JpegDevice(int width, int height, Resolution resolution)
public JpegDevice(int width, int height, Resolution resolution)
Initializes a new instance of the JpegDevice class with provided image dimensions, resolution and maximum quality.
Parameters:
Parameter | Type | Description |
---|---|---|
width | int | Image output width. |
height | int | Image output height. |
resolution | Resolution | Resolution for the result image file, see Resolution class. |
JpegDevice(PageSize pageSize, Resolution resolution)
public JpegDevice(PageSize pageSize, Resolution resolution)
Initializes a new instance of the JpegDevice class with provided page size, resolution and maximum quality.
Parameters:
Parameter | Type | Description |
---|---|---|
pageSize | PageSize | Page size of the output image. |
resolution | Resolution | Resolution for the result image file, see Resolution class. |
JpegDevice(int width, int height, Resolution resolution, int quality)
public JpegDevice(int width, int height, Resolution resolution, int quality)
Initializes a new instance of the JpegDevice class with provided image dimensions, resolution and quality.
Parameters:
Parameter | Type | Description |
---|---|---|
width | int | Image output width. |
height | int | Image output height. |
resolution | Resolution | Resolution for the result image file, see Resolution class. |
quality | int | Specifies the level of compression for an image. The range of useful values for the quality is from 0 to 100. The lower the number specified, the higher the compression and therefore the lower the quality of the image. Zero would give you the lowest quality image and 100 the highest. |
JpegDevice(PageSize pageSize, Resolution resolution, int quality)
public JpegDevice(PageSize pageSize, Resolution resolution, int quality)
Initializes a new instance of the JpegDevice class with provided page size, resolution and quality.
Parameters:
Parameter | Type | Description |
---|---|---|
pageSize | PageSize | Page size of the output image. |
resolution | Resolution | Resolution for the result image file, see Resolution class. |
quality | int | Specifies the level of compression for an image. The range of useful values for the quality is from 0 to 100. The lower the number specified, the higher the compression and therefore the lower the quality of the image. Zero would give you the lowest quality image and 100 the highest. |
processInternal(Page page, System.IO.Stream output)
public void processInternal(Page page, System.IO.Stream output)
Converts the page into jpeg and saves it in the output stream.
Parameters:
Parameter | Type | Description |
---|---|---|
page | Page | The page to convert. |
output | com.aspose.ms.System.IO.Stream | Output stream with jpeg image. |
process(Page page, OutputStream output)
public void process(Page page, OutputStream output)
Converts the page into jpeg and saves it in the output stream.
Parameters:
Parameter | Type | Description |
---|---|---|
page | Page | The page to convert. |
output | java.io.OutputStream | Output stream with jpeg image. |