diff options
Diffstat (limited to 'src/others/mimesh/libg3d-0.0.8/plugins/import/imp_vrml2/imp_vrml_types.h')
-rw-r--r-- | src/others/mimesh/libg3d-0.0.8/plugins/import/imp_vrml2/imp_vrml_types.h | 88 |
1 files changed, 88 insertions, 0 deletions
diff --git a/src/others/mimesh/libg3d-0.0.8/plugins/import/imp_vrml2/imp_vrml_types.h b/src/others/mimesh/libg3d-0.0.8/plugins/import/imp_vrml2/imp_vrml_types.h new file mode 100644 index 0000000..6ca2327 --- /dev/null +++ b/src/others/mimesh/libg3d-0.0.8/plugins/import/imp_vrml2/imp_vrml_types.h | |||
@@ -0,0 +1,88 @@ | |||
1 | /* $Id:$ */ | ||
2 | |||
3 | /* | ||
4 | libg3d - 3D object loading library | ||
5 | |||
6 | Copyright (C) 2005-2009 Markus Dahms <mad@automagically.de> | ||
7 | |||
8 | This library is free software; you can redistribute it and/or | ||
9 | modify it under the terms of the GNU Lesser General Public | ||
10 | License as published by the Free Software Foundation; either | ||
11 | version 2.1 of the License, or (at your option) any later version. | ||
12 | |||
13 | This library is distributed in the hope that it will be useful, | ||
14 | but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
15 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU | ||
16 | Lesser General Public License for more details. | ||
17 | |||
18 | You should have received a copy of the GNU Lesser General Public | ||
19 | License along with this library; if not, write to the Free Software | ||
20 | Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA | ||
21 | */ | ||
22 | #ifndef _IMP_VRML_TYPES_H | ||
23 | #define _IMP_VRML_TYPES_H | ||
24 | |||
25 | #include "imp_vrml2.h" | ||
26 | |||
27 | typedef enum { | ||
28 | T_UNKNOWN = 0, | ||
29 | T_SPECIAL, | ||
30 | T_OBJECT, | ||
31 | T_TOKEN2, | ||
32 | T_TOKEN3, | ||
33 | T_STRING, | ||
34 | T_BOOLEAN, | ||
35 | T_INT, | ||
36 | T_FLOAT, | ||
37 | T_FLOAT2, | ||
38 | T_FLOAT3, | ||
39 | T_FLOAT4, | ||
40 | T_FLOAT_X, | ||
41 | T_LIST_OBJECT, | ||
42 | T_LIST_STRING, | ||
43 | T_LIST_INT, | ||
44 | T_LIST_FLOAT, | ||
45 | T_LIST_FLOAT2, | ||
46 | T_LIST_FLOAT3, | ||
47 | T_LIST_FLOAT4, | ||
48 | T_LIST_FLOAT_X, | ||
49 | N_TYPES | ||
50 | } VrmlType; | ||
51 | |||
52 | typedef struct { | ||
53 | gchar *name; | ||
54 | gchar *defid; | ||
55 | gboolean define; | ||
56 | guint32 level; | ||
57 | GSList *properties; | ||
58 | } VrmlObject; | ||
59 | |||
60 | typedef struct { | ||
61 | gchar *name; | ||
62 | VrmlType id; | ||
63 | |||
64 | gsize n_items; | ||
65 | VrmlObject **v_object; | ||
66 | gchar **v_str; | ||
67 | G3DFloat *v_float; | ||
68 | gint32 *v_int; | ||
69 | gboolean v_boolean; | ||
70 | guint32 level; | ||
71 | } VrmlProperty; | ||
72 | |||
73 | typedef VrmlType (* VrmlTypeDetect)(VrmlReader *reader); | ||
74 | |||
75 | typedef struct { | ||
76 | const gchar *name; | ||
77 | VrmlType id; | ||
78 | VrmlTypeDetect detect; | ||
79 | } VrmlTypeDef; | ||
80 | |||
81 | typedef gboolean (* VrmlNodeCallback)(VrmlReader *reader, VrmlObject *object); | ||
82 | |||
83 | typedef struct { | ||
84 | const gchar *name; | ||
85 | VrmlNodeCallback callback; | ||
86 | } VrmlNodeDef; | ||
87 | |||
88 | #endif /* _IMP_VRML_TYPES_H */ | ||