MCPcopy Create free account
hub / github.com/EricLengyel/Terathon-Math-Library / VecTransformPoint3D

Function VecTransformPoint3D

TSSimd.h:1915–1931  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1913 }
1914
1915 inline vec_float VecTransformPoint3D(const vec_float& c1, const vec_float& c2, const vec_float& c3, const vec_float& c4, const vec_float& p)
1916 {
1917 #if defined(TERATHON_SSE)
1918
1919 vec_float result = _mm_mul_ps(c1, VecSmearX(p));
1920 result = _mm_add_ps(result, _mm_mul_ps(c2, VecSmearY(p)));
1921 result = _mm_add_ps(result, _mm_mul_ps(c3, VecSmearZ(p)));
1922 return (_mm_add_ps(result, c4));
1923
1924 #elif defined(TERATHON_NEON)
1925
1926 vec_float result = vmulq_f32(c1, VecSmearX(p));
1927 result = vfmaq_f32(result, c2, VecSmearY(p));
1928 return (vaddq_f32(vfmaq_f32(result, c3, VecSmearZ(p)), c4));
1929
1930 #endif
1931 }
1932
1933 inline vec_int8 VecInt8GetZero(void)
1934 {

Callers 2

operator *Method · 0.85
TransformPoint3DMethod · 0.85

Calls 3

VecSmearXFunction · 0.85
VecSmearYFunction · 0.85
VecSmearZFunction · 0.85

Tested by

no test coverage detected