sencX2d.h (1774B)
1 /* Copyright (C) 2018-2021, 2023, 2024 |Méso|Star> (contact@meso-star.com) 2 * 3 * This program 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 * This program 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 <http://www.gnu.org/licenses/>. */ 15 16 #ifndef SENC_X_2D_H 17 #define SENC_X_2D_H 18 19 #if !defined(SENCXD_DIM) || (SENCXD_DIM != 2 && SENCXD_DIM != 3) 20 #error "SENCXD_DIM must be defined; admissible values are 2 and 3" 21 #endif 22 23 #include <star/senc2d.h> 24 25 /* Star-enclosures-XD macros generic to the SENCXD_DIM */ 26 #ifndef SENCXD 27 #define SENCXD CONCAT(CONCAT(SENC, SENCXD_DIM), D) 28 #endif 29 #ifndef sencXd 30 #define sencXd(Name) CONCAT(CONCAT(CONCAT(senc, SENCXD_DIM), d_), Name) 31 #endif 32 #ifndef SENCXD_ 33 #define SENCXD_(Name) CONCAT(CONCAT(CONCAT(SENC, SENCXD_DIM), D_), Name) 34 #endif 35 36 /* Function names that require additional dedicated macros */ 37 #define senc2d_scene_get_primitives_count senc2d_scene_get_segments_count 38 #define senc2d_scene_get_primitive senc2d_scene_get_segment 39 #define senc2d_scene_get_primitive_media senc2d_scene_get_segment_media 40 #define senc2d_scene_get_primitive_enclosures senc2d_scene_get_segment_enclosures 41 #define senc2d_enclosure_get_primitive senc2d_enclosure_get_segment 42 #define senc2d_enclosure_get_primitive_id senc2d_enclosure_get_segment_id 43 44 #endif /* SENC_X_2D_H */