'\" te .\" Copyright (c) 2007, Sun Microsystems, Inc. All Rights Reserved .TH mlib_ImageBlendMulti_Fp 3MLIB "2 Mar 2007" "SunOS 5.11" "mediaLib Library Functions" .SH NAME mlib_ImageBlendMulti_Fp \- blend multiple images .SH SYNOPSIS .LP .nf cc [ \fIflag\fR... ] \fIfile\fR... \fB-lmlib\fR [ \fIlibrary\fR... ] #include \fBmlib_status\fR \fBmlib_ImageBlendMulti_Fp\fR(\fBmlib_image *\fR\fIdst\fR, \fBconst mlib_image **\fR\fIsrcs\fR, \fBconst mlib_image **\fR\fIalphas\fR, \fBconst mlib_d64 *\fR\fIc\fR, \fBmlib_s32\fR \fIn\fR); .fi .SH DESCRIPTION .sp .LP The \fBmlib_ImageBlendMulti_Fp()\fR function blends multiple source images, using multiple alpha images, into a single destination image. .sp .LP All images involved should have the same data type and same size and the source and destination images should have the same number of channels. The alpha images should have either 1 channel or the same number of channels as the sources and destination. A single-channel alpha image would be applied to all channels of the corresponding source image. Single and multi-channel alpha images can be mixed in the same invocation. .sp .LP It uses the following equation: .sp .in +2 .nf n-1 SUM {alphas[k][x][y][j] * srcs[k][x][y][i]} k=0 dst[x][y][i] = --------------------------------------------- n-1 SUM {alphas[k][x][y][j]} k=0 .fi .in -2 .sp .LP or .sp .in +2 .nf n-1 dst[x][y][i] = c[i] if SUM {alphas[k][x][y][j]} = 0 k=0 .fi .in -2 .sp .LP where \fBj = i\fR for multi-channel alpha images; \fBj = 0\fR for signle-channel alpha images. .SH PARAMETERS .sp .LP The function takes the following arguments: .sp .ne 2 .mk .na \fB\fIdst\fR\fR .ad .RS 10n .rt Pointer to destination image. .RE .sp .ne 2 .mk .na \fB\fIsrcs\fR\fR .ad .RS 10n .rt Pointer to an array of source images. .RE .sp .ne 2 .mk .na \fB\fIalphas\fR\fR .ad .RS 10n .rt Pointer to an array of alpha images. .RE .sp .ne 2 .mk .na \fB\fIc\fR\fR .ad .RS 10n .rt Background color. .RE .sp .ne 2 .mk .na \fB\fIn\fR\fR .ad .RS 10n .rt Number of source images to be blended. .RE .SH RETURN VALUES .sp .LP The function returns \fBMLIB_SUCCESS\fR if successful. Otherwise it returns \fBMLIB_FAILURE\fR. .SH ATTRIBUTES .sp .LP See \fBattributes\fR(5) for descriptions of the following attributes: .sp .sp .TS tab() box; cw(2.75i) |cw(2.75i) lw(2.75i) |lw(2.75i) . ATTRIBUTE TYPEATTRIBUTE VALUE _ Interface StabilityCommitted _ MT-LevelMT-Safe .TE .SH SEE ALSO .sp .LP \fBmlib_ImageBlendMulti\fR(3MLIB), \fBmlib_ImageBlend\fR(3MLIB), \fBmlib_ImageBlend_Fp\fR(3MLIB), \fBattributes\fR(5)