Skip to content

What's the right way to use TetGen? #97

Closed

Description

@Xayah-Hina

Hi~

I'm working on a FEM simulation on PositionBasedDynamics and get trapped by the right way to convert a obj mesh to a tet model.

In the example scene DeformableSolidCollisionScene, I learned that .ele file and .node file are required to get a tetrahedron model, they're produced by the tool TetGen.

But unfortunately, I found that TetGen seems not to support a direct approach to convert a .obj file to .ele and .node TetGen doc, it seems only support .off .ply .stl .mesh. And there is a command tetgen -pqa5000.0 Armadillo_UV_low.off at the last line of the files armadillo_4k.ele and armadillo_4k.node, which hints that a .off is required, but I don't know where can I get the .off file...


So my confusion is that,

  • how can I use TetGen correctly when working on PositionBasedDynamics?

more specifically,

  • what is the .off file?
  • is it simply converted from a .obj file or whatever else?
  • what is the most recommended way to do with TetGen and PositionBasedDynamics?

Best regards~

Activity

  1. korzen commented on May 10, 2021

    @korzen

    Hi, you can convert obj to ply and/or stl using e.g. free MeshLab.

    TetGen has great documention http://wias-berlin.de/software/tetgen/1.5/doc/manual/manual006.html#sec88

  2. Xayah-Hina commented on May 10, 2021

    @Xayah-Hina
    Author

    @korzen Oh yes, I used MeshLab. my question now is: why don't the visFile in xxxScene.json directly support ply or off format?

    and btw, if I want to realize dynamic tetrahedralization and fracture like this -> Adaptive Tetrahedral Meshes for Brittle Fracture Simulation, I wonder if there is any convenient approach for PositionBasedDynamics framework?

    Sorry to bother you for my personal problems~ I'm new to physics based animation, and really appreciate your help! ~(≥▽≤)/~

  3. janbender commented on May 10, 2021

    @janbender
    Member

    @korzen Oh yes, I used MeshLab. my question now is: why don't the visFile in xxxScene.json directly support ply or off format?

    The simple answer is: because nobody had time to implement this yet ;-)

  4. Xayah-Hina commented on May 10, 2021

    @Xayah-Hina
    Author

    @janbender I see it~ thank you guys for this awesome work~ ଘ(੭ˊᵕˋ)੭

  5. Xayah-Hina commented on May 22, 2021

    @Xayah-Hina
    Author

    @korzen I feel so sad that I still can not convert correctly using TetGen. T.T

    in fact, I can successfully convert some simple model like sphere.ply and dragon_vrip_res4.ply using tetgen -pq mymodel.ply command. But when it comes to some complex model like bun_zipper.ply and my branch model branch.ply, it can't work properly any more...

    terminal message:
    p1

    output files:
    p2

    my models:
    models.zip

    I really wonder why ToT... Apologize to bother you but could you please offer me some advice for my confusion? Thanks a lot!

  6. janbender commented on May 26, 2021

    @janbender
    Member

    I'm no expert in using TetGen but maybe TetWild can give you better results:

    https://github.com/Yixin-Hu/TetWild

  7. locked and limited conversation to collaborators on Nov 30, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions