Blender's not ideal for transforming AABBs

This commit is contained in:
Jack Andersen 2016-08-14 11:11:17 -10:00
parent c89b7692f3
commit eae83a1cb9
3 changed files with 4 additions and 12 deletions

View File

@ -875,7 +875,6 @@ uint32_t BlenderConnection::DataStream::Mesh::SkinBanks::addSurface
} }
BlenderConnection::DataStream::ColMesh::ColMesh(BlenderConnection& conn) BlenderConnection::DataStream::ColMesh::ColMesh(BlenderConnection& conn)
: aabbMin(conn), aabbMax(conn)
{ {
uint32_t matCount; uint32_t matCount;
conn._readBuf(&matCount, 4); conn._readBuf(&matCount, 4);

View File

@ -531,13 +531,6 @@ public:
/** Intermediate collision mesh representation prepared by blender from a single mesh object */ /** Intermediate collision mesh representation prepared by blender from a single mesh object */
struct ColMesh struct ColMesh
{ {
/* Object transform in scene */
//Matrix4f sceneXf;
/* Cumulative AABB */
Vector3f aabbMin;
Vector3f aabbMax;
/** HECL source and metadata of each material */ /** HECL source and metadata of each material */
struct Material struct Material
{ {

View File

@ -239,10 +239,10 @@ def cookcol(writebuf, mesh_obj):
#wmtx[3][0], wmtx[3][1], wmtx[3][2], wmtx[3][3])) #wmtx[3][0], wmtx[3][1], wmtx[3][2], wmtx[3][3]))
# Filter out useless AABB points and send data # Filter out useless AABB points and send data
pt = wmtx * Vector(copy_obj.bound_box[0]) #pt = wmtx * Vector(copy_obj.bound_box[0])
writebuf(struct.pack('fff', pt[0], pt[1], pt[2])) #writebuf(struct.pack('fff', pt[0], pt[1], pt[2]))
pt = wmtx * Vector(copy_obj.bound_box[6]) #pt = wmtx * Vector(copy_obj.bound_box[6])
writebuf(struct.pack('fff', pt[0], pt[1], pt[2])) #writebuf(struct.pack('fff', pt[0], pt[1], pt[2]))
# Send materials # Send materials
writebuf(struct.pack('I', len(copy_mesh.materials))) writebuf(struct.pack('I', len(copy_mesh.materials)))