MeshLib C Docs
Loading...
Searching...
No Matches
MRCylinder3.h
Go to the documentation of this file.
1#pragma once
2
3#include <MRCMisc/exports.h>
4
5#include <stddef.h>
6
7#ifdef __cplusplus
8extern "C" {
9#endif
10
11typedef struct MR_Line3d MR_Line3d; // Defined in `#include <MRCMesh/MRLine.h>`.
12typedef struct MR_Line3f MR_Line3f; // Defined in `#include <MRCMesh/MRLine.h>`.
13typedef struct MR_Vector3d MR_Vector3d; // Defined in `#include <MRCMesh/MRVector3.h>`.
14typedef struct MR_Vector3f MR_Vector3f; // Defined in `#include <MRCMesh/MRVector3.h>`.
15
16
17// A class describing a cylinder as a mathematical object.A cylinder is represented by a centerline, a radius, and a length.template <typename T>
18// TODO: Cylinder3 could be infinite. For example for infinite Cylinder3 we could use negative length or length = -1
22
23// A class describing a cylinder as a mathematical object.A cylinder is represented by a centerline, a radius, and a length.template <typename T>
24// TODO: Cylinder3 could be infinite. For example for infinite Cylinder3 we could use negative length or length = -1
28
33
38
43
48
52
57
62
66
71
75
80
83
86
91
96MRC_API MR_Cylinder3f *MR_Cylinder3f_Construct_4(const MR_Vector3f *inCenter, const MR_Vector3f *inDirectoin, float inRadius, float inLength);
97
101MRC_API MR_Cylinder3f *MR_Cylinder3f_Construct_3(const MR_Line3f *inAxis, float inRadius, float inLength);
102
105
108
114
119
124
129
134
139
144
149
154
158
163
168
172
177
181
186
189
192
197
202MRC_API MR_Cylinder3d *MR_Cylinder3d_Construct_4(const MR_Vector3d *inCenter, const MR_Vector3d *inDirectoin, double inRadius, double inLength);
203
207MRC_API MR_Cylinder3d *MR_Cylinder3d_Construct_3(const MR_Line3d *inAxis, double inRadius, double inLength);
208
211
214
220
225
230
235
240
241#ifdef __cplusplus
242} // extern "C"
243#endif
struct MR_Line3d MR_Line3d
Definition MRBestFit.h:16
struct MR_Line3f MR_Line3f
Definition MRBestFit.h:17
MRC_API void MR_Cylinder3f_Destroy(const MR_Cylinder3f *_this)
Destroys a heap-allocated instance of MR_Cylinder3f. Does nothing if the pointer is null.
MRC_API const MR_Vector3f * MR_Cylinder3f_direction_const(const MR_Cylinder3f *_this)
MRC_API const MR_Cylinder3d * MR_Cylinder3d_OffsetPtr(const MR_Cylinder3d *ptr, ptrdiff_t i)
Offsets a pointer to an array element by i positions (not bytes). Use only if you're certain that the...
struct MR_Cylinder3f MR_Cylinder3f
Definition MRCylinder3.h:21
MRC_API const MR_Line3d * MR_Cylinder3d_Get_mainAxis(const MR_Cylinder3d *_this)
MRC_API MR_Vector3d * MR_Cylinder3d_center(MR_Cylinder3d *_this)
MRC_API MR_Cylinder3d * MR_Cylinder3d_Construct_4(const MR_Vector3d *inCenter, const MR_Vector3d *inDirectoin, double inRadius, double inLength)
MRC_API MR_Vector3f * MR_Cylinder3f_center(MR_Cylinder3f *_this)
MRC_API MR_Cylinder3f * MR_Cylinder3f_AssignFromAnother(MR_Cylinder3f *_this, const MR_Cylinder3f *_other)
MRC_API MR_Cylinder3d * MR_Cylinder3d_DefaultConstructArray(size_t num_elems)
MRC_API const double * MR_Cylinder3d_Get_radius(const MR_Cylinder3d *_this)
MRC_API MR_Line3f * MR_Cylinder3f_GetMutable_mainAxis(MR_Cylinder3f *_this)
MRC_API void MR_Cylinder3d_Destroy(const MR_Cylinder3d *_this)
Destroys a heap-allocated instance of MR_Cylinder3d. Does nothing if the pointer is null.
MRC_API const double * MR_Cylinder3d_Get_length(const MR_Cylinder3d *_this)
MRC_API MR_Cylinder3d * MR_Cylinder3d_OffsetMutablePtr(MR_Cylinder3d *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 double * MR_Cylinder3d_GetMutable_radius(MR_Cylinder3d *_this)
MRC_API MR_Cylinder3f * MR_Cylinder3f_OffsetMutablePtr(MR_Cylinder3f *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 MR_Line3d * MR_Cylinder3d_GetMutable_mainAxis(MR_Cylinder3d *_this)
MRC_API float * MR_Cylinder3f_GetMutable_length(MR_Cylinder3f *_this)
MRC_API const float * MR_Cylinder3f_Get_radius(const MR_Cylinder3f *_this)
MRC_API const MR_Vector3d * MR_Cylinder3d_center_const(const MR_Cylinder3d *_this)
MRC_API float * MR_Cylinder3f_GetMutable_radius(MR_Cylinder3f *_this)
MRC_API void MR_Cylinder3f_Set_length(MR_Cylinder3f *_this, float value)
MRC_API MR_Cylinder3f * MR_Cylinder3f_Construct_4(const MR_Vector3f *inCenter, const MR_Vector3f *inDirectoin, float inRadius, float inLength)
MRC_API void MR_Cylinder3f_Set_mainAxis(MR_Cylinder3f *_this, const MR_Line3f *value)
MRC_API MR_Vector3f * MR_Cylinder3f_direction(MR_Cylinder3f *_this)
MRC_API MR_Cylinder3d * MR_Cylinder3d_AssignFromAnother(MR_Cylinder3d *_this, const MR_Cylinder3d *_other)
MRC_API MR_Cylinder3f * MR_Cylinder3f_DefaultConstructArray(size_t num_elems)
MRC_API const MR_Line3f * MR_Cylinder3f_Get_mainAxis(const MR_Cylinder3f *_this)
MRC_API MR_Cylinder3f * MR_Cylinder3f_DefaultConstruct(void)
MRC_API MR_Cylinder3f * MR_Cylinder3f_Construct_3(const MR_Line3f *inAxis, float inRadius, float inLength)
struct MR_Cylinder3d MR_Cylinder3d
Definition MRCylinder3.h:27
MRC_API void MR_Cylinder3d_Set_length(MR_Cylinder3d *_this, double value)
MRC_API void MR_Cylinder3d_DestroyArray(const MR_Cylinder3d *_this)
Destroys a heap-allocated array of MR_Cylinder3d. Does nothing if the pointer is null.
MRC_API MR_Cylinder3d * MR_Cylinder3d_Construct_3(const MR_Line3d *inAxis, double inRadius, double inLength)
MRC_API void MR_Cylinder3f_Set_radius(MR_Cylinder3f *_this, float value)
MRC_API const float * MR_Cylinder3f_Get_length(const MR_Cylinder3f *_this)
MRC_API MR_Cylinder3d * MR_Cylinder3d_DefaultConstruct(void)
MRC_API const MR_Cylinder3f * MR_Cylinder3f_OffsetPtr(const MR_Cylinder3f *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 double * MR_Cylinder3d_GetMutable_length(MR_Cylinder3d *_this)
MRC_API MR_Vector3d * MR_Cylinder3d_direction(MR_Cylinder3d *_this)
MRC_API const MR_Vector3d * MR_Cylinder3d_direction_const(const MR_Cylinder3d *_this)
MRC_API const MR_Vector3f * MR_Cylinder3f_center_const(const MR_Cylinder3f *_this)
MRC_API void MR_Cylinder3d_Set_mainAxis(MR_Cylinder3d *_this, const MR_Line3d *value)
MRC_API MR_Cylinder3d * MR_Cylinder3d_ConstructFromAnother(const MR_Cylinder3d *_other)
MRC_API void MR_Cylinder3f_DestroyArray(const MR_Cylinder3f *_this)
Destroys a heap-allocated array of MR_Cylinder3f. Does nothing if the pointer is null.
MRC_API MR_Cylinder3f * MR_Cylinder3f_ConstructFromAnother(const MR_Cylinder3f *_other)
MRC_API void MR_Cylinder3d_Set_radius(MR_Cylinder3d *_this, double value)
#define MRC_API
Definition exports.h:11
Definition MRVector3.h:61
Definition MRVector3.h:52