47 lines
1017 B
C++
47 lines
1017 B
C++
/* -----------------------------------------------------------------------------
|
|
GSFramework
|
|
Copyright 2001-2013 Emmanuel Julien. All Rights Reserved.
|
|
----------------------------------------------------------------------------- */
|
|
|
|
|
|
#ifndef __NOBJ_IMPORT__
|
|
#define __NOBJ_IMPORT__
|
|
|
|
|
|
#include "import/import_interface.h"
|
|
|
|
|
|
struct ObjMtl;
|
|
|
|
namespace GS {
|
|
namespace Core { class Geometry; }
|
|
namespace S3D {
|
|
|
|
/*
|
|
@short OBJ importer.
|
|
@author Emmanuel Julien (ejulien@gsworks.fr)
|
|
*/
|
|
class OBJImporter : public IImport
|
|
{
|
|
const Config *config;
|
|
|
|
/// Load a material library from file.
|
|
bool LoadMaterialLibrary(List <ObjMtl *> &, const char *uri);
|
|
|
|
public:
|
|
|
|
/// Import geometry.
|
|
Core::Geometry *ImportGeometry(const char *uri, IResourceFactoryEvent * = 0);
|
|
|
|
/// Test importer on a file.
|
|
virtual bool TestImport(const char *uri);
|
|
/// Import as scene from obj groups.
|
|
virtual bool ImportScene(Scene *, const char *uri, const Config &, Group ** = 0);
|
|
};
|
|
|
|
} // S3D
|
|
} // GS
|
|
|
|
|
|
#endif // __NOBJ_IMPORT__
|