Skip to content


Switch branches/tags

Name already in use

A tag already exists with the provided branch name. Many Git commands accept both tag and branch names, so creating this branch may cause unexpected behavior. Are you sure you want to create this branch?

Latest commit


Git stats


Failed to load latest commit information.
Latest commit message
Commit time

GitHub all releases GitHub

Java API for Image Processing

Imaging API is a library offering advanced image processing features. Developers can create, edit or convert images in their own application. Also Aspose. Imaging library supports drawing and work with graphic primitives. Image export and conversion (including uniform multi-page image processing) is the one of API core features along with image transformations (resize, crop, flip&rotate, binarization, grayscale, adjust), advanced image manipulation features (filtering, dithering, masking, deskewing) and memory optimization strategies.

Directory Description
Examples A collection of Java examples that help you learn the product features.
Plugins Plugins that will demonstrate one or more features of Aspose.Imaging for Java.

Directory Description
Examples A collection of Java examples that help you learn the product features.
Plugins Plugins related to Aspose.Imaging for Java product.

Imaging API Features

Load & Save Image Formats

Raster Formats: JPEG2000, JPEG, BMP, TIFF, GIF, PNG, DICOM, TGA, ICO
Metafiles: EMF, WMF
Compressed metafiles: EMZ, WMZ
Other: WebP, Svg, Svgz (compressed Svg)
Animation: Apng

Save Images As

Fixed-layout: PDF
Photoshop: PSD
Web: Html5 Canvas
AutoCAD: Dxf

Load Images


Platform Independence

Aspose.Imaging for Java can be virtually run in any OS where Java is installed (since JDK 1.6)

  • Windows (since 7)
  • Linux
  • MacOS
  • Any OS where Java is installed.

Aspose.Imaging works for both x86 and x64 versions of the above listed operating systems.

Note: In Linux OS, it is recommended to install the package with Microsoft compatible fonts (e.g. sudo apt-get install ttf-mscorefonts-installer).

Get Started with Aspose.Imaging for Java

Aspose hosts all Java APIs at the Aspose Repository. You can easily use Aspose.BarCode for Java API directly in your Maven projects with simple configurations. For the detailed instructions please visit Installing Aspose.Imaging for Java from Maven Repository documentation page.

Resize a JPG Image

try (Image image = Image.load(dir + "template.jpg"))
    image.resize(300, 300); + "output.jpg");

Create & Manipulate PNG via API

// image width and height
int width = 500;
int height = 300;

// where created image to store
String path = "createdImage.png";
// create options
try (PngOptions options = new PngOptions())
	options.setSource(new FileCreateSource(path, false));
	try (PngImage image = (PngImage)Image.create(options, width, height))
		// create and initialize an instance of Graphics class 
		// and Clear Graphics surface
		Graphics graphic = new Graphics(image);
		// draw line on image
		graphic.drawLine(new Pen(Color.getBlue()), 9, 9, 90, 90);        

		// resize image
		int newWidth = 400;
		image.resizeWidthProportionally(newWidth, ResizeType.LanczosResample);  

		// crop the image to specified area
		com.aspose.imaging.Rectangle area = new com.aspose.imaging.Rectangle(10,10,200,200);    

Home | Product Page | Docs | Demos | API Reference | Examples | Blog | Search | Free Support | Temporary License