# DMPlexTransformRegister
Adds a new transform component implementation 
## Synopsis
```
#include "petscdmplextransform.h" 
PetscErrorCode DMPlexTransformRegister(const char name[], PetscErrorCode (*create_func)(DMPlexTransform))
```
Not Collective


## Input Parameters

- ***name        -*** The name of a new user-defined creation routine
- ***create_func -*** The creation routine itself



## Sample usage
```none
  DMPlexTransformRegister("my_transform", MyTransformCreate);
```


Then, your transform type can be chosen with the procedural interface via
```none
  DMPlexTransformCreate(MPI_Comm, DMPlexTransform *);
  DMPlexTransformSetType(DMPlexTransform, "my_transform");
```

or at runtime via the option
```none
  -dm_plex_transform_type my_transform
```





## Note
`DMPlexTransformRegister()` may be called multiple times to add several user-defined transforms


## See Also
 [](chapter_unstructured), `DM`, `DMPLEX`, `DMPlexTransform`, `DMPlexTransformRegisterAll()`, `DMPlexTransformRegisterDestroy()`

## Level
advanced

## Location
<A HREF="PETSC_DOC_OUT_ROOT_PLACEHOLDER/src/dm/impls/plex/transform/interface/plextransform.c.html#DMPlexTransformRegister">src/dm/impls/plex/transform/interface/plextransform.c</A>


---
[Edit on GitLab](https://gitlab.com/petsc/petsc/-/edit/release/src/dm/impls/plex/transform/interface/plextransform.c)


[Index of all DMPlex routines](index.md)  
[Table of Contents for all manual pages](/docs/manualpages/index.md)  
[Index of all manual pages](/docs/manualpages/singleindex.md)  
