TBC Macros and Extensions

 View Only
Expand all | Collapse all

trying to understand ShellMeshInstance's properties Transform and GlobalTransformation

  • 1.  trying to understand ShellMeshInstance's properties Transform and GlobalTransformation

    Posted 02-18-2025 15:37
    Edited by Ronny Schneider 02-18-2025 15:42

    There is ShellMeshData with vertex coordinates defined in relation to that meshes reference point, let's assume here the center of gravity of a wheel.

    Then there is the ShellMeshInstance allowing you to place the same ShellMeshData at different locations.

    From my reasoning I'd assume that "Transform" is the relation of the center of gravity of a single wheel to the center of gravity of the whole car, and the "GlobalTransformation" is then "moving" the car to its final place in the world. (You could also keep the Transform.Translate of each wheel at zero, and place it with different GlobalTransformation correctly in the world)

    What I don't get is why the following two objects end up at the "same" location on the screen. Both ShellMeshData have vertices defined close to zero. But from my reasoning the palm tree should end up at coordinates twice as big, since it's "Transform" and "GlobalTransformation" are the same. Is this a special case where one of them is ignored?

    Palmtree

    A screenshot of a computer

Description automatically generated

    A screenshot of a computer

Description automatically generated

    A screenshot of a computer

Description automatically generated

     

    Machine

    A screenshot of a computer

Description automatically generated

    A screenshot of a computer

Description automatically generated

    A screenshot of a computer

Description automatically generated

     



    ------------------------------
    Ronny Schneider
    ------------------------------



  • 2.  RE: trying to understand ShellMeshInstance's properties Transform and GlobalTransformation

    Posted 02-18-2025 20:30

    I believe it has something to do with the ShellMeshInstance's parent, the BIMEntity, and its AffineTransformation.



    ------------------------------
    Ronny Schneider
    ------------------------------