t8  UNKNOWN
t8code is a C library to manage a forest of adaptive space-trees of general element classes in parallel.
Typedefs | Functions
t8_geometry_cad.h File Reference

This header provides the C interface to create a cad geometry. More...

#include <t8.h>
#include <t8_geometry/t8_geometry.h>
#include <t8_geometry/t8_geometry_with_vertices.h>

Go to the source code of this file.

Typedefs

typedef struct t8_geometry_cad t8_geometry_cad_c
 This typedef holds virtual functions for a particular geometry. More...
 

Functions

t8_geometry_cad_ct8_geometry_cad_new (int dim, const char *fileprefix, const char *name_in)
 Create a new cad geometry with a given dimension. More...
 
void t8_geometry_cad_destroy (t8_geometry_cad_c **geom)
 Destroy a cad geometry that was created with t8_geometry_cad_new. More...
 

Detailed Description

This header provides the C interface to create a cad geometry.

Typedef Documentation

◆ t8_geometry_cad_c

This typedef holds virtual functions for a particular geometry.

We need it so that we can use t8_geometry_cad_c pointers in .c files without them seeing the actual C++ code (and then not compiling)

Function Documentation

◆ t8_geometry_cad_destroy()

void t8_geometry_cad_destroy ( t8_geometry_cad_c **  geom)

Destroy a cad geometry that was created with t8_geometry_cad_new.

Parameters
[in,out]geomA cad geometry. Set to NULL on output.

◆ t8_geometry_cad_new()

t8_geometry_cad_c* t8_geometry_cad_new ( int  dim,
const char *  fileprefix,
const char *  name_in 
)

Create a new cad geometry with a given dimension.

The geometry is currently viable with quad/hex and triangle trees. Tets will be supported soon. The geometry uses as many vertices as the tree type has, as well as additional geometry information, which is extracted from a .brep file. The vertices are saved via the t8_cmesh_set_tree_vertices function. Since the internals of this geometry are finely tuned to the .brep file it is recommended to only use it with the t8_cmesh_readmshfile function.

Parameters
[in]dim0 <= dimension <= 3. The dimension.
[in]fileprefixPrefix of a .brep file from which to extract an cad geometry.
[in]nameThe name to give this geometry.
Returns
A pointer to an allocated t8_geometry_cad struct, as if the t8_geometry_cad (int dim, const *char fileprefix, const char *name) constructor was called.