Fix bone aabb calculation, which caused a skeletal mesh culling issue
There was a bug that could result in most bone aabb boxes ending up with tiny size upon import and mess up with culling of skeletal meshes. This fixes it.
This commit is contained in:
parent
775e74e0d4
commit
ff318d91ee
|
@ -776,7 +776,7 @@ Error VisualServer::_surface_set_data(Array p_arrays, uint32_t p_format, uint32_
|
||||||
continue; //break;
|
continue; //break;
|
||||||
ERR_FAIL_INDEX_V(idx, total_bones, ERR_INVALID_DATA);
|
ERR_FAIL_INDEX_V(idx, total_bones, ERR_INVALID_DATA);
|
||||||
|
|
||||||
if (bptr->size.x < 0) {
|
if (bptr[idx].size.x < 0) {
|
||||||
//first
|
//first
|
||||||
bptr[idx] = AABB(v, SMALL_VEC3);
|
bptr[idx] = AABB(v, SMALL_VEC3);
|
||||||
any_valid = true;
|
any_valid = true;
|
||||||
|
|
Loading…
Reference in New Issue