mirror of
https://github.com/nillerusr/source-engine.git
synced 2026-08-07 17:29:36 +00:00
again boring misalignment fixes
This commit is contained in:
@@ -381,7 +381,7 @@ void CalcBoneQuaternion( int frame, float s,
|
||||
if ( panim->flags & STUDIO_ANIM_RAWROT )
|
||||
{
|
||||
Quaternion48 tmp;
|
||||
memcpy( &tmp, panim->pQuat48(), sizeof(Quaternion48) );
|
||||
V_memcpy( &tmp, panim->pQuat48(), sizeof(Quaternion48) );
|
||||
q = tmp;
|
||||
Assert( q.IsValid() );
|
||||
return;
|
||||
@@ -390,7 +390,7 @@ void CalcBoneQuaternion( int frame, float s,
|
||||
if ( panim->flags & STUDIO_ANIM_RAWROT2 )
|
||||
{
|
||||
Quaternion64 tmp;
|
||||
memcpy( &tmp, panim->pQuat64(), sizeof(Quaternion64) );
|
||||
V_memcpy( &tmp, panim->pQuat64(), sizeof(Quaternion64) );
|
||||
q = tmp;
|
||||
Assert( q.IsValid() );
|
||||
return;
|
||||
|
||||
@@ -705,7 +705,6 @@ inline void CUtlBuffer::GetTypeBin( T &dest )
|
||||
if ( !m_Byteswap.IsSwappingBytes() || ( sizeof( T ) == 1 ) )
|
||||
{
|
||||
memcpy(&dest, PeekGet(), sizeof(T) );
|
||||
dest = *(T *)PeekGet();
|
||||
}
|
||||
else
|
||||
{
|
||||
@@ -735,8 +734,7 @@ inline void CUtlBuffer::GetTypeBin< float >( float &dest )
|
||||
}
|
||||
else
|
||||
{
|
||||
// aligned read
|
||||
dest = *(float *)pData;
|
||||
memcpy( &dest, (void*)pData, sizeof(float) );
|
||||
}
|
||||
if ( m_Byteswap.IsSwappingBytes() )
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user