Class ImageResizer
- java.lang.Object
- 
- org.nuxeo.ecm.platform.picture.magick.MagickExecutor
- 
- org.nuxeo.ecm.platform.picture.magick.utils.ImageResizer
 
 
- 
 public class ImageResizer extends MagickExecutor Unit command to extract a simplified view of a JPEG file using ImageMagick = extract the needed picture information to reach the target definition level- Author:
- tiry
 
- 
- 
Field SummaryFields Modifier and Type Field Description static intMAX_JEPG_DIMENSION
 - 
Constructor SummaryConstructors Constructor Description ImageResizer()
 - 
Method SummaryAll Methods Static Methods Concrete Methods Modifier and Type Method Description static ImageInforesize(String inputFile, String outputFile, int targetWidth, int targetHeight, int targetDepth)static PointscaleToMax(int width, int height, int max)Adapts width and height to a max conserving ratio.- 
Methods inherited from class org.nuxeo.ecm.platform.picture.magick.MagickExecutorexecCommand
 
- 
 
- 
- 
- 
Field Detail- 
MAX_JEPG_DIMENSIONpublic static final int MAX_JEPG_DIMENSION - Since:
- 10.3
- See Also:
- Constant Field Values
 
 
- 
 - 
Method Detail- 
resizepublic static ImageInfo resize(String inputFile, String outputFile, int targetWidth, int targetHeight, int targetDepth) throws CommandNotAvailable, CommandException - Throws:
- CommandNotAvailable
- CommandException
 
 - 
scaleToMaxpublic static Point scaleToMax(int width, int height, int max) Adapts width and height to a max conserving ratio.- Returns:
- new Point to scale or the original one if none is > max.
- Since:
- 10.3
 
 
- 
 
-