class
AnySceneImporterAny scene importer plugin.
Contents
Detects file type based on file extension, loads corresponding plugin and then tries to open the file with it.
This plugin depends on the Trade library and is built if WITH_ANYSCENEIMPORTER
is enabled when building Magnum. To use as a dynamic plugin, you need to load the "AnySceneImporter"
plugin from MAGNUM_PLUGINS_IMPORTER_DIR
. To use as a static plugin or as a dependency of another plugin with CMake, you need to request the AnySceneImporter
component of the Magnum
package in CMake and link to the Magnum::AnySceneImporter
target. See Downloading and building, Usage with CMake and Loading and using plugins for more information.
Supported formats:
- 3ds Max 3DS and ASE (
*.3ds
,*.ase
), loaded with any plugin that provides3dsImporter
- AC3D (
*.ac
), loaded with any plugin that providesAc3dImporter
- Blender 3D (
*.blend
), loaded with any plugin that providesBlenderImporter
- Biovision BVH (
*.bvh
), loaded with any plugin that providesBvhImporter
- CharacterStudio Motion (
*.csm
), loaded with any plugin that providesCsmImporter
- COLLADA (
*.dae
), loaded with ColladaImporter or any other plugin that provides it - DirectX X (
*.x
), loaded with any plugin that providesDirectXImporter
- AutoCAD DXF (
*.dxf
), loaded with any plugin that providesDxfImporter
- Autodesk FBX (
*.fbx
), loaded with any plugin that providesFbxImporter
- glTF (
*.gltf
), loaded with any plugin that providesGltfImporter
- Binary glTF (
*.glb
), loaded with any plugin that providesGlbImporter
- Industry Foundation Classes (IFC/Step) (
*.ifc
), loaded with any plugin that providesIfcImporter
- Irrlicht Mesh and Scene (
*.irrmesh
,*.irr
), loaded with any plugin that providesIrrlichtImporter
- LightWave, LightWave Scene (
*.lwo
,*.lws
), loaded with any plugin that providesLightWaveImporter
- Modo (
*.lxo
), loaded with any plugin that providesModoImporter
- Milkshape 3D (
*.ms3d
), loaded with any plugin that providesMilkshapeImporter
- Wavefront OBJ (
*.obj
), loaded with ObjImporter or any other plugin that provides it - Ogre XML (
*.xml
), loaded with any plugin that providesOgreImporter
- OpenGEX (
*.ogex
), loaded with OpenGexImporter or any other plugin that provides it - Stanford (
*.ply
), loaded with StanfordImporter or any other plugin that provides it - Stereolitography (
*.stl
), loaded with any plugin that providesStlImporter
- TrueSpace (
*.cob
,*.scn
), loaded with any plugin that providesTrueSpaceImporter
- Unreal (
*.3d
), loaded with any plugin that providesUnrealImporter
- Valve Model (
*.smd
,*.vta
), loaded with any plugin that providesValveImporter
- XGL (
*.xgl
,*.zgl
), loaded with any plugin that providesXglImporter
Only loading from files is supported.
Base classes
- class AbstractImporter
- Base for importer plugins.
Constructors, destructors, conversion operators
-
AnySceneImporter(PluginManager::
Manager<AbstractImporter>& manager) explicit - Constructor with access to plugin manager.
-
AnySceneImporter(PluginManager::
AbstractManager& manager, const std:: string& plugin) explicit - Plugin manager constructor.
Private functions
- auto doFeatures() const override -> Features virtual
- Implementation for features()
- auto doIsOpened() const override -> bool virtual
- Implementation for isOpened()
- void doClose() override virtual
- Implementation for close()
-
void doOpenFile(const std::
string& filename) override virtual - Implementation for openFile()
- auto doDefaultScene() override -> Int virtual
- Implementation for defaultScene()
- auto doSceneCount() const override -> UnsignedInt virtual
- Implementation for sceneCount()
-
auto doSceneForName(const std::
string& name) override -> Int virtual - Implementation for sceneForName()
-
auto doSceneName(UnsignedInt id) override -> std::
string virtual - Implementation for sceneName()
-
auto doScene(UnsignedInt id) override -> Containers::
Optional<SceneData> virtual - Implementation for scene()
- auto doLightCount() const override -> UnsignedInt virtual
- Implementation for lightCount()
-
auto doLightForName(const std::
string& name) override -> Int virtual - Implementation for lightForName()
-
auto doLightName(UnsignedInt id) override -> std::
string virtual - Implementation for lightName()
-
auto doLight(UnsignedInt id) override -> Containers::
Optional<LightData> virtual - Implementation for light()
- auto doCameraCount() const override -> UnsignedInt virtual
- Implementation for cameraCount()
-
auto doCameraForName(const std::
string& name) override -> Int virtual - Implementation for cameraForName()
-
auto doCameraName(UnsignedInt id) override -> std::
string virtual - Implementation for cameraName()
-
auto doCamera(UnsignedInt id) override -> Containers::
Optional<CameraData> virtual - Implementation for camera()
- auto doObject2DCount() const override -> UnsignedInt virtual
- Implementation for object2DCount()
-
auto doObject2DForName(const std::
string& name) override -> Int virtual - Implementation for object2DForName()
-
auto doObject2DName(UnsignedInt id) override -> std::
string virtual - Implementation for object2DName()
-
auto doObject2D(UnsignedInt id) override -> std::
unique_ptr<ObjectData2D> virtual - Implementation for object2D()
- auto doObject3DCount() const override -> UnsignedInt virtual
- Implementation for object3DCount()
-
auto doObject3DForName(const std::
string& name) override -> Int virtual - Implementation for object3DForName()
-
auto doObject3DName(UnsignedInt id) override -> std::
string virtual - Implementation for object3DName()
-
auto doObject3D(UnsignedInt id) override -> std::
unique_ptr<ObjectData3D> virtual - Implementation for object3D()
- auto doMesh2DCount() const override -> UnsignedInt virtual
- Implementation for mesh2DCount()
-
auto doMesh2DForName(const std::
string& name) override -> Int virtual - Implementation for mesh2DForName()
-
auto doMesh2DName(UnsignedInt id) override -> std::
string virtual - Implementation for mesh2DName()
-
auto doMesh2D(UnsignedInt id) override -> Containers::
Optional<MeshData2D> virtual - Implementation for mesh2D()
- auto doMesh3DCount() const override -> UnsignedInt virtual
- Implementation for mesh3DCount()
-
auto doMesh3DForName(const std::
string& name) override -> Int virtual - Implementation for mesh3DForName()
-
auto doMesh3DName(UnsignedInt id) override -> std::
string virtual - Implementation for mesh3DName()
-
auto doMesh3D(UnsignedInt id) override -> Containers::
Optional<MeshData3D> virtual - Implementation for mesh3D()
- auto doMaterialCount() const override -> UnsignedInt virtual
- Implementation for materialCount()
-
auto doMaterialForName(const std::
string& name) override -> Int virtual - Implementation for materialForName()
-
auto doMaterialName(UnsignedInt id) override -> std::
string virtual - Implementation for materialName()
-
auto doMaterial(UnsignedInt id) override -> std::
unique_ptr<AbstractMaterialData> virtual - Implementation for material()
- auto doTextureCount() const override -> UnsignedInt virtual
- Implementation for textureCount()
-
auto doTextureForName(const std::
string& name) override -> Int virtual - Implementation for textureForName()
-
auto doTextureName(UnsignedInt id) override -> std::
string virtual - Implementation for textureName()
-
auto doTexture(UnsignedInt id) override -> Containers::
Optional<TextureData> virtual - Implementation for texture()
- auto doImage1DCount() const override -> UnsignedInt virtual
- Implementation for image1DCount()
-
auto doImage1DForName(const std::
string& name) override -> Int virtual - Implementation for image1DForName()
-
auto doImage1DName(UnsignedInt id) override -> std::
string virtual - Implementation for image1DName()
-
auto doImage1D(UnsignedInt id) override -> Containers::
Optional<ImageData1D> virtual - Implementation for image1D()
- auto doImage2DCount() const override -> UnsignedInt virtual
- Implementation for image2DCount()
-
auto doImage2DForName(const std::
string& name) override -> Int virtual - Implementation for image2DForName()
-
auto doImage2DName(UnsignedInt id) override -> std::
string virtual - Implementation for image2DName()
-
auto doImage2D(UnsignedInt id) override -> Containers::
Optional<ImageData2D> virtual - Implementation for image2D()
- auto doImage3DCount() const override -> UnsignedInt virtual
- Implementation for image3DCount()
-
auto doImage3DForName(const std::
string& name) override -> Int virtual - Implementation for image3DForName()
-
auto doImage3DName(UnsignedInt id) override -> std::
string virtual - Implementation for image3DName()
-
auto doImage3D(UnsignedInt id) override -> Containers::
Optional<ImageData3D> virtual - Implementation for image3D()
Function documentation
void Magnum:: Trade:: AnySceneImporter:: doOpenFile(const std:: string& filename) override virtual private
Implementation for openFile()
If Feature::
Int Magnum:: Trade:: AnySceneImporter:: doDefaultScene() override virtual private
Implementation for defaultScene()
Default implementation returns -1
.
UnsignedInt Magnum:: Trade:: AnySceneImporter:: doSceneCount() const override virtual private
Implementation for sceneCount()
Default implementation returns 0
.
Int Magnum:: Trade:: AnySceneImporter:: doSceneForName(const std:: string& name) override virtual private
Implementation for sceneForName()
Default implementation returns -1
.
std:: string Magnum:: Trade:: AnySceneImporter:: doSceneName(UnsignedInt id) override virtual private
Implementation for sceneName()
Default implementation returns empty string.
UnsignedInt Magnum:: Trade:: AnySceneImporter:: doLightCount() const override virtual private
Implementation for lightCount()
Default implementation returns 0
.
Int Magnum:: Trade:: AnySceneImporter:: doLightForName(const std:: string& name) override virtual private
Implementation for lightForName()
Default implementation returns -1
.
std:: string Magnum:: Trade:: AnySceneImporter:: doLightName(UnsignedInt id) override virtual private
Implementation for lightName()
Default implementation returns empty string.
UnsignedInt Magnum:: Trade:: AnySceneImporter:: doCameraCount() const override virtual private
Implementation for cameraCount()
Default implementation returns 0
.
Int Magnum:: Trade:: AnySceneImporter:: doCameraForName(const std:: string& name) override virtual private
Implementation for cameraForName()
Default implementation returns -1
.
std:: string Magnum:: Trade:: AnySceneImporter:: doCameraName(UnsignedInt id) override virtual private
Implementation for cameraName()
Default implementation returns empty string.
UnsignedInt Magnum:: Trade:: AnySceneImporter:: doObject2DCount() const override virtual private
Implementation for object2DCount()
Default implementation returns 0
.
Int Magnum:: Trade:: AnySceneImporter:: doObject2DForName(const std:: string& name) override virtual private
Implementation for object2DForName()
Default implementation returns -1
.
std:: string Magnum:: Trade:: AnySceneImporter:: doObject2DName(UnsignedInt id) override virtual private
Implementation for object2DName()
Default implementation returns empty string.
UnsignedInt Magnum:: Trade:: AnySceneImporter:: doObject3DCount() const override virtual private
Implementation for object3DCount()
Default implementation returns 0
.
Int Magnum:: Trade:: AnySceneImporter:: doObject3DForName(const std:: string& name) override virtual private
Implementation for object3DForName()
Default implementation returns -1
.
std:: string Magnum:: Trade:: AnySceneImporter:: doObject3DName(UnsignedInt id) override virtual private
Implementation for object3DName()
Default implementation returns empty string.
UnsignedInt Magnum:: Trade:: AnySceneImporter:: doMesh2DCount() const override virtual private
Implementation for mesh2DCount()
Default implementation returns 0
.
Int Magnum:: Trade:: AnySceneImporter:: doMesh2DForName(const std:: string& name) override virtual private
Implementation for mesh2DForName()
Default implementation returns -1
.
std:: string Magnum:: Trade:: AnySceneImporter:: doMesh2DName(UnsignedInt id) override virtual private
Implementation for mesh2DName()
Default implementation returns empty string.
UnsignedInt Magnum:: Trade:: AnySceneImporter:: doMesh3DCount() const override virtual private
Implementation for mesh3DCount()
Default implementation returns 0
.
Int Magnum:: Trade:: AnySceneImporter:: doMesh3DForName(const std:: string& name) override virtual private
Implementation for mesh3DForName()
Default implementation returns -1
.
std:: string Magnum:: Trade:: AnySceneImporter:: doMesh3DName(UnsignedInt id) override virtual private
Implementation for mesh3DName()
Default implementation returns empty string.
UnsignedInt Magnum:: Trade:: AnySceneImporter:: doMaterialCount() const override virtual private
Implementation for materialCount()
Default implementation returns 0
.
Int Magnum:: Trade:: AnySceneImporter:: doMaterialForName(const std:: string& name) override virtual private
Implementation for materialForName()
Default implementation returns -1
.
std:: string Magnum:: Trade:: AnySceneImporter:: doMaterialName(UnsignedInt id) override virtual private
Implementation for materialName()
Default implementation returns empty string.
UnsignedInt Magnum:: Trade:: AnySceneImporter:: doTextureCount() const override virtual private
Implementation for textureCount()
Default implementation returns 0
.
Int Magnum:: Trade:: AnySceneImporter:: doTextureForName(const std:: string& name) override virtual private
Implementation for textureForName()
Default implementation returns -1
.
std:: string Magnum:: Trade:: AnySceneImporter:: doTextureName(UnsignedInt id) override virtual private
Implementation for textureName()
Default implementation returns empty string.
UnsignedInt Magnum:: Trade:: AnySceneImporter:: doImage1DCount() const override virtual private
Implementation for image1DCount()
Default implementation returns 0
.
Int Magnum:: Trade:: AnySceneImporter:: doImage1DForName(const std:: string& name) override virtual private
Implementation for image1DForName()
Default implementation returns -1
.
std:: string Magnum:: Trade:: AnySceneImporter:: doImage1DName(UnsignedInt id) override virtual private
Implementation for image1DName()
Default implementation returns empty string.
UnsignedInt Magnum:: Trade:: AnySceneImporter:: doImage2DCount() const override virtual private
Implementation for image2DCount()
Default implementation returns 0
.
Int Magnum:: Trade:: AnySceneImporter:: doImage2DForName(const std:: string& name) override virtual private
Implementation for image2DForName()
Default implementation returns -1
.
std:: string Magnum:: Trade:: AnySceneImporter:: doImage2DName(UnsignedInt id) override virtual private
Implementation for image2DName()
Default implementation returns empty string.
UnsignedInt Magnum:: Trade:: AnySceneImporter:: doImage3DCount() const override virtual private
Implementation for image3DCount()
Default implementation returns 0
.
Int Magnum:: Trade:: AnySceneImporter:: doImage3DForName(const std:: string& name) override virtual private
Implementation for image3DForName()
Default implementation returns -1
.
std:: string Magnum:: Trade:: AnySceneImporter:: doImage3DName(UnsignedInt id) override virtual private
Implementation for image3DName()
Default implementation returns empty string.