Jump to content

physics shapes of sculpted prims


Gaia Clary
 Share

You are about to reply to a thread that has been inactive for 2075 days.

Please take a moment to consider if this thread is worth bumping.

Recommended Posts

Hi. I was curious to see how the actual physics shape for a sculpted prim might look. So i went to aditi, rezzed my primstar and got an astonishing result:

When i set Physics type to "Prim" (which seems to be the dafault for Sculpties) nothing shows up in the viewers physics shape display.  But when i set it to "Convex Hull,something shows up (see right most image):

sculpty_physics_shape.png

This is a flat disk.

10 minutes later when i wanted to create a jira and make some more images, i got another result when enabling Convex Hull:

p2.png

When i try the same on main grid, i can not see any physics shape on sculpties.

All of that is not expected...

Any idea around what is going on ?

Link to comment
Share on other sites


Josh Susanto wrote:

 As far as I know, the physics of sculpts on the main grid are always those of the sphere you'll often see while the sculpt is rezzing.

As far as i know it is a torus like shape. I am not satisfied with believing. I want the proof!

Link to comment
Share on other sites

Actually, I believe it's the convex hull of a torus with major radius = minor radius (no hole through the middle). So it has flat faces about half the diameter across the ends in one direction. How about this. These are four physical spheres on the end of a sculpty.  They would roll off if it isn't flat. The physical cubes fell off the rest of that surface. The flat ends are perpendicular to the local X axis.  This is actually a fence. I made it cube dimensions for this test.  If only we had cloth, then this would be easy.

sculpty_pshape_flats.jpg

I don't understand the physics shape display. For this one, I can only see the wireframe thingy filling only part of the bounding box! It can switch with size between Prim and CH (see my last long post) without that showing up on the edit dialog.

By the way, last I triede you could link transparent undistorted boxes, spheres and/or cylinders to the sculpty then set the sculpty ty physics type None, and get the physics shape prims for 0.1 prim each, as with meshes. I expect they will be 0.5 each now :matte-motes-crying:.

Link to comment
Share on other sites

Has to do with poles, being used to create "air" between sculpts.

It rezzes as a sphere (the torus is just a stitching option) not the shape of your mesh.

I use this method in one of my products, try this easy to test.

 

Sculpt 2 prims like so.

 

CUBE-------------------------CUBE 

 

then sculpt it, or upload the map as so.

You cannot walk inbetween the line  you will see when yor boundrybox makes contant. walk around it pushing it, you will see its a sphere.:matte-motes-asleep-2:

(as i use sculptstudio) unless with phantom. There is properly a way to eliminate that but i have not found that as of yet.

Link to comment
Share on other sites

You need a physics shape mesh with the hole for the door in it, and set to physics type Prim OR link in some boxes (as few as possible), one being the root, stretch them (no other distortions) to fill the shape, leaving the hole fpr the door, make them transparent, edit selected on the mesh and set it's physics type to "None" on the Features tab. The latter works for meshes and sculpties (at least it used to).

Link to comment
Share on other sites

Correct me if im wrong here, by my knowing the sculptie there, its boundry box gives its actual shape so that means retangle unless you defined it different with your sculpttool (depends on what tool used).

 

With multi sculps like i suggest above this post, what are your result? If you are willing to try that please post them

 

 

Link to comment
Share on other sites

right I tried to import a physics mesh for the building but it treated it the same as the building mesh itself.. which nullifies its purpose even when in preview it shows it should have appropriate hole. kinda seems to defeate the purpose of mesh though if I have to add extra prims in order to save a few by doing mesh to make a building.

Link to comment
Share on other sites

No. I believe the physics/collision shape is not the bounding box. It is always this torus vonvex hull thing. See here, for example, the same sculpty, made physicsl and sitting on the flat end, or on a ronded part of the side, of the physics shape. When it's on the rounded bit, the visual part of it, which is still inside the bounding box, penetrates into the flat surface that it rests on.

sculpty_round_edges.jpg

I'm not sure what you mean by "multi-sculpty". If that is several sculpties arranged and/or linked together, then I think each of them will have the same torus-convex-hull collision/physics shape. the linked assembly will then behave like a convex hull of the whole lot for resting on flat surfaces, but will allow things to penetrate into the gaps between them. Here is a picture of four of the same dculpty made physics and linked together and placed on a flat surface. Then an array of 12x12 physical cubes was dropped from just above the top surface. The scylpties are made tranparent so you can see where the cubes dropped in between the sculpty physics shapes where they are rounded. The pile in the middle shows that the physics shapes of the linked sculpties behave independently. Note the ones nleft resting on the flat parts too.

sculpty_pshape_3.jpg

Link to comment
Share on other sites

Multisculpt, as in 1 primmed sculpts with multiple shapes ...

For instance sculpt studio uses a boundrybox *retangled* that affects the real shape of a sculpt What i ment is sculpt 2 cubes with it like so.

 

CUBE------------CUBE

 

The dotted line is air, so with SS using the pole slices to do that. When i drop prims on that i see that the BOUNDRY box is for sure retangled were it suppose to fall through on the floo. I will try to post few pics when i have time to show what i ment..

Link to comment
Share on other sites

You mean like these? The top shows two different versions, with the cubes separated on the X axis (left four) or on the Z axis (right three). These are all physical. They are textured with a scaled-up version of their own sculptmaps, which are shown on the panels. Since the flat parts of the collision/physics shape are at opposite ends of the X axis, the one on the left can balance on its end. Th one on the rifgt cannot, because the end is ronded. You can see that both will rest on the ground at an angle with part of their visual shape penetrating the ground, because the other sides are rounded.

Below is a picture of a non-physical bicube that has been made semi-transparent. It is resting on one of the flat faces. The plywood objects are all physical and are vleaning on the collision/physics shape of the bicube. You can see two things about that shape. First, it is there in the middle where the visual shape is empty, supporting the thin rods; second, the wide planks penetrate the visual shape to rest on the rounded physical shape inside. This proves that the collision/physics shape is not the bounding box.

sculptpshape1.jpg

Link to comment
Share on other sites

  • 4 weeks later...

Hey folks,

 

I'm a bit late to this thread, but I thought I'd chime in. Drongle is 100% correct. The physics shape is the convex hull of a torus. The viewer's physics shape display feature does not work in all cases. The server does not send down the real physics shape, so the viewer tries to follow the same logic as the server to derive the shape. This doesn't work in all cases and can easily get out of sync with the server. I'm not sure it was ever fully implemented for sculpts. Feel free to submit a feature request.

 

Falcon

Link to comment
Share on other sites

  • 4 years later...

I do not know what the physics shape of a sculpt is; however, I can say with certainty it is not the same as a convex hull torrus and you can prove it for yourself. Rez a sculpt or create a regular prim and set it to sculpt shape instead of box. Make sure the physics shape is set to prim if you rezzed one out of inventory.

Set the size large, say 64x64x64 so the changes will be more dramatic (and obvious). Copy the location and size of the sculpt using the C (of the CPp) buttons. Rez a torrus and paste the location and size using the P buttons. Get on top of the torrus, walking to the center of the divot. Change the physics shape to Convex Hull. When you do,  you'll rise. Set the sculpty to phantom and you'll fall. Ergo they do not have the same physics shape.

Now maybe you're thinking I forgot about rotation, but I did not. You can check for yourself if the rotation of both is set the same you will always fall when you make the torrus phantom.

Link to comment
Share on other sites

I'm not sure what the problem is with your experiment, but I repeated it 9except usiong 32m instead of 64) with the results shown in the picture. Both sculpty (default map apple shape) and torus are 32x32x32. Torus is all defualt parameters, as when first rezzed. Both are rotated through 90 degrees about the Y axis, so that the torus dimple (and the flat top of the sculpty physics shape) are on the top. Note that this does NOT put the sculpty dimple on top. That is dimpled along the Z axis, while the torus dimples are along the X axis. The sculpty is transparent blue blank texture; torus is transparent yellow blank texture. Ruler divisions are 1m. In all cases, I flew up and then dropped down until I landed on the surface. On the left, the sculpty is Phantom and the torus is Convex Hull. In the middle, the sculpty is still Phantom, but the torus is Prim. On the right, the sculpty is Prim, and the torus is Phantom. So the position where the avatar came to rest on both the convex hull of the torus (left) and the Prim-type phsyics shape of the sculpty (right) are identical, as predicted is the phsyics shape os the sculpty is indeed the convex hull of the torus. Note that the visible geometry of this sculpty does not fill the whole of the space occupied by its physics shape. This is quite common with sculpties which do not use the entire range of RGB colour values in their maps, and thus do not use the entire dimensions of the bounding box.

 

Link to comment
Share on other sites


Drongle McMahon wrote:

No. I believe the physics/collision shape is not the bounding box.

I can confirm that. It is some kind of rounded shape within the boundign box, not the bounding box itself. I never really tried to figure out exactly what kind of shape though.

 

Edit Until now... See my next post

Link to comment
Share on other sites

I learned a trick from Maestro Linden once. He told me he didn't trust the physics shape display himself and used pathfinding view instead. If I understood him correctly, the main reason was that the physics shape display is generated by the viewer while pathfinder view is done by server. You can find it at Build -> Pathfinding -> Viev / test... Switch "Static Obstacles" on.

Some limitations here: pathfinding view only works with objcets and linksets marked as static obstacles, the navmesh has to be updated (use "Rebake Region" for that) and the physics shape that gets displayed that way may well obscure or be obscured by the visual model.

Now, this is where it gets really interesting. Here is the physics shape of the good old apple sculpt according to the navmesh. The physics shape hides the visual shape completely in this case so I added a copy of the apple without the physics shape beside it



 

And here is a trio of cubes with navmesh physics shape. In this case the physics model was much smaller than the visual so I made the cubes slightly transparent to show both.



Link to comment
Share on other sites

Oh, well remembered ChinRey. That's pretty definitive. I we look at cubes of different size, we can see that the inward displacement of the collision shape is constant, irrespective of size. This is presumably to counteract the ~0.1m float gap between the avatar and a mesh physics shape, so that the avatar appears to be standing exactly on the visible cube.



The torus convex hull is a bit unusual, as it isn't symetrical in the direction of the hole. Here are three objects with the phsyics revealed by the pathfinding method. On the left is a sculpty (default map). Next is a torus with physics shape set to convex hull, and on the right is the same torus with the physics shape set to Prim. In the top row, duplicates of the same objects have been rotated to look at the other end. In the torus (apart from a bit of strange triangulation for the convex hull) the physics shape has faces flat in the vertical plane, but at the other it's an edge that protrudes. The shape is actually a 9x9 torus. The convex hull, but apparently not the Prim shape, has the same inset from the visible shape as the cube. The physics of the sculpty (left) has the same geometry, subdivisions and and asymmetry, as the convex hull of the torus. That gives us extra confirmatiuon that it is the convex hull of a torus. It's interesting that the asymmetry means that both torus and sculpties might sometimes show different behaviour depending on which end they are stood.



Also, the small number of faces around the perimeter of the torus physics explains why it rolls badly. If you look at a sdphere, its physics is a subdivided icosohedron, which is much smoother, allowing it to roll much more easily.

  • Like 1
Link to comment
Share on other sites

You are about to reply to a thread that has been inactive for 2075 days.

Please take a moment to consider if this thread is worth bumping.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

×
×
  • Create New...