# OpenGL Splitting a cuboid body

This topic is 4239 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

## Recommended Posts

Hello Im working with the physic engine ODE and OpenGL, and I try to split 3D-Bodys (I use cuboids) into two smaller parts. Now I have the problem that I dont know how to compute the positions of the "smaller body parts". What I have is: -The rotation matrix of my cuboid -The center point of the cuboid -The side lenghs of the cuboid Here I have a sketch: So I need somehow to compute the Point P2 and P3, this will be the center points of the small body parts, so I can simulate the break of my body. I hope somebody can help me out, or maybe had the same problem and solve it another way, couse I really have a hard time with this :)

##### Share on other sites
This is more of a Math and Physics problem, but what you need to do is get the transformations of the prism's axes. This is simply a row (column?) of the rotation matrix, scaled by the distance from the center to the new center. Then you take that and add it to the original position vector.

1. 1
2. 2
Rutin
19
3. 3
khawk
18
4. 4
5. 5
A4L
11

• 9
• 12
• 16
• 26
• 10
• ### Forum Statistics

• Total Topics
633769
• Total Posts
3013759
×