LibT2FS 0.1
C API for accessing TEngine data in memory.
Loading...
Searching...
No Matches
models/common.h
Go to the documentation of this file.
1/* This file is part of LibT2FS.
2 *
3 * LibT2FS is free software: you can redistribute it and/or modify
4 * it under the terms of the GNU General Public License as published by
5 * the Free Software Foundation, either version 3 of the License, or
6 * (at your option) any later version.
7 *
8 * LibT2FS is distributed in the hope that it will be useful,
9 * but WITHOUT ANY WARRANTY; without even the implied warranty of
10 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
11 * GNU General Public License for more details.
12 *
13 * You should have received a copy of the GNU General Public License
14 * along with this program. If not, see <https://www.gnu.org/licenses/>.
15 */
16
17#ifndef H_T2FS_DATA_COMMON
18#define H_T2FS_DATA_COMMON
19
20#ifdef T2FS_DEBUG
21#define SASSERT_SIZE(what, size) \
22 _Static_assert((sizeof(what) == size), "" #what " expected to be " #size " in size");
23#else
24#define SASSERT_SIZE(what, size)
25#endif
26
27
30typedef struct __attribute__((__packed__)) s_t2fsDataCoordF32 {
31 float x, y, z;
33
36typedef struct __attribute__((__packed__)) s_t2fsDataWorldCoordF32 {
37 float x, z, y;
39
43typedef struct __attribute__((__packed__)) s_t2fsDataCoordS32 {
44 int32_t x, y, z;
46
47
53typedef struct __attribute__((__packed__)) s_t2fsDataCoordS16 {
54 int16_t x, y, z;
56
57
63typedef struct __attribute__((__packed__)) s_t2fsDataWorldCoordS16 {
64 int16_t x, z, y;
66
67#endif
struct s_t2fsDataWorldCoordF32 t2fsDataWorldCoordF32
struct s_t2fsDataCoordF32 t2fsDataCoordF32
struct s_t2fsDataWorldCoordS16 t2fsDataWorldCoordS16
struct s_t2fsDataCoordS16 t2fsDataCoordS16
struct s_t2fsDataCoordS32 t2fsDataCoordS32
yeah.. not kiddin
Definition models/common.h:30
float z
Definition models/common.h:31
float y
Definition models/common.h:31
float x
Definition models/common.h:31
Definition models/common.h:53
int16_t y
Definition models/common.h:54
int16_t z
Definition models/common.h:54
int16_t x
Definition models/common.h:54
yeah.. not kiddin
Definition models/common.h:43
int32_t x
Definition models/common.h:44
int32_t z
Definition models/common.h:44
int32_t y
Definition models/common.h:44
Definition models/common.h:36
float z
Definition models/common.h:37
float x
Definition models/common.h:37
float y
Definition models/common.h:37
Definition models/common.h:63
int16_t z
Definition models/common.h:64
int16_t x
Definition models/common.h:64
int16_t y
Definition models/common.h:64