Class AIMeshLoader
Inheritance
java.lang.Object
AIMeshLoader
Syntax
public class AIMeshLoader
Fields
AI_DEBONE_THRESHOLD
Default value for configuration properties.
Declaration
public static final float AI_DEBONE_THRESHOLD= 1.0f
Field Value
Type |
Description |
final float |
|
AI_DEFAULT_FLAGS
Declaration
public static final int AI_DEFAULT_FLAGS= aiProcess_Triangulate | aiProcess_GenSmoothNormals
| aiProcess_CalcTangentSpace | aiProcess_OptimizeMeshes| aiProcess_JoinIdenticalVertices
Field Value
Type |
Description |
final int |
|
AI_DEFAULT_MATERIAL_NAME
Name for default materials (2nd is used if meshes have UV coords)
Declaration
public static final String AI_DEFAULT_MATERIAL_NAME= "DefaultMaterial"
Field Value
Type |
Description |
final String |
|
ai_epsilon
Declaration
public static final float ai_epsilon= 0.00001f
Field Value
Type |
Description |
final float |
|
AI_MATH_PI
Declaration
public static final double AI_MATH_PI= 3.141592653589793d
Field Value
Type |
Description |
final double |
|
AI_MATH_PI_F
Declaration
public static final float AI_MATH_PI_F= 3.1415927f
Field Value
Type |
Description |
final float |
|
AI_MATKEY_GLTF_PBRMETALLICROUGHNESS_BASE_COLOR_TEXTURE
Declaration
public static final int AI_MATKEY_GLTF_PBRMETALLICROUGHNESS_BASE_COLOR_TEXTURE= aiTextureType_DIFFUSE
Field Value
Type |
Description |
final int |
|
AI_MATKEY_NAME
Declaration
public static final String AI_MATKEY_NAME= "?mat.name"
Field Value
Type |
Description |
final String |
|
AI_MAX_BONE_WEIGHTS
Maximum number of indices per face (polygon).
Declaration
public static final int AI_MAX_BONE_WEIGHTS= 0x7FFFFFFF
Field Value
Type |
Description |
final int |
|
AI_MAX_FACE_INDICES
Maximum number of indices per face (polygon).
Declaration
public static final int AI_MAX_FACE_INDICES= 0x7FFF
Field Value
Type |
Description |
final int |
|
AI_MAX_FACES
Maximum number of faces per mesh.
Declaration
public static final int AI_MAX_FACES= 0x7FFFFFFF
Field Value
Type |
Description |
final int |
|
AI_MAX_NUMBER_OF_COLOR_SETS
Supported number of vertex color sets per mesh.
Declaration
public static final int AI_MAX_NUMBER_OF_COLOR_SETS= 0x8
Field Value
Type |
Description |
final int |
|
AI_MAX_NUMBER_OF_TEXTURECOORDS
Supported number of texture coord sets (UV(W) channels) per mesh.
Declaration
public static final int AI_MAX_NUMBER_OF_TEXTURECOORDS= 0x8
Field Value
Type |
Description |
final int |
|
AI_MAX_VERTICES
Maximum number of vertices per mesh.
Declaration
public static final int AI_MAX_VERTICES= 0x7FFFFFFF
Field Value
Type |
Description |
final int |
|
AI_SBBC_DEFAULT_MAX_BONES
Default values for configuration properties.
Declaration
public static final int AI_SBBC_DEFAULT_MAX_BONES= 0x3C
Field Value
Type |
Description |
final int |
|
AI_TRUE
Declaration
public static final int AI_TRUE= 0x1
Field Value
Type |
Description |
final int |
|
AI_UVTRAFO_SCALING
Declaration
public static final int AI_UVTRAFO_SCALING= 0x1
Field Value
Type |
Description |
final int |
|
Declaration
public static final String aiAI_MATKEY_GLTF_PBRMETALLICROUGHNESS_BASE_COLOR_FACTOR= "$mat.gltf.pbrMetallicRoughness.baseColorFactor"
Field Value
Type |
Description |
final String |
|
aiBlendMode_Default
Defines alpha-blend flags.
Declaration
public static final int aiBlendMode_Default= 0x0
Field Value
Type |
Description |
final int |
|
aiComponent_NORMALS
Declaration
public static final int aiComponent_NORMALS= 0x2
Field Value
Type |
Description |
final int |
|
aiLightSource_UNDEFINED
Enumerates all supported types of light sources.
Declaration
public static final int aiLightSource_UNDEFINED= 0x0
Field Value
Type |
Description |
final int |
|
aiProcess_CalcTangentSpace
Defines the flags for all possible post processing steps.
Declaration
public static final int aiProcess_CalcTangentSpace= 0x1
Field Value
Type |
Description |
final int |
|
aiProcess_ConvertToLeftHanded
Declaration
public static final int aiProcess_ConvertToLeftHanded= aiProcess_MakeLeftHanded | aiProcess_FlipUVs
| aiProcess_FlipWindingOrder | 0
Field Value
Type |
Description |
final int |
|
aiPTI_Float
A very primitive RTTI system for the contents of material properties.
Declaration
public static final int aiPTI_Float= 0x1
Field Value
Type |
Description |
final int |
|
aiShadingMode_Flat
Defines all shading models supported by the library.
Declaration
public static final int aiShadingMode_Flat= 0x1
Field Value
Type |
Description |
final int |
|
aiTextureFlags_Invert
Defines some mixed flags for a particular texture.
Declaration
public static final int aiTextureFlags_Invert= 0x1
Field Value
Type |
Description |
final int |
|
aiTextureMapMode_Wrap
Defines how UV coordinates outside the [0...1] range are handled. Commonly referred to as 'wrapping mode'.
Declaration
public static final int aiTextureMapMode_Wrap= 0x0
Field Value
Type |
Description |
final int |
|
aiTextureMapping_UV
Defines how the mapping coords for a texture are generated.
Declaration
public static final int aiTextureMapping_UV= 0x0
Field Value
Type |
Description |
final int |
|
aiTextureOp_Multiply
Defines how the Nth texture of a specific type is combined with the result of all previous layers.
Declaration
public static final int aiTextureOp_Multiply= 0x0
Field Value
Type |
Description |
final int |
|
aiTextureType_NONE
Defines the purpose of a texture.
Declaration
public static final int aiTextureType_NONE= 0x0
Field Value
Type |
Description |
final int |
|
MAXLEN
Maximum dimension for strings, ASSIMP strings are zero terminated.
Declaration
public static final int MAXLEN= 0x400
Field Value
Type |
Description |
final int |
|
MODELS_DIR
Declaration
public static final String MODELS_DIR= "./res/models/"
Field Value
Type |
Description |
final String |
|
Methods
loadModel(String modelFileName, String modelName, int post_options)
Declaration
public static Mesh loadModel(String modelFileName, String modelName, int post_options)
Parameters
Type |
Name |
Description |
String |
modelFileName |
|
String |
modelName |
|
int |
post_options |
|
Returns
loadModel(String modelFileName, String modelName, int post_options, AssetManager man)
Loads a mesh from a file using AssetI Importer Library. If no post options are provided (The value is 0) defaults will be used. Defaults are : aiProcess_Triangulate | aiProcess_GenSmoothNormals | aiProcess_FlipUVs | aiProcess_CalcTangentSpace. NOTE: aiProcess_JoinIdenticalVertices is useful.
Declaration
public static Mesh loadModel(String modelFileName, String modelName, int post_options, AssetManager man)
Parameters
Type |
Name |
Description |
String |
modelFileName |
|
String |
modelName |
|
int |
post_options |
|
AssetManager |
man |
|
Returns
Type |
Description |
Mesh |
A Model Scene, since one model file can contain many individual models.
|
loadModelScene(String modelFilePath, int post_options, AssetManager man)
Declaration
public static ModelScene loadModelScene(String modelFilePath, int post_options, AssetManager man)
Parameters
Type |
Name |
Description |
String |
modelFilePath |
|
int |
post_options |
|
AssetManager |
man |
|
Returns
printLibInfo()
Declaration
public static void printLibInfo()
removeMesh(Mesh mesh)
Declaration
public static void removeMesh(Mesh mesh)
Parameters
Type |
Name |
Description |
Mesh |
mesh |
|