MeshLib C Docs
Loading...
Searching...
No Matches
MRIOParsing.h
Go to the documentation of this file.
1#pragma once
2
3#include <MRCMisc/common.h>
4#include <MRCMisc/exports.h>
5
6#include <stdint.h>
7
8#ifdef __cplusplus
9extern "C" {
10#endif
11
12typedef struct MR_VertId MR_VertId; // Defined in `#include <MRCMesh/MRId.h>`.
13typedef struct MR_expected_void_std_string MR_expected_void_std_string; // Defined in `#include <MRCMisc/expected_void_std_string.h>`.
14typedef struct MR_std_vector_uint64_t MR_std_vector_uint64_t; // Defined in `#include <MRCMisc/std_vector_uint64_t.h>`.
15
16
17// returns offsets for each new line in monolith char block
21
22// reads the first integer number in the line
28MRC_API MR_expected_void_std_string *MR_parseFirstNum(const char *str, const char *str_end, int32_t *num);
29
30// reads the polygon points and optional number of polygon points
31// example
32// N vertex0 vertex1 ... vertexN
37MRC_API MR_expected_void_std_string *MR_parsePolygon(const char *str, const char *str_end, MR_VertId *vertId, int32_t *numPoints);
38
39#ifdef __cplusplus
40} // extern "C"
41#endif
struct MR_expected_void_std_string MR_expected_void_std_string
Definition MRCtm.h:20
struct MR_std_vector_uint64_t MR_std_vector_uint64_t
Definition MRHeapBytes.h:18
MRC_API MR_std_vector_uint64_t * MR_splitByLines(const char *data, MR_uint64_t size)
MRC_API MR_expected_void_std_string * MR_parseFirstNum(const char *str, const char *str_end, int32_t *num)
MRC_API MR_expected_void_std_string * MR_parsePolygon(const char *str, const char *str_end, MR_VertId *vertId, int32_t *numPoints)
uint64_t MR_uint64_t
Definition common.h:14
#define MRC_API
Definition exports.h:11
size_t size() const
Definition MRId.h:56