image resize

From DavinciWiki
Jump to: navigation, search


64-bit SafeYes

Description

Resizes a multiband image/numerical data upwards or downwards

Arguments and Return Values

Input: Data array and factor information

Output: An resized array

Usage


Syntax: image_resize(data = VAL [, factor = DOUBLE] [, xfactor = DOUBLE] [, yfactor = DOUBLE ] [,width = INT ] [,height = INT] [,lockratio=bool] [,interp={'bilinear' | 'bicubic' | 'none'}] [,ignore = DOUBLE])

'factor' - Resize factor

'xfactor' - Resize x factor

'yfactor' - Resize x factor

'width' - Resize an image to a specified width

'height' - Resize an image to a specified height

'lockratio' - Locks the image aspect ratio

'interp' - Interpolation algorithm. For scaling up the available options are 'bicubic', 'bilinear' or 'none'. For scaling down it uses the average box algorithm by default or 'none' if specified.


Examples

dv> a = create(200,200,1)
200x200x1 array of int, bsq format [160,000 bytes]
dv> b = image_resize(a, 2.5)
500x500x1 array of int, bsq format [1,000,000 bytes]
dv> c = image_resize(b, 0.5)
250x250x1 array of int, bsq format [250,000 bytes]
dv> d = image_resize(a, width=300, interp=bicubic)
300x200x1 array of int, bsq format [240,000 bytes]

DavinciWiki Mini-Nav Bar

Contents


Contact Developers

  • davinci-dev [AT] mars.asu.edu

All other topics

  • See navigation on the left

Related Functions

Recent Core Changes

Modified On: 11-18-2010

Personal tools