Browse Source

Update UnrealLoader.h

use memcpy instead of = operator for pos copy.
Kim Kulling 6 years ago
parent
commit
103048ff85
1 changed files with 2 additions and 1 deletions
  1. 2 1
      code/Unreal/UnrealLoader.h

+ 2 - 1
code/Unreal/UnrealLoader.h

@@ -127,7 +127,8 @@ inline void CompressVertex(const aiVector3D& v, uint32_t& out)
     n.X = (int32_t)v.x;
     n.X = (int32_t)v.x;
     n.Y = (int32_t)v.y;
     n.Y = (int32_t)v.y;
     n.Z = (int32_t)v.z;
     n.Z = (int32_t)v.z;
-    out = t;
+    ::memcpy( &out, &t, sizeof(int32_t));
+    //out = t;
 }
 }
 
 
     // UNREAL vertex decompression
     // UNREAL vertex decompression