Current File : //usr/share/man/man3mlib/mlib_VectorSumAbsDiff_U8_Sat.3mlib
'\" te
.\" Copyright (c) 2007, Sun Microsystems, Inc.  All Rights Reserved 
.TH mlib_VectorSumAbsDiff_U8_Sat 3MLIB "2 Mar 2007" "SunOS 5.11" "mediaLib Library Functions"
.SH NAME
mlib_VectorSumAbsDiff_U8_Sat, mlib_VectorSumAbsDiff_S8_Sat, mlib_VectorSumAbsDiff_S16_Sat, mlib_VectorSumAbsDiff_S32_Sat \- sum of the absolute values of the differences of two vectors
.SH SYNOPSIS
.LP
.nf
cc [ \fIflag\fR... ] \fIfile\fR... \fB-lmlib\fR [ \fIlibrary\fR... ]
#include <mlib.h>

\fBmlib_status\fR \fBmlib_VectorSumAbsDiff_U8_Sat\fR(\fBmlib_d64 *\fR\fIz\fR, 
     \fBconst mlib_u8 *\fR\fIx\fR, \fBconst mlib_u8 *\fR\fIy\fR, \fBmlib_s32\fR \fIn\fR);
.fi

.LP
.nf
\fBmlib_status\fR \fBmlib_VectorSumAbsDiff_S8_Sat\fR(\fBmlib_d64 *\fR\fIz\fR,
     \fBconst mlib_s8 *\fR\fIx\fR, \fBconst mlib_s8 *\fR\fIy\fR, \fBmlib_s32\fR \fIn\fR);
.fi

.LP
.nf
\fBmlib_status\fR \fBmlib_VectorSumAbsDiff_S16_Sat\fR(\fBmlib_d64 *\fR\fIz\fR,
     \fBconst mlib_s16 *\fR\fIx\fR, \fBconst mlib_s16 *\fR\fIy\fR, \fBmlib_s32\fR \fIn\fR);
.fi

.LP
.nf
\fBmlib_status\fR \fBmlib_VectorSumAbsDiff_S32_Sat\fR(\fBmlib_d64 *\fR\fIz\fR,
     \fBconst mlib_s32 *\fR\fIx\fR, \fBconst mlib_s32 *\fR\fIy\fR, \fBmlib_s32\fR \fIn\fR);
.fi

.SH DESCRIPTION
.sp
.LP
Each of these functions computes the sum of the absolute values of the differences of two vectors.
.sp
.LP
The following equation is used:
.sp
.in +2
.nf
       n-1
z[0] = SUM |x[i] - y[i]|
       i=0
.fi
.in -2

.SH PARAMETERS
.sp
.LP
Each of the functions takes the following arguments:
.sp
.ne 2
.mk
.na
\fB\fIz\fR\fR
.ad
.RS 5n
.rt  
Pointer to the sum of the absolute differences between two vectors.
.RE

.sp
.ne 2
.mk
.na
\fB\fIx\fR\fR
.ad
.RS 5n
.rt  
Pointer to the first element of the first source vector.
.RE

.sp
.ne 2
.mk
.na
\fB\fIy\fR\fR
.ad
.RS 5n
.rt  
Pointer to the first element of the second source vector.
.RE

.sp
.ne 2
.mk
.na
\fB\fIn\fR\fR
.ad
.RS 5n
.rt  
Number of elements in the vectors.
.RE

.SH RETURN VALUES
.sp
.LP
Each of the functions 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
\fBattributes\fR(5)