com.alibaba.simpleimage.util
类 ImageScaleHelper

java.lang.Object
  继承者 com.alibaba.simpleimage.util.ImageScaleHelper

public class ImageScaleHelper
extends Object


构造方法摘要
ImageScaleHelper()
           
 
方法摘要
static PlanarImage autoScaleImage(PlanarImage input, double scale)
           
static PlanarImage bicubicScaleImage(PlanarImage input, float scale, int alg)
           
static double computeDoubleScale(int w, int h, ScaleParameter zoom)
           
static float computeFloatScale(int w, int h, ScaleParameter zoom)
           
static PlanarImage lanczosScaleImage(PlanarImage input, double scale)
           
static PlanarImage progressiveScaleImage(PlanarImage input, int targetWidth, int targetHeight, Object hint, boolean progressive)
          已过时。 
static PlanarImage scale(PlanarImage input, ScaleParameter zoom)
           
static ImageWrapper scaleGIF(ImageWrapper imgWrapper, ScaleParameter zoom)
           
static PlanarImage subsampleavgScaleImage(PlanarImage input, double scale)
           
 
从类 java.lang.Object 继承的方法
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

构造方法详细信息

ImageScaleHelper

public ImageScaleHelper()
方法详细信息

scaleGIF

public static ImageWrapper scaleGIF(ImageWrapper imgWrapper,
                                    ScaleParameter zoom)
                             throws SimpleImageException
抛出:
SimpleImageException

scale

public static PlanarImage scale(PlanarImage input,
                                ScaleParameter zoom)

computeFloatScale

public static float computeFloatScale(int w,
                                      int h,
                                      ScaleParameter zoom)

computeDoubleScale

public static double computeDoubleScale(int w,
                                        int h,
                                        ScaleParameter zoom)

bicubicScaleImage

public static PlanarImage bicubicScaleImage(PlanarImage input,
                                            float scale,
                                            int alg)

subsampleavgScaleImage

public static PlanarImage subsampleavgScaleImage(PlanarImage input,
                                                 double scale)

lanczosScaleImage

public static PlanarImage lanczosScaleImage(PlanarImage input,
                                            double scale)

autoScaleImage

public static PlanarImage autoScaleImage(PlanarImage input,
                                         double scale)

progressiveScaleImage

@Deprecated
public static PlanarImage progressiveScaleImage(PlanarImage input,
                                                           int targetWidth,
                                                           int targetHeight,
                                                           Object hint,
                                                           boolean progressive)
已过时。 

折半渐进压缩图片方法 测试后觉得效果不太理想,不鼓励使用

参数:
img -
targetWidth -
targetHeight -
hint -
progressiveBilinear -
返回:


Copyright © 2012–2015 Alibaba Group. All rights reserved.