mirror of
https://github.com/bkaradzic/bimg.git
synced 2026-06-08 10:53:46 +00:00
Cleanup.
This commit is contained in:
@@ -928,7 +928,7 @@ namespace bimg
|
||||
xyz[1] += rgba1[5];
|
||||
xyz[2] += rgba1[6];
|
||||
|
||||
bx::store(dst, bx::normalize(bx::load(xyz) ) );
|
||||
bx::store(dst, bx::normalize(bx::load<bx::Vec3>(xyz) ) );
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -978,7 +978,7 @@ namespace bimg
|
||||
{
|
||||
const float* normal = (const float*)&nsaMip.m_data[(yy*nsaMip.m_width+xx)*(nsaMip.m_bpp/8)];
|
||||
const float solidAngle = normal[3];
|
||||
const float ndotl = bx::clamp(bx::dot(bx::load(normal), _dir), 0.0f, 1.0f);
|
||||
const float ndotl = bx::clamp(bx::dot(bx::load<bx::Vec3>(normal), _dir), 0.0f, 1.0f);
|
||||
|
||||
if (ndotl >= _specularAngle)
|
||||
{
|
||||
|
||||
@@ -90,7 +90,7 @@ void imageRgba32fNormalize(void* _dst, uint32_t _width, uint32_t _height, uint32
|
||||
const float* rgba = (const float*)&src[0];
|
||||
for (uint32_t xx = 0; xx < _width; ++xx, rgba += 4, dst += 16)
|
||||
{
|
||||
const bx::Vec3 xyz = bx::load(rgba);
|
||||
const bx::Vec3 xyz = bx::load<bx::Vec3>(rgba);
|
||||
bx::store(dst, bx::normalize(xyz) );
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user