| 63 | |
| 64 | template <class T> |
| 65 | static IMATH_NAMESPACE::Vec4<T> |
| 66 | Vec4Array_min(const FixedArray<IMATH_NAMESPACE::Vec4<T> > &a) { |
| 67 | Vec4<T> tmp(Vec4<T>(0)); |
| 68 | size_t len = a.len(); |
| 69 | if (len > 0) |
| 70 | tmp = a[0]; |
| 71 | for (size_t i=1; i < len; ++i) |
| 72 | { |
| 73 | if (a[i].x < tmp.x) |
| 74 | tmp.x = a[i].x; |
| 75 | if (a[i].y < tmp.y) |
| 76 | tmp.y = a[i].y; |
| 77 | if (a[i].z < tmp.z) |
| 78 | tmp.z = a[i].z; |
| 79 | if (a[i].w < tmp.w) |
| 80 | tmp.w = a[i].w; |
| 81 | } |
| 82 | return tmp; |
| 83 | } |
| 84 | |
| 85 | template <class T> |
| 86 | static IMATH_NAMESPACE::Vec4<T> |