mediaLib Library Functions
mlibImageZoomTranslateTableFp(3MLIB)
NAME
mlibImageZoomTranslateTableFp - zoom, with translation,
with table-driven interpolation
SYNOPSIS
cc [ flag... ] file... -lmlib [ library... ]
#include
mlibstatus mlibImageZoomTranslateTableFp(mlibimage *dst,
const mlibimage *src, mlibd64 zoomx, mlibd64 zoomy,
mlibd64 tx, mlibd64 ty, const void *interptable,
mlibedge edge);
DESCRIPTION
The mlibImageZoomTranslateTableFp() function will enlarge
or minify the floating-point source image by the X and Y
zoom factors, with translation. It uses a table,
interptable, to do interpolation.
It uses the following equation for coordinate mapping:
xd = zoomx*xs ] tx
yd = zoomy*ys ] ty
where a point with coordinates (xs, ys) in the source image
is mapped to a point with coordinates (xd, yd) in the desti-
nation image.
The data type of the images can be MLIBFLOAT or
MLIBDOUBLE.
The width and height of the destination image can be dif-
ferent from the width and height of the source image.
The center of the upper-left corner pixel of an image is
located at (0.5, 0.5).
PARAMETERS
The function takes the following arguments:
dst Pointer to destination image.
SunOS 5.11 Last change: 2 Mar 2007 1
mediaLib Library Functions
mlibImageZoomTranslateTableFp(3MLIB)
src Pointer to source image.
zoomx X zoom factor. zoomx > 0.
zoomy Y zoom factor. zoomy > 0.
tx X translation.
ty Y translation.
interptable Pointer to an interpolation table. The table
is created by the
mlibImageInterpTableCreate() function.
edge Type of edge condition. It can be one of the
following:
MLIBEDGEDSTNOWRITE
MLIBEDGEDSTFILZERO
MLIBEDGEOPNEAREST
MLIBEDGESRCEXTEND
MLIBEDGESRCEXTENDINDEF
MLIBEDGESRCPADED
RETURN VALUES
The function returns MLIBSUCES if successful. Otherwise
it returns MLIBFAILURE.
ATRIBUTES
See attributes(5) for descriptions of the following attri-
butes:
SunOS 5.11 Last change: 2 Mar 2007 2
mediaLib Library Functions
mlibImageZoomTranslateTableFp(3MLIB)
ATRIBUTE TYPE ATRIBUTE VALUE
Interface Stability Committed
MT-Level MT-Safe
SEE ALSO
mlibImageInterpTableCreate(3MLIB),
mlibImageInterpTableDelete(3MLIB),
mlibImageZoomTranslateTable(3MLIB),
mlibImageZoomTranslate(3MLIB),
mlibImageZoomTranslateFp(3MLIB), attributes(5)
SunOS 5.11 Last change: 2 Mar 2007 3
mediaLib Library Functions
mlibImageZoomTranslateTableFp(3MLIB)
SunOS 5.11 Last change: 2 Mar 2007 4
|