com.atlassian.confluence.plugins.avatar
Interface ImageHelper

All Known Implementing Classes:
DefaultImageHelper

public interface ImageHelper


Method Summary
 InputStream autoCropAndResize(InputStream imageStream)
          Crops the largest centre square in the image provided.
 InputStream cropAndResize(InputStream imageStream, int x, int y, int width, int height)
          Returns a crop of the specified area denoted with x and y offets spanning the specified width and height.
 

Method Detail

autoCropAndResize

InputStream autoCropAndResize(InputStream imageStream)
Crops the largest centre square in the image provided.

Parameters:
imageStream - the stream of the image.
Returns:
a crop representing the largest centre square in the image provided.

cropAndResize

InputStream cropAndResize(InputStream imageStream,
                          int x,
                          int y,
                          int width,
                          int height)
Returns a crop of the specified area denoted with x and y offets spanning the specified width and height.

Parameters:
imageStream - the stream of the image
x - the x offset
y - the y offset
width - the width of the crop area
height - the height of the crop area
Returns:
a crop of the specified area denoted with x and y offets spanning the specified width and height.


Copyright © 2003-2013 Atlassian. All Rights Reserved.