Skip to content

Commit

Permalink
Fixed incorrect use of __m128i where __m128 should have been used.
Browse files Browse the repository at this point in the history
  • Loading branch information
hamsham committed Jan 3, 2019
1 parent 0fdcf76 commit 39bb203
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions soft_render/src/SR_FragmentProcessor.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -414,12 +414,12 @@ void SR_FragmentProcessor::render_triangle(const uint_fast64_t binId, const SR_T
if (p0[1] < p2[1]) std::swap(p0, p2);
if (p1[1] < p2[1]) std::swap(p1, p2);

const __m128i p0x = _mm_set1_ps(p0[0]);
const __m128i p0y = _mm_set1_ps(p0[1]);
const __m128i p1x = _mm_set1_ps(p1[0]);
const __m128i p1y = _mm_set1_ps(p1[1]);
const __m128i p2x = _mm_set1_ps(p2[0]);
const __m128i p2y = _mm_set1_ps(p2[1]);
const __m128 p0x = _mm_set1_ps(p0[0]);
const __m128 p0y = _mm_set1_ps(p0[1]);
const __m128 p1x = _mm_set1_ps(p1[0]);
const __m128 p1y = _mm_set1_ps(p1[1]);
const __m128 p2x = _mm_set1_ps(p2[0]);
const __m128 p2y = _mm_set1_ps(p2[1]);
const __m128 p10x = _mm_sub_ps(p1x, p0x);
const __m128 p20x = _mm_sub_ps(p2x, p0x);
const __m128 p21x = _mm_sub_ps(p2x, p1x);
Expand Down

0 comments on commit 39bb203

Please sign in to comment.