mad Function

mad Function


Computes the product of the first and second specified argument, then adds the third specified argument.

inline float mad(
   float _X,
   float _Y,
   float _Z
) restrict(amp);

inline double mad(
   double _X,
   double _Y,
   double _Z
) restrict(amp);

inline int mad(
   int _X,
   int _Y,
   int _Z
) restrict(amp);

inline unsigned int mad(
   unsigned int _X,
   unsigned int _Y,
   unsigned int _Z
) restrict(amp);


The first specified argument.


The second specified argument.


The third specified argument.

The result of _X * _Y + _Z.


Header: amp.h

Namespace: Concurrency::direct3d

© 2015 Microsoft