vrshoot

view libs/assimp/assimp/importerdesc.h @ 0:b2f14e535253

initial commit
author John Tsiombikas <nuclear@member.fsf.org>
date Sat, 01 Feb 2014 19:58:19 +0200
parents
children
line source
1 /*
2 ---------------------------------------------------------------------------
3 Open Asset Import Library (assimp)
4 ---------------------------------------------------------------------------
6 Copyright (c) 2006-2012, assimp team
8 All rights reserved.
10 Redistribution and use of this software in source and binary forms,
11 with or without modification, are permitted provided that the following
12 conditions are met:
14 * Redistributions of source code must retain the above
15 copyright notice, this list of conditions and the
16 following disclaimer.
18 * Redistributions in binary form must reproduce the above
19 copyright notice, this list of conditions and the
20 following disclaimer in the documentation and/or other
21 materials provided with the distribution.
23 * Neither the name of the assimp team, nor the names of its
24 contributors may be used to endorse or promote products
25 derived from this software without specific prior
26 written permission of the assimp team.
28 THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
29 "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
30 LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
31 A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
32 OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
33 SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
34 LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
35 DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
36 THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
37 (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
38 OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
39 ---------------------------------------------------------------------------
40 */
42 /** @file importerdesc.h
43 * @brief #aiImporterFlags, aiImporterDesc implementation.
44 */
45 #ifndef INCLUDED_AI_IMPORTER_DESC_H
46 #define INCLUDED_AI_IMPORTER_DESC_H
49 /** Mixed set of flags for #aiImporterDesc, indicating some features
50 * common to many importers*/
51 enum aiImporterFlags
52 {
53 /** Indicates that there is a textual encoding of the
54 * file format; and that it is supported.*/
55 aiImporterFlags_SupportTextFlavour = 0x1,
57 /** Indicates that there is a binary encoding of the
58 * file format; and that it is supported.*/
59 aiImporterFlags_SupportBinaryFlavour = 0x2,
61 /** Indicates that there is a compressed encoding of the
62 * file format; and that it is supported.*/
63 aiImporterFlags_SupportCompressedFlavour = 0x4,
65 /** Indicates that the importer reads only a very particular
66 * subset of the file format. This happens commonly for
67 * declarative or procedural formats which cannot easily
68 * be mapped to #aiScene */
69 aiImporterFlags_LimitedSupport = 0x8,
71 /** Indicates that the importer is highly experimental and
72 * should be used with care. This only happens for trunk
73 * (i.e. SVN) versions, experimental code is not included
74 * in releases. */
75 aiImporterFlags_Experimental = 0x10,
76 };
79 /** Meta information about a particular importer. Importers need to fill
80 * this structure, but they can freely decide how talkative they are.
81 * A common use case for loader meta info is a user interface
82 * in which the user can choose between various import/export file
83 * formats. Building such an UI by hand means a lot of maintenance
84 * as importers/exporters are added to Assimp, so it might be useful
85 * to have a common mechanism to query some rough importer
86 * characteristics. */
87 struct aiImporterDesc
88 {
89 /** Full name of the importer (i.e. Blender3D importer)*/
90 const char* mName;
92 /** Original author (left blank if unknown or whole assimp team) */
93 const char* mAuthor;
95 /** Current maintainer, left blank if the author maintains */
96 const char* mMaintainer;
98 /** Implementation comments, i.e. unimplemented features*/
99 const char* mComments;
101 /** Any combination of the #aiLoaderFlags enumerated values.
102 These flags indicate some characteristics common to many
103 importers. */
104 unsigned int mFlags;
106 /** Minimum format version that can be loaded im major.minor format,
107 both are set to 0 if there is either no version scheme
108 or if the loader doesn't care. */
109 unsigned int mMinMajor;
110 unsigned int mMinMinor;
112 /** Maximum format version that can be loaded im major.minor format,
113 both are set to 0 if there is either no version scheme
114 or if the loader doesn't care. Loaders that expect to be
115 forward-compatible to potential future format versions should
116 indicate zero, otherwise they should specify the current
117 maximum version.*/
118 unsigned int mMaxMajor;
119 unsigned int mMaxMinor;
121 /** List of file extensions this importer can handle.
122 List entries are separated by space characters.
123 All entries are lower case without a leading dot (i.e.
124 "xml dae" would be a valid value. Note that multiple
125 importers may respond to the same file extension -
126 assimp calls all importers in the order in which they
127 are registered and each importer gets the opportunity
128 to load the file until one importer "claims" the file. Apart
129 from file extension checks, importers typically use
130 other methods to quickly reject files (i.e. magic
131 words) so this does not mean that common or generic
132 file extensions such as XML would be tediously slow. */
133 const char* mFileExtensions;
134 };
136 #endif