PeriDyno 1.0.0
Loading...
Searching...
No Matches
TetraMeshWriterFracture.h
Go to the documentation of this file.
1/*
2This Module is designed to output surface mesh file of TetrahedronSet;
3the output file format: obj
4*/
5
6#pragma once
9
10#include "Topology/TetrahedronSet.h"
11
12#include <string>
13#include <memory>
14
15namespace dyno
16{
17
18 template <typename TDataType> class TriangleSet;
19 template <typename TDataType> class TetrahedronSet;
20
21
23 {
27 {
29 }
31 {
33 }
35 {
36 return vertexId1 + vertexId2 + vertexId3;
37 }
38 };
39
40
41 template<typename TDataType>
43 {
45
46 public:
47 typedef typename TDataType::Real Real;
48 typedef typename TDataType::Coord Coord;
52
55
56 void loadUVs(std::string path);
57
59 bool updatePtr();
60
61 bool outputSurfaceMesh();
62
64
65 protected:
66
67 public:
68
69
70 protected:
71
72 std::string file_postfix = ".obj";
73
78 std::shared_ptr<TetrahedronSet<TDataType>> ptr_TetrahedronSet;
79
81
82
83 bool first = true;
84
85
90
91 std::vector<Coord> vnList;
92 };
93}
#define DECLARE_TCLASS(name, T1)
Definition Object.h:87
TopologyModule::Tetrahedron Tetrahedron
std::shared_ptr< TetrahedronSet< TDataType > > ptr_TetrahedronSet
void setTetrahedronSetPtr(std::shared_ptr< TetrahedronSet< TDataType > > ptr_tets)
VectorND< PointType, 2 > Tri2Tet
VectorND< PointType, 4 > Tetrahedron
Vector< PointType, 3 > Triangle
This is an implementation of AdditiveCCD based on peridyno.
Definition Array.h:25
Array< T, DeviceType::GPU > DArray
Definition Array.inl:89
DYN_FUNC T minimum(const T &v0, const T &v1)
Definition SimpleMath.h:120
Array< T, DeviceType::CPU > CArray
Definition Array.h:151
DYN_FUNC T maximum(const T &v0, const T &v1)
Definition SimpleMath.h:160