:orphan: # 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 ## 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 [](ch_unstructured), `DM`, `DMPLEX`, `DMPlexTransform`, `DMPlexTransformRegisterAll()`, `DMPlexTransformRegisterDestroy()` ## Level advanced ## Location src/dm/impls/plex/transform/interface/plextransform.c --- [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](/manualpages/index.md) [Index of all manual pages](/manualpages/singleindex.md)