simdpp::blend
From cppreference.com
< shuffle
template<unsigned N, class V1, class V2, class V3>
PROMOTED_EXPRESSION blend( const any_vec<N,V1>& on, const any_vec<N,V2>& off, |
||
Blends vectors in two vectors according to a mask. Elements for which corresponding element in mask
is set to ones are picked from the on
vector. Elements for which corresponding element in mask
is set to zeroes are picked from the off
vector.
The return type is a vector expression of N
bytes. The vector type is governed by the expression promotion rules.
Contents |
Parameters
on, off, mask | - | any two vectors of same size |
Return value
A vector expression evaluating to mask ? on : off
.
Equivalent operation
r0 = mask0 ? on0 : off0 ... rN = maskN ? onN : offN
See also
This section is incomplete |