Nevar pievienot vairāk kā 25 tēmas Tēmai ir jāsākas ar burtu vai ciparu, tā var saturēt domu zīmes ('-') un var būt līdz 35 simboliem gara.
 
 
 
 
 
 

874 rindas
35 KiB

  1. /*
  2. ---------------------------------------------------------------------------
  3. Open Asset Import Library (assimp)
  4. ---------------------------------------------------------------------------
  5. Copyright (c) 2006-2012, assimp team
  6. All rights reserved.
  7. Redistribution and use of this software in source and binary forms,
  8. with or without modification, are permitted provided that the following
  9. conditions are met:
  10. * Redistributions of source code must retain the above
  11. copyright notice, this list of conditions and the
  12. following disclaimer.
  13. * Redistributions in binary form must reproduce the above
  14. copyright notice, this list of conditions and the
  15. following disclaimer in the documentation and/or other
  16. materials provided with the distribution.
  17. * Neither the name of the assimp team, nor the names of its
  18. contributors may be used to endorse or promote products
  19. derived from this software without specific prior
  20. written permission of the assimp team.
  21. THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
  22. "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
  23. LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
  24. A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
  25. OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  26. SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  27. LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
  28. DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
  29. THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
  30. (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
  31. OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  32. ---------------------------------------------------------------------------
  33. */
  34. /** @file config.h
  35. * @brief Defines constants for configurable properties for the library
  36. *
  37. * Typically these properties are set via
  38. * #Assimp::Importer::SetPropertyFloat,
  39. * #Assimp::Importer::SetPropertyInteger or
  40. * #Assimp::Importer::SetPropertyString,
  41. * depending on the data type of a property. All properties have a
  42. * default value. See the doc for the mentioned methods for more details.
  43. *
  44. * <br><br>
  45. * The corresponding functions for use with the plain-c API are:
  46. * #aiSetImportPropertyInteger,
  47. * #aiSetImportPropertyFloat,
  48. * #aiSetImportPropertyString
  49. */
  50. #ifndef INCLUDED_AI_CONFIG_H
  51. #define INCLUDED_AI_CONFIG_H
  52. // ###########################################################################
  53. // LIBRARY SETTINGS
  54. // General, global settings
  55. // ###########################################################################
  56. // ---------------------------------------------------------------------------
  57. /** @brief Enables time measurements.
  58. *
  59. * If enabled, measures the time needed for each part of the loading
  60. * process (i.e. IO time, importing, postprocessing, ..) and dumps
  61. * these timings to the DefaultLogger. See the @link perf Performance
  62. * Page@endlink for more information on this topic.
  63. *
  64. * Property type: bool. Default value: false.
  65. */
  66. #define AI_CONFIG_GLOB_MEASURE_TIME \
  67. "GLOB_MEASURE_TIME"
  68. // ---------------------------------------------------------------------------
  69. /** @brief Global setting to disable generation of skeleton dummy meshes
  70. *
  71. * Skeleton dummy meshes are generated as a visualization aid in cases which
  72. * the input data contains no geometry, but only animation data.
  73. * Property data type: bool. Default value: false
  74. */
  75. // ---------------------------------------------------------------------------
  76. #define AI_CONFIG_IMPORT_NO_SKELETON_MESHES \
  77. "IMPORT_NO_SKELETON_MESHES"
  78. # if 0 // not implemented yet
  79. // ---------------------------------------------------------------------------
  80. /** @brief Set Assimp's multithreading policy.
  81. *
  82. * This setting is ignored if Assimp was built without boost.thread
  83. * support (ASSIMP_BUILD_NO_THREADING, which is implied by ASSIMP_BUILD_BOOST_WORKAROUND).
  84. * Possible values are: -1 to let Assimp decide what to do, 0 to disable
  85. * multithreading entirely and any number larger than 0 to force a specific
  86. * number of threads. Assimp is always free to ignore this settings, which is
  87. * merely a hint. Usually, the default value (-1) will be fine. However, if
  88. * Assimp is used concurrently from multiple user threads, it might be useful
  89. * to limit each Importer instance to a specific number of cores.
  90. *
  91. * For more information, see the @link threading Threading page@endlink.
  92. * Property type: int, default value: -1.
  93. */
  94. #define AI_CONFIG_GLOB_MULTITHREADING \
  95. "GLOB_MULTITHREADING"
  96. #endif
  97. // ###########################################################################
  98. // POST PROCESSING SETTINGS
  99. // Various stuff to fine-tune the behavior of a specific post processing step.
  100. // ###########################################################################
  101. // ---------------------------------------------------------------------------
  102. /** @brief Maximum bone count per mesh for the SplitbyBoneCount step.
  103. *
  104. * Meshes are split until the maximum number of bones is reached. The default
  105. * value is AI_SBBC_DEFAULT_MAX_BONES, which may be altered at
  106. * compile-time.
  107. * Property data type: integer.
  108. */
  109. // ---------------------------------------------------------------------------
  110. #define AI_CONFIG_PP_SBBC_MAX_BONES \
  111. "PP_SBBC_MAX_BONES"
  112. // default limit for bone count
  113. #if (!defined AI_SBBC_DEFAULT_MAX_BONES)
  114. # define AI_SBBC_DEFAULT_MAX_BONES 60
  115. #endif
  116. // ---------------------------------------------------------------------------
  117. /** @brief Specifies the maximum angle that may be between two vertex tangents
  118. * that their tangents and bi-tangents are smoothed.
  119. *
  120. * This applies to the CalcTangentSpace-Step. The angle is specified
  121. * in degrees. The maximum value is 175.
  122. * Property type: float. Default value: 45 degrees
  123. */
  124. #define AI_CONFIG_PP_CT_MAX_SMOOTHING_ANGLE \
  125. "PP_CT_MAX_SMOOTHING_ANGLE"
  126. // ---------------------------------------------------------------------------
  127. /** @brief Source UV channel for tangent space computation.
  128. *
  129. * The specified channel must exist or an error will be raised.
  130. * Property type: integer. Default value: 0
  131. */
  132. // ---------------------------------------------------------------------------
  133. #define AI_CONFIG_PP_CT_TEXTURE_CHANNEL_INDEX \
  134. "PP_CT_TEXTURE_CHANNEL_INDEX"
  135. // ---------------------------------------------------------------------------
  136. /** @brief Specifies the maximum angle that may be between two face normals
  137. * at the same vertex position that their are smoothed together.
  138. *
  139. * Sometimes referred to as 'crease angle'.
  140. * This applies to the GenSmoothNormals-Step. The angle is specified
  141. * in degrees, so 180 is PI. The default value is 175 degrees (all vertex
  142. * normals are smoothed). The maximum value is 175, too. Property type: float.
  143. * Warning: setting this option may cause a severe loss of performance. The
  144. * performance is unaffected if the #AI_CONFIG_FAVOUR_SPEED flag is set but
  145. * the output quality may be reduced.
  146. */
  147. #define AI_CONFIG_PP_GSN_MAX_SMOOTHING_ANGLE \
  148. "PP_GSN_MAX_SMOOTHING_ANGLE"
  149. // ---------------------------------------------------------------------------
  150. /** @brief Sets the colormap (= palette) to be used to decode embedded
  151. * textures in MDL (Quake or 3DGS) files.
  152. *
  153. * This must be a valid path to a file. The file is 768 (256*3) bytes
  154. * large and contains RGB triplets for each of the 256 palette entries.
  155. * The default value is colormap.lmp. If the file is not found,
  156. * a default palette (from Quake 1) is used.
  157. * Property type: string.
  158. */
  159. #define AI_CONFIG_IMPORT_MDL_COLORMAP \
  160. "IMPORT_MDL_COLORMAP"
  161. // ---------------------------------------------------------------------------
  162. /** @brief Configures the #aiProcess_RemoveRedundantMaterials step to
  163. * keep materials matching a name in a given list.
  164. *
  165. * This is a list of 1 to n strings, ' ' serves as delimiter character.
  166. * Identifiers containing whitespaces must be enclosed in *single*
  167. * quotation marks. For example:<tt>
  168. * "keep-me and_me_to anotherMaterialToBeKept \'name with whitespace\'"</tt>.
  169. * If a material matches on of these names, it will not be modified or
  170. * removed by the postprocessing step nor will other materials be replaced
  171. * by a reference to it. <br>
  172. * This option might be useful if you are using some magic material names
  173. * to pass additional semantics through the content pipeline. This ensures
  174. * they won't be optimized away, but a general optimization is still
  175. * performed for materials not contained in the list.
  176. * Property type: String. Default value: n/a
  177. * @note Linefeeds, tabs or carriage returns are treated as whitespace.
  178. * Material names are case sensitive.
  179. */
  180. #define AI_CONFIG_PP_RRM_EXCLUDE_LIST \
  181. "PP_RRM_EXCLUDE_LIST"
  182. // ---------------------------------------------------------------------------
  183. /** @brief Configures the #aiProcess_PretransformVertices step to
  184. * keep the scene hierarchy. Meshes are moved to worldspace, but
  185. * no optimization is performed (read: meshes with equal materials are not
  186. * joined. The total number of meshes won't change).
  187. *
  188. * This option could be of use for you if the scene hierarchy contains
  189. * important additional information which you intend to parse.
  190. * For rendering, you can still render all meshes in the scene without
  191. * any transformations.
  192. * Property type: bool. Default value: false.
  193. */
  194. #define AI_CONFIG_PP_PTV_KEEP_HIERARCHY \
  195. "PP_PTV_KEEP_HIERARCHY"
  196. // ---------------------------------------------------------------------------
  197. /** @brief Configures the #aiProcess_PretransformVertices step to normalize
  198. * all vertex components into the [-1,1] range. That is, a bounding box
  199. * for the whole scene is computed, the maximum component is taken and all
  200. * meshes are scaled appropriately (uniformly of course!).
  201. * This might be useful if you don't know the spatial dimension of the input
  202. * data*/
  203. #define AI_CONFIG_PP_PTV_NORMALIZE \
  204. "PP_PTV_NORMALIZE"
  205. // ---------------------------------------------------------------------------
  206. /** @brief Configures the #aiProcess_PretransformVertices step to use
  207. * a users defined matrix as the scene root node transformation before
  208. * transforming vertices.
  209. * Property type: bool. Default value: false.
  210. */
  211. #define AI_CONFIG_PP_PTV_ADD_ROOT_TRANSFORMATION \
  212. "PP_PTV_ADD_ROOT_TRANSFORMATION"
  213. // ---------------------------------------------------------------------------
  214. /** @brief Configures the #aiProcess_PretransformVertices step to use
  215. * a users defined matrix as the scene root node transformation before
  216. * transforming vertices. This property correspond to the 'a1' component
  217. * of the transformation matrix.
  218. * Property type: aiMatrix4x4.
  219. */
  220. #define AI_CONFIG_PP_PTV_ROOT_TRANSFORMATION \
  221. "PP_PTV_ROOT_TRANSFORMATION"
  222. // ---------------------------------------------------------------------------
  223. /** @brief Configures the #aiProcess_FindDegenerates step to
  224. * remove degenerated primitives from the import - immediately.
  225. *
  226. * The default behaviour converts degenerated triangles to lines and
  227. * degenerated lines to points. See the documentation to the
  228. * #aiProcess_FindDegenerates step for a detailed example of the various ways
  229. * to get rid of these lines and points if you don't want them.
  230. * Property type: bool. Default value: false.
  231. */
  232. #define AI_CONFIG_PP_FD_REMOVE \
  233. "PP_FD_REMOVE"
  234. // ---------------------------------------------------------------------------
  235. /** @brief Configures the #aiProcess_OptimizeGraph step to preserve nodes
  236. * matching a name in a given list.
  237. *
  238. * This is a list of 1 to n strings, ' ' serves as delimiter character.
  239. * Identifiers containing whitespaces must be enclosed in *single*
  240. * quotation marks. For example:<tt>
  241. * "keep-me and_me_to anotherNodeToBeKept \'name with whitespace\'"</tt>.
  242. * If a node matches on of these names, it will not be modified or
  243. * removed by the postprocessing step.<br>
  244. * This option might be useful if you are using some magic node names
  245. * to pass additional semantics through the content pipeline. This ensures
  246. * they won't be optimized away, but a general optimization is still
  247. * performed for nodes not contained in the list.
  248. * Property type: String. Default value: n/a
  249. * @note Linefeeds, tabs or carriage returns are treated as whitespace.
  250. * Node names are case sensitive.
  251. */
  252. #define AI_CONFIG_PP_OG_EXCLUDE_LIST \
  253. "PP_OG_EXCLUDE_LIST"
  254. // ---------------------------------------------------------------------------
  255. /** @brief Set the maximum number of triangles in a mesh.
  256. *
  257. * This is used by the "SplitLargeMeshes" PostProcess-Step to determine
  258. * whether a mesh must be split or not.
  259. * @note The default value is AI_SLM_DEFAULT_MAX_TRIANGLES
  260. * Property type: integer.
  261. */
  262. #define AI_CONFIG_PP_SLM_TRIANGLE_LIMIT \
  263. "PP_SLM_TRIANGLE_LIMIT"
  264. // default value for AI_CONFIG_PP_SLM_TRIANGLE_LIMIT
  265. #if (!defined AI_SLM_DEFAULT_MAX_TRIANGLES)
  266. # define AI_SLM_DEFAULT_MAX_TRIANGLES 1000000
  267. #endif
  268. // ---------------------------------------------------------------------------
  269. /** @brief Set the maximum number of vertices in a mesh.
  270. *
  271. * This is used by the "SplitLargeMeshes" PostProcess-Step to determine
  272. * whether a mesh must be split or not.
  273. * @note The default value is AI_SLM_DEFAULT_MAX_VERTICES
  274. * Property type: integer.
  275. */
  276. #define AI_CONFIG_PP_SLM_VERTEX_LIMIT \
  277. "PP_SLM_VERTEX_LIMIT"
  278. // default value for AI_CONFIG_PP_SLM_VERTEX_LIMIT
  279. #if (!defined AI_SLM_DEFAULT_MAX_VERTICES)
  280. # define AI_SLM_DEFAULT_MAX_VERTICES 1000000
  281. #endif
  282. // ---------------------------------------------------------------------------
  283. /** @brief Set the maximum number of bones affecting a single vertex
  284. *
  285. * This is used by the #aiProcess_LimitBoneWeights PostProcess-Step.
  286. * @note The default value is AI_LBW_MAX_WEIGHTS
  287. * Property type: integer.*/
  288. #define AI_CONFIG_PP_LBW_MAX_WEIGHTS \
  289. "PP_LBW_MAX_WEIGHTS"
  290. // default value for AI_CONFIG_PP_LBW_MAX_WEIGHTS
  291. #if (!defined AI_LMW_MAX_WEIGHTS)
  292. # define AI_LMW_MAX_WEIGHTS 0x4
  293. #endif // !! AI_LMW_MAX_WEIGHTS
  294. // ---------------------------------------------------------------------------
  295. /** @brief Lower the deboning threshold in order to remove more bones.
  296. *
  297. * This is used by the #aiProcess_Debone PostProcess-Step.
  298. * @note The default value is AI_DEBONE_THRESHOLD
  299. * Property type: float.*/
  300. #define AI_CONFIG_PP_DB_THRESHOLD \
  301. "PP_DB_THRESHOLD"
  302. // default value for AI_CONFIG_PP_LBW_MAX_WEIGHTS
  303. #if (!defined AI_DEBONE_THRESHOLD)
  304. # define AI_DEBONE_THRESHOLD 1.0f
  305. #endif // !! AI_DEBONE_THRESHOLD
  306. // ---------------------------------------------------------------------------
  307. /** @brief Require all bones qualify for deboning before removing any
  308. *
  309. * This is used by the #aiProcess_Debone PostProcess-Step.
  310. * @note The default value is 0
  311. * Property type: bool.*/
  312. #define AI_CONFIG_PP_DB_ALL_OR_NONE \
  313. "PP_DB_ALL_OR_NONE"
  314. /** @brief Default value for the #AI_CONFIG_PP_ICL_PTCACHE_SIZE property
  315. */
  316. #ifndef PP_ICL_PTCACHE_SIZE
  317. # define PP_ICL_PTCACHE_SIZE 12
  318. #endif
  319. // ---------------------------------------------------------------------------
  320. /** @brief Set the size of the post-transform vertex cache to optimize the
  321. * vertices for. This configures the #aiProcess_ImproveCacheLocality step.
  322. *
  323. * The size is given in vertices. Of course you can't know how the vertex
  324. * format will exactly look like after the import returns, but you can still
  325. * guess what your meshes will probably have.
  326. * @note The default value is #PP_ICL_PTCACHE_SIZE. That results in slight
  327. * performance improvements for most nVidia/AMD cards since 2002.
  328. * Property type: integer.
  329. */
  330. #define AI_CONFIG_PP_ICL_PTCACHE_SIZE "PP_ICL_PTCACHE_SIZE"
  331. // ---------------------------------------------------------------------------
  332. /** @brief Enumerates components of the aiScene and aiMesh data structures
  333. * that can be excluded from the import using the #aiPrpcess_RemoveComponent step.
  334. *
  335. * See the documentation to #aiProcess_RemoveComponent for more details.
  336. */
  337. enum aiComponent
  338. {
  339. /** Normal vectors */
  340. #ifdef SWIG
  341. aiComponent_NORMALS = 0x2,
  342. #else
  343. aiComponent_NORMALS = 0x2u,
  344. #endif
  345. /** Tangents and bitangents go always together ... */
  346. #ifdef SWIG
  347. aiComponent_TANGENTS_AND_BITANGENTS = 0x4,
  348. #else
  349. aiComponent_TANGENTS_AND_BITANGENTS = 0x4u,
  350. #endif
  351. /** ALL color sets
  352. * Use aiComponent_COLORn(N) to specify the N'th set */
  353. aiComponent_COLORS = 0x8,
  354. /** ALL texture UV sets
  355. * aiComponent_TEXCOORDn(N) to specify the N'th set */
  356. aiComponent_TEXCOORDS = 0x10,
  357. /** Removes all bone weights from all meshes.
  358. * The scenegraph nodes corresponding to the bones are NOT removed.
  359. * use the #aiProcess_OptimizeGraph step to do this */
  360. aiComponent_BONEWEIGHTS = 0x20,
  361. /** Removes all node animations (aiScene::mAnimations).
  362. * The corresponding scenegraph nodes are NOT removed.
  363. * use the #aiProcess_OptimizeGraph step to do this */
  364. aiComponent_ANIMATIONS = 0x40,
  365. /** Removes all embedded textures (aiScene::mTextures) */
  366. aiComponent_TEXTURES = 0x80,
  367. /** Removes all light sources (aiScene::mLights).
  368. * The corresponding scenegraph nodes are NOT removed.
  369. * use the #aiProcess_OptimizeGraph step to do this */
  370. aiComponent_LIGHTS = 0x100,
  371. /** Removes all cameras (aiScene::mCameras).
  372. * The corresponding scenegraph nodes are NOT removed.
  373. * use the #aiProcess_OptimizeGraph step to do this */
  374. aiComponent_CAMERAS = 0x200,
  375. /** Removes all meshes (aiScene::mMeshes). */
  376. aiComponent_MESHES = 0x400,
  377. /** Removes all materials. One default material will
  378. * be generated, so aiScene::mNumMaterials will be 1. */
  379. aiComponent_MATERIALS = 0x800,
  380. /** This value is not used. It is just there to force the
  381. * compiler to map this enum to a 32 Bit integer. */
  382. #ifndef SWIG
  383. _aiComponent_Force32Bit = 0x9fffffff
  384. #endif
  385. };
  386. // Remove a specific color channel 'n'
  387. #define aiComponent_COLORSn(n) (1u << (n+20u))
  388. // Remove a specific UV channel 'n'
  389. #define aiComponent_TEXCOORDSn(n) (1u << (n+25u))
  390. // ---------------------------------------------------------------------------
  391. /** @brief Input parameter to the #aiProcess_RemoveComponent step:
  392. * Specifies the parts of the data structure to be removed.
  393. *
  394. * See the documentation to this step for further details. The property
  395. * is expected to be an integer, a bitwise combination of the
  396. * #aiComponent flags defined above in this header. The default
  397. * value is 0. Important: if no valid mesh is remaining after the
  398. * step has been executed (e.g you thought it was funny to specify ALL
  399. * of the flags defined above) the import FAILS. Mainly because there is
  400. * no data to work on anymore ...
  401. */
  402. #define AI_CONFIG_PP_RVC_FLAGS \
  403. "PP_RVC_FLAGS"
  404. // ---------------------------------------------------------------------------
  405. /** @brief Input parameter to the #aiProcess_SortByPType step:
  406. * Specifies which primitive types are removed by the step.
  407. *
  408. * This is a bitwise combination of the aiPrimitiveType flags.
  409. * Specifying all of them is illegal, of course. A typical use would
  410. * be to exclude all line and point meshes from the import. This
  411. * is an integer property, its default value is 0.
  412. */
  413. #define AI_CONFIG_PP_SBP_REMOVE \
  414. "PP_SBP_REMOVE"
  415. // ---------------------------------------------------------------------------
  416. /** @brief Input parameter to the #aiProcess_FindInvalidData step:
  417. * Specifies the floating-point accuracy for animation values. The step
  418. * checks for animation tracks where all frame values are absolutely equal
  419. * and removes them. This tweakable controls the epsilon for floating-point
  420. * comparisons - two keys are considered equal if the invariant
  421. * abs(n0-n1)>epsilon holds true for all vector respectively quaternion
  422. * components. The default value is 0.f - comparisons are exact then.
  423. */
  424. #define AI_CONFIG_PP_FID_ANIM_ACCURACY \
  425. "PP_FID_ANIM_ACCURACY"
  426. // TransformUVCoords evaluates UV scalings
  427. #define AI_UVTRAFO_SCALING 0x1
  428. // TransformUVCoords evaluates UV rotations
  429. #define AI_UVTRAFO_ROTATION 0x2
  430. // TransformUVCoords evaluates UV translation
  431. #define AI_UVTRAFO_TRANSLATION 0x4
  432. // Everything baked together -> default value
  433. #define AI_UVTRAFO_ALL (AI_UVTRAFO_SCALING | AI_UVTRAFO_ROTATION | AI_UVTRAFO_TRANSLATION)
  434. // ---------------------------------------------------------------------------
  435. /** @brief Input parameter to the #aiProcess_TransformUVCoords step:
  436. * Specifies which UV transformations are evaluated.
  437. *
  438. * This is a bitwise combination of the AI_UVTRAFO_XXX flags (integer
  439. * property, of course). By default all transformations are enabled
  440. * (AI_UVTRAFO_ALL).
  441. */
  442. #define AI_CONFIG_PP_TUV_EVALUATE \
  443. "PP_TUV_EVALUATE"
  444. // ---------------------------------------------------------------------------
  445. /** @brief A hint to assimp to favour speed against import quality.
  446. *
  447. * Enabling this option may result in faster loading, but it needn't.
  448. * It represents just a hint to loaders and post-processing steps to use
  449. * faster code paths, if possible.
  450. * This property is expected to be an integer, != 0 stands for true.
  451. * The default value is 0.
  452. */
  453. #define AI_CONFIG_FAVOUR_SPEED \
  454. "FAVOUR_SPEED"
  455. // ###########################################################################
  456. // IMPORTER SETTINGS
  457. // Various stuff to fine-tune the behaviour of specific importer plugins.
  458. // ###########################################################################
  459. // ---------------------------------------------------------------------------
  460. /** @brief Set whether the fbx importer will merge all geometry layers present
  461. * in the source file or take only the first.
  462. *
  463. * The default value is true (1)
  464. * Property type: bool
  465. */
  466. #define AI_CONFIG_IMPORT_FBX_READ_ALL_GEOMETRY_LAYERS \
  467. "IMPORT_FBX_READ_ALL_GEOMETRY_LAYERS"
  468. // ---------------------------------------------------------------------------
  469. /** @brief Set whether the fbx importer will read all materials present in the
  470. * source file or take only the referenced materials.
  471. *
  472. * This is void unless IMPORT_FBX_READ_MATERIALS=1.
  473. *
  474. * The default value is false (0)
  475. * Property type: bool
  476. */
  477. #define AI_CONFIG_IMPORT_FBX_READ_ALL_MATERIALS \
  478. "IMPORT_FBX_READ_ALL_MATERIALS"
  479. // ---------------------------------------------------------------------------
  480. /** @brief Set whether the fbx importer will read materials.
  481. *
  482. * The default value is true (1)
  483. * Property type: bool
  484. */
  485. #define AI_CONFIG_IMPORT_FBX_READ_MATERIALS \
  486. "IMPORT_FBX_READ_MATERIALS"
  487. // ---------------------------------------------------------------------------
  488. /** @brief Set whether the fbx importer will read cameras.
  489. *
  490. * The default value is true (1)
  491. * Property type: bool
  492. */
  493. #define AI_CONFIG_IMPORT_FBX_READ_CAMERAS \
  494. "IMPORT_FBX_READ_CAMERAS"
  495. // ---------------------------------------------------------------------------
  496. /** @brief Set whether the fbx importer will read light sources.
  497. *
  498. * The default value is true (1)
  499. * Property type: bool
  500. */
  501. #define AI_CONFIG_IMPORT_FBX_READ_LIGHTS \
  502. "IMPORT_FBX_READ_LIGHTS"
  503. // ---------------------------------------------------------------------------
  504. /** @brief Set whether the fbx importer will read animations.
  505. *
  506. * The default value is true (1)
  507. * Property type: bool
  508. */
  509. #define AI_CONFIG_IMPORT_FBX_READ_ANIMATIONS \
  510. "IMPORT_FBX_READ_ANIMATIONS"
  511. // ---------------------------------------------------------------------------
  512. /** @brief Set whether the fbx importer will act in strict mode in which only
  513. * FBX 2013 is supported and any other sub formats are rejected. FBX 2013
  514. * is the primary target for the importer, so this format is best
  515. * supported and well-tested.
  516. *
  517. * The default value is false (0)
  518. * Property type: bool
  519. */
  520. #define AI_CONFIG_IMPORT_FBX_STRICT_MODE \
  521. "IMPORT_FBX_STRICT_MODE"
  522. // ---------------------------------------------------------------------------
  523. /** @brief Set whether the fbx importer will preserve pivot points for
  524. * transformations (as extra nodes). If set to false, pivots and offsets
  525. * will be evaluated whenever possible.
  526. *
  527. * The default value is true (1)
  528. * Property type: bool
  529. */
  530. #define AI_CONFIG_IMPORT_FBX_PRESERVE_PIVOTS \
  531. "IMPORT_FBX_PRESERVE_PIVOTS"
  532. // ---------------------------------------------------------------------------
  533. /** @brief Specifies whether the importer will drop empty animation curves or
  534. * animation curves which match the bind pose transformation over their
  535. * entire defined range.
  536. *
  537. * The default value is true (1)
  538. * Property type: bool
  539. */
  540. #define AI_CONFIG_IMPORT_FBX_OPTIMIZE_EMPTY_ANIMATION_CURVES \
  541. "IMPORT_FBX_OPTIMIZE_EMPTY_ANIMATION_CURVES"
  542. // ---------------------------------------------------------------------------
  543. /** @brief Set the vertex animation keyframe to be imported
  544. *
  545. * ASSIMP does not support vertex keyframes (only bone animation is supported).
  546. * The library reads only one frame of models with vertex animations.
  547. * By default this is the first frame.
  548. * \note The default value is 0. This option applies to all importers.
  549. * However, it is also possible to override the global setting
  550. * for a specific loader. You can use the AI_CONFIG_IMPORT_XXX_KEYFRAME
  551. * options (where XXX is a placeholder for the file format for which you
  552. * want to override the global setting).
  553. * Property type: integer.
  554. */
  555. #define AI_CONFIG_IMPORT_GLOBAL_KEYFRAME "IMPORT_GLOBAL_KEYFRAME"
  556. #define AI_CONFIG_IMPORT_MD3_KEYFRAME "IMPORT_MD3_KEYFRAME"
  557. #define AI_CONFIG_IMPORT_MD2_KEYFRAME "IMPORT_MD2_KEYFRAME"
  558. #define AI_CONFIG_IMPORT_MDL_KEYFRAME "IMPORT_MDL_KEYFRAME"
  559. #define AI_CONFIG_IMPORT_MDC_KEYFRAME "IMPORT_MDC_KEYFRAME"
  560. #define AI_CONFIG_IMPORT_SMD_KEYFRAME "IMPORT_SMD_KEYFRAME"
  561. #define AI_CONFIG_IMPORT_UNREAL_KEYFRAME "IMPORT_UNREAL_KEYFRAME"
  562. // ---------------------------------------------------------------------------
  563. /** @brief Configures the AC loader to collect all surfaces which have the
  564. * "Backface cull" flag set in separate meshes.
  565. *
  566. * Property type: bool. Default value: true.
  567. */
  568. #define AI_CONFIG_IMPORT_AC_SEPARATE_BFCULL \
  569. "IMPORT_AC_SEPARATE_BFCULL"
  570. // ---------------------------------------------------------------------------
  571. /** @brief Configures whether the AC loader evaluates subdivision surfaces (
  572. * indicated by the presence of the 'subdiv' attribute in the file). By
  573. * default, Assimp performs the subdivision using the standard
  574. * Catmull-Clark algorithm
  575. *
  576. * * Property type: bool. Default value: true.
  577. */
  578. #define AI_CONFIG_IMPORT_AC_EVAL_SUBDIVISION \
  579. "IMPORT_AC_EVAL_SUBDIVISION"
  580. // ---------------------------------------------------------------------------
  581. /** @brief Configures the UNREAL 3D loader to separate faces with different
  582. * surface flags (e.g. two-sided vs. single-sided).
  583. *
  584. * * Property type: bool. Default value: true.
  585. */
  586. #define AI_CONFIG_IMPORT_UNREAL_HANDLE_FLAGS \
  587. "UNREAL_HANDLE_FLAGS"
  588. // ---------------------------------------------------------------------------
  589. /** @brief Configures the terragen import plugin to compute uv's for
  590. * terrains, if not given. Furthermore a default texture is assigned.
  591. *
  592. * UV coordinates for terrains are so simple to compute that you'll usually
  593. * want to compute them on your own, if you need them. This option is intended
  594. * for model viewers which want to offer an easy way to apply textures to
  595. * terrains.
  596. * * Property type: bool. Default value: false.
  597. */
  598. #define AI_CONFIG_IMPORT_TER_MAKE_UVS \
  599. "IMPORT_TER_MAKE_UVS"
  600. // ---------------------------------------------------------------------------
  601. /** @brief Configures the ASE loader to always reconstruct normal vectors
  602. * basing on the smoothing groups loaded from the file.
  603. *
  604. * Some ASE files have carry invalid normals, other don't.
  605. * * Property type: bool. Default value: true.
  606. */
  607. #define AI_CONFIG_IMPORT_ASE_RECONSTRUCT_NORMALS \
  608. "IMPORT_ASE_RECONSTRUCT_NORMALS"
  609. // ---------------------------------------------------------------------------
  610. /** @brief Configures the M3D loader to detect and process multi-part
  611. * Quake player models.
  612. *
  613. * These models usually consist of 3 files, lower.md3, upper.md3 and
  614. * head.md3. If this property is set to true, Assimp will try to load and
  615. * combine all three files if one of them is loaded.
  616. * Property type: bool. Default value: true.
  617. */
  618. #define AI_CONFIG_IMPORT_MD3_HANDLE_MULTIPART \
  619. "IMPORT_MD3_HANDLE_MULTIPART"
  620. // ---------------------------------------------------------------------------
  621. /** @brief Tells the MD3 loader which skin files to load.
  622. *
  623. * When loading MD3 files, Assimp checks whether a file
  624. * <md3_file_name>_<skin_name>.skin is existing. These files are used by
  625. * Quake III to be able to assign different skins (e.g. red and blue team)
  626. * to models. 'default', 'red', 'blue' are typical skin names.
  627. * Property type: String. Default value: "default".
  628. */
  629. #define AI_CONFIG_IMPORT_MD3_SKIN_NAME \
  630. "IMPORT_MD3_SKIN_NAME"
  631. // ---------------------------------------------------------------------------
  632. /** @brief Specify the Quake 3 shader file to be used for a particular
  633. * MD3 file. This can also be a search path.
  634. *
  635. * By default Assimp's behaviour is as follows: If a MD3 file
  636. * <tt><any_path>/models/<any_q3_subdir>/<model_name>/<file_name>.md3</tt> is
  637. * loaded, the library tries to locate the corresponding shader file in
  638. * <tt><any_path>/scripts/<model_name>.shader</tt>. This property overrides this
  639. * behaviour. It can either specify a full path to the shader to be loaded
  640. * or alternatively the path (relative or absolute) to the directory where
  641. * the shaders for all MD3s to be loaded reside. Assimp attempts to open
  642. * <tt><dir>/<model_name>.shader</tt> first, <tt><dir>/<file_name>.shader</tt>
  643. * is the fallback file. Note that <dir> should have a terminal (back)slash.
  644. * Property type: String. Default value: n/a.
  645. */
  646. #define AI_CONFIG_IMPORT_MD3_SHADER_SRC \
  647. "IMPORT_MD3_SHADER_SRC"
  648. // ---------------------------------------------------------------------------
  649. /** @brief Configures the LWO loader to load just one layer from the model.
  650. *
  651. * LWO files consist of layers and in some cases it could be useful to load
  652. * only one of them. This property can be either a string - which specifies
  653. * the name of the layer - or an integer - the index of the layer. If the
  654. * property is not set the whole LWO model is loaded. Loading fails if the
  655. * requested layer is not available. The layer index is zero-based and the
  656. * layer name may not be empty.<br>
  657. * Property type: Integer. Default value: all layers are loaded.
  658. */
  659. #define AI_CONFIG_IMPORT_LWO_ONE_LAYER_ONLY \
  660. "IMPORT_LWO_ONE_LAYER_ONLY"
  661. // ---------------------------------------------------------------------------
  662. /** @brief Configures the MD5 loader to not load the MD5ANIM file for
  663. * a MD5MESH file automatically.
  664. *
  665. * The default strategy is to look for a file with the same name but the
  666. * MD5ANIM extension in the same directory. If it is found, it is loaded
  667. * and combined with the MD5MESH file. This configuration option can be
  668. * used to disable this behaviour.
  669. *
  670. * * Property type: bool. Default value: false.
  671. */
  672. #define AI_CONFIG_IMPORT_MD5_NO_ANIM_AUTOLOAD \
  673. "IMPORT_MD5_NO_ANIM_AUTOLOAD"
  674. // ---------------------------------------------------------------------------
  675. /** @brief Defines the begin of the time range for which the LWS loader
  676. * evaluates animations and computes aiNodeAnim's.
  677. *
  678. * Assimp provides full conversion of LightWave's envelope system, including
  679. * pre and post conditions. The loader computes linearly subsampled animation
  680. * chanels with the frame rate given in the LWS file. This property defines
  681. * the start time. Note: animation channels are only generated if a node
  682. * has at least one envelope with more tan one key assigned. This property.
  683. * is given in frames, '0' is the first frame. By default, if this property
  684. * is not set, the importer takes the animation start from the input LWS
  685. * file ('FirstFrame' line)<br>
  686. * Property type: Integer. Default value: taken from file.
  687. *
  688. * @see AI_CONFIG_IMPORT_LWS_ANIM_END - end of the imported time range
  689. */
  690. #define AI_CONFIG_IMPORT_LWS_ANIM_START \
  691. "IMPORT_LWS_ANIM_START"
  692. #define AI_CONFIG_IMPORT_LWS_ANIM_END \
  693. "IMPORT_LWS_ANIM_END"
  694. // ---------------------------------------------------------------------------
  695. /** @brief Defines the output frame rate of the IRR loader.
  696. *
  697. * IRR animations are difficult to convert for Assimp and there will
  698. * always be a loss of quality. This setting defines how many keys per second
  699. * are returned by the converter.<br>
  700. * Property type: integer. Default value: 100
  701. */
  702. #define AI_CONFIG_IMPORT_IRR_ANIM_FPS \
  703. "IMPORT_IRR_ANIM_FPS"
  704. // ---------------------------------------------------------------------------
  705. /** @brief Ogre Importer will try to find referenced materials from this file.
  706. *
  707. * Ogre meshes reference with material names, this does not tell Assimp the file
  708. * where it is located in. Assimp will try to find the source file in the following
  709. * order: <material-name>.material, <mesh-filename-base>.material and
  710. * lastly the material name defined by this config property.
  711. * <br>
  712. * Property type: String. Default value: Scene.material.
  713. */
  714. #define AI_CONFIG_IMPORT_OGRE_MATERIAL_FILE \
  715. "IMPORT_OGRE_MATERIAL_FILE"
  716. // ---------------------------------------------------------------------------
  717. /** @brief Ogre Importer detect the texture usage from its filename.
  718. *
  719. * Ogre material texture units do not define texture type, the textures usage
  720. * depends on the used shader or Ogres fixed pipeline. If this config property
  721. * is true Assimp will try to detect the type from the textures filename postfix:
  722. * _n, _nrm, _nrml, _normal, _normals and _normalmap for normal map, _s, _spec,
  723. * _specular and _specularmap for specular map, _l, _light, _lightmap, _occ
  724. * and _occlusion for light map, _disp and _displacement for displacement map.
  725. * The matching is case insensitive. Post fix is taken between last "_" and last ".".
  726. * Default behavior is to detect type from lower cased texture unit name by
  727. * matching against: normalmap, specularmap, lightmap and displacementmap.
  728. * For both cases if no match is found aiTextureType_DIFFUSE is used.
  729. * <br>
  730. * Property type: Bool. Default value: false.
  731. */
  732. #define AI_CONFIG_IMPORT_OGRE_TEXTURETYPE_FROM_FILENAME \
  733. "IMPORT_OGRE_TEXTURETYPE_FROM_FILENAME"
  734. /** @brief Specifies whether the IFC loader skips over IfcSpace elements.
  735. *
  736. * IfcSpace elements (and their geometric representations) are used to
  737. * represent, well, free space in a building storey.<br>
  738. * Property type: Bool. Default value: true.
  739. */
  740. #define AI_CONFIG_IMPORT_IFC_SKIP_SPACE_REPRESENTATIONS "IMPORT_IFC_SKIP_SPACE_REPRESENTATIONS"
  741. // ---------------------------------------------------------------------------
  742. /** @brief Specifies whether the IFC loader skips over
  743. * shape representations of type 'Curve2D'.
  744. *
  745. * A lot of files contain both a faceted mesh representation and a outline
  746. * with a presentation type of 'Curve2D'. Currently Assimp doesn't convert those,
  747. * so turning this option off just clutters the log with errors.<br>
  748. * Property type: Bool. Default value: true.
  749. */
  750. #define AI_CONFIG_IMPORT_IFC_SKIP_CURVE_REPRESENTATIONS "IMPORT_IFC_SKIP_CURVE_REPRESENTATIONS"
  751. // ---------------------------------------------------------------------------
  752. /** @brief Specifies whether the IFC loader will use its own, custom triangulation
  753. * algorithm to triangulate wall and floor meshes.
  754. *
  755. * If this property is set to false, walls will be either triangulated by
  756. * #aiProcess_Triangulate or will be passed through as huge polygons with
  757. * faked holes (i.e. holes that are connected with the outer boundary using
  758. * a dummy edge). It is highly recommended to set this property to true
  759. * if you want triangulated data because #aiProcess_Triangulate is known to
  760. * have problems with the kind of polygons that the IFC loader spits out for
  761. * complicated meshes.
  762. * Property type: Bool. Default value: true.
  763. */
  764. #define AI_CONFIG_IMPORT_IFC_CUSTOM_TRIANGULATION "IMPORT_IFC_CUSTOM_TRIANGULATION"
  765. #define AI_CONFIG_IMPORT_COLLADA_IGNORE_UP_DIRECTION "IMPORT_COLLADA_IGNORE_UP_DIRECTION"
  766. #endif // !! AI_CONFIG_H_INC