MeshLib C Docs
Loading...
Searching...
No Matches
MRAlignTextToMesh.h
Go to the documentation of this file.
1#pragma once
2
3#include <MRCMesh/MRVector2.h>
4#include <MRCMesh/MRVector3.h>
5#include <MRCMisc/common.h>
6#include <MRCMisc/exports.h>
7
8#include <stdbool.h>
9#include <stddef.h>
10
11#ifdef __cplusplus
12extern "C" {
13#endif
14
15typedef struct MR_Mesh MR_Mesh; // Defined in `#include <MRCMesh/MRMesh.h>`.
16typedef struct MR_MeshTriPoint MR_MeshTriPoint; // Defined in `#include <MRCMesh/MRMeshTriPoint.h>`.
17typedef struct MR_SymbolMeshParams MR_SymbolMeshParams; // Defined in `#include <MRCSymbolMesh/MRSymbolMesh.h>`.
18typedef struct MR_expected_MR_Mesh_std_string MR_expected_MR_Mesh_std_string; // Defined in `#include <MRCMisc/expected_MR_Mesh_std_string.h>`.
19
20
26
27// Start coordinate on mesh, represent lowest left corner of text
32
33// Start coordinate on mesh, represent lowest left corner of text
38
39// Start coordinate on mesh, represent lowest left corner of text
44
45// Position of the startPoint in a text bounding box
46// (0, 0) - bottom left, (0, 1) - bottom right, (0.5, 0.5) - center, (1, 1) - top right
51
52// Position of the startPoint in a text bounding box
53// (0, 0) - bottom left, (0, 1) - bottom right, (0.5, 0.5) - center, (1, 1) - top right
57
58// Position of the startPoint in a text bounding box
59// (0, 0) - bottom left, (0, 1) - bottom right, (0.5, 0.5) - center, (1, 1) - top right
64
65// Direction of text
70
71// Direction of text
75
76// Direction of text
81
82// Text normal to surface, if nullptr - use mesh normal at `startPoint`
87
88// Text normal to surface, if nullptr - use mesh normal at `startPoint`
92
93// Text normal to surface, if nullptr - use mesh normal at `startPoint`
98
99// Font height, meters
104
105// Font height, meters
109
110// Font height, meters
115
116// Text mesh inside and outside offset of input mesh
121
122// Text mesh inside and outside offset of input mesh
126
127// Text mesh inside and outside offset of input mesh
132
133// Maximum possible movement of text mesh alignment, meters
138
139// Maximum possible movement of text mesh alignment, meters
143
144// Maximum possible movement of text mesh alignment, meters
149
150// If true then size of each symbol will be calculated from font height, otherwise - on bounding box of the text
155
156// If true then size of each symbol will be calculated from font height, otherwise - on bounding box of the text
160
161// If true then size of each symbol will be calculated from font height, otherwise - on bounding box of the text
166
170
175
178
181
185
188
192
195
198
203
204// Creates symbol mesh and aligns it to given surface
210
211#ifdef __cplusplus
212} // extern "C"
213#endif
struct MR_MeshTriPoint MR_MeshTriPoint
Definition MRAggregateFlow.h:13
MRC_API MR_TextMeshAlignParams * MR_TextMeshAlignParams_ConstructFromAnother(MR_PassBy _other_pass_by, MR_TextMeshAlignParams *_other)
MRC_API MR_SymbolMeshParams * MR_TextMeshAlignParams_MutableUpcastTo_MR_SymbolMeshParams(MR_TextMeshAlignParams *object)
Upcasts an instance of MR::TextMeshAlignParams to its base class MR::SymbolMeshParams.
MRC_API MR_expected_MR_Mesh_std_string * MR_alignTextToMesh(const MR_Mesh *mesh, const MR_TextMeshAlignParams *params)
MRC_API void MR_TextMeshAlignParams_DestroyArray(const MR_TextMeshAlignParams *_this)
Destroys a heap-allocated array of MR_TextMeshAlignParams. Does nothing if the pointer is null.
MRC_API void MR_TextMeshAlignParams_Destroy(const MR_TextMeshAlignParams *_this)
Destroys a heap-allocated instance of MR_TextMeshAlignParams. Does nothing if the pointer is null.
struct MR_TextMeshAlignParams MR_TextMeshAlignParams
Definition MRAlignTextToMesh.h:25
MRC_API void MR_TextMeshAlignParams_Set_surfaceOffset(MR_TextMeshAlignParams *_this, float value)
MRC_API void MR_TextMeshAlignParams_Set_direction(MR_TextMeshAlignParams *_this, MR_Vector3f value)
MRC_API MR_TextMeshAlignParams * MR_TextMeshAlignParams_AssignFromAnother(MR_TextMeshAlignParams *_this, MR_PassBy _other_pass_by, MR_TextMeshAlignParams *_other)
MRC_API float * MR_TextMeshAlignParams_GetMutable_textMaximumMovement(MR_TextMeshAlignParams *_this)
MRC_API MR_Vector3f * MR_TextMeshAlignParams_GetMutable_direction(MR_TextMeshAlignParams *_this)
MRC_API const MR_Vector2f * MR_TextMeshAlignParams_Get_pivotPoint(const MR_TextMeshAlignParams *_this)
MRC_API void MR_TextMeshAlignParams_Set_fontBasedSizeCalc(MR_TextMeshAlignParams *_this, bool value)
MRC_API const float * MR_TextMeshAlignParams_Get_surfaceOffset(const MR_TextMeshAlignParams *_this)
MRC_API MR_Vector2f * MR_TextMeshAlignParams_GetMutable_pivotPoint(MR_TextMeshAlignParams *_this)
MRC_API const MR_Vector3f *const * MR_TextMeshAlignParams_Get_textNormal(const MR_TextMeshAlignParams *_this)
MRC_API void MR_TextMeshAlignParams_Set_fontHeight(MR_TextMeshAlignParams *_this, float value)
MRC_API const MR_Vector3f ** MR_TextMeshAlignParams_GetMutable_textNormal(MR_TextMeshAlignParams *_this)
MRC_API void MR_TextMeshAlignParams_Set_textNormal(MR_TextMeshAlignParams *_this, const MR_Vector3f *value)
MRC_API const float * MR_TextMeshAlignParams_Get_fontHeight(const MR_TextMeshAlignParams *_this)
MRC_API const MR_MeshTriPoint * MR_TextMeshAlignParams_Get_startPoint(const MR_TextMeshAlignParams *_this)
MRC_API const bool * MR_TextMeshAlignParams_Get_fontBasedSizeCalc(const MR_TextMeshAlignParams *_this)
MRC_API MR_MeshTriPoint * MR_TextMeshAlignParams_GetMutable_startPoint(MR_TextMeshAlignParams *_this)
MRC_API MR_TextMeshAlignParams * MR_TextMeshAlignParams_OffsetMutablePtr(MR_TextMeshAlignParams *ptr, ptrdiff_t i)
Offsets a pointer to an array element by i positions (not bytes). Use only if you're certain that the...
MRC_API void MR_TextMeshAlignParams_Set_pivotPoint(MR_TextMeshAlignParams *_this, MR_Vector2f value)
MRC_API float * MR_TextMeshAlignParams_GetMutable_surfaceOffset(MR_TextMeshAlignParams *_this)
MRC_API void MR_TextMeshAlignParams_Set_startPoint(MR_TextMeshAlignParams *_this, const MR_MeshTriPoint *value)
MRC_API float * MR_TextMeshAlignParams_GetMutable_fontHeight(MR_TextMeshAlignParams *_this)
MRC_API const MR_Vector3f * MR_TextMeshAlignParams_Get_direction(const MR_TextMeshAlignParams *_this)
MRC_API void MR_TextMeshAlignParams_Set_textMaximumMovement(MR_TextMeshAlignParams *_this, float value)
struct MR_SymbolMeshParams MR_SymbolMeshParams
Definition MRAlignTextToMesh.h:17
MRC_API MR_TextMeshAlignParams * MR_TextMeshAlignParams_DefaultConstructArray(size_t num_elems)
MRC_API bool * MR_TextMeshAlignParams_GetMutable_fontBasedSizeCalc(MR_TextMeshAlignParams *_this)
MRC_API MR_TextMeshAlignParams * MR_TextMeshAlignParams_DefaultConstruct(void)
MRC_API const float * MR_TextMeshAlignParams_Get_textMaximumMovement(const MR_TextMeshAlignParams *_this)
MRC_API const MR_TextMeshAlignParams * MR_TextMeshAlignParams_OffsetPtr(const MR_TextMeshAlignParams *ptr, ptrdiff_t i)
Offsets a pointer to an array element by i positions (not bytes). Use only if you're certain that the...
MRC_API const MR_SymbolMeshParams * MR_TextMeshAlignParams_UpcastTo_MR_SymbolMeshParams(const MR_TextMeshAlignParams *object)
struct MR_expected_MR_Mesh_std_string MR_expected_MR_Mesh_std_string
Definition MRCtm.h:18
struct MR_Mesh MR_Mesh
Definition MRCtm.h:13
MR_PassBy
Definition common.h:19
#define MRC_API
Definition exports.h:11
Definition MRVector2.h:44
Definition MRVector3.h:51