Custom 3D collision shape

#1

Anyone have an idea on how to prepare a custom 3d collision shape? @sven ?

When I try with a custom convexshape I sometimes get

WARNING:PHYSICS: Overflow in AABB, object removed from simulation
WARNING:PHYSICS: If you can reproduce this, please email bugs@continuousphysics.com

WARNING:PHYSICS: Please include above information, your Platform, version of OS.

WARNING:PHYSICS: Thanks.

Here is attempt at making a cube

shape_type: TYPE_HULL
data: -1
data: -1
data: -1
data: -1
data: -1
data: -1
data: -1
data: 1
data: -1
data: -1
data: 1
data: 1
data: 1
data: -1
data: -1
data: 1
data: -1
data: 1
data: 1
data: 1
data: -1
data: 1
data: 1
data: 1

But it looks like this

2017-10-13 02_37_50-Defold Standard Geometry

What I’d like is to be able to define .dae files as collision shapes so objects can use their own geometry for collision, or be able to set a simplified version of their .dae for collision, or be able to have/make a tool which can convert .dae files to proper collision shape files.

4 Likes

#2

I’ve made a note to investigate what the current status is on this. Will check on Monday.
If there isn’t already a ticket I’ll make sure to create one and bring it up asap as it’s certainly something we want, especially considering our current take on 3D and performance.

5 Likes

#3

Added ticket DEF-2927. I can’t give any ETA at the very moment though.

1 Like

#4

Can you post what the version of the bullet physics library being used is?

0 Likes

#5

Version 2.77

1 Like

#6

Download for anyone interested https://storage.googleapis.com/google-code-archive-downloads/v2/code.google.com/bullet/bullet-2.77.zip

I’ll read the docs for this version.

4 Likes

#7

Have custom 3D collision shapes been added since these posts?

0 Likes

#8

Sadly not for meshes. Bullet physics should easily be able to support it too…

0 Likes

#9

Okay, cheers. What about .convexshape in 3D?

0 Likes

#10

You could try getting it to work, the original post in this thread was my last attempt at it.

If we could have static meshes for levels/terrain that could be enough for many 3d game use cases.

0 Likes

#11

Here is my attempt using @selimanac’s editor with a slightly angled camera. It almost works, but I think the 0 depth makes it freak out a bit.

3D:

2D:

2 Likes