IMeshModel Class Reference

An IModel dedicated for loading models from files. More...

#include <model.h>

Inheritance diagram for IMeshModel:

IModel CObjModel

List of all members.

Public Member Functions

virtual bool loadObjModel (const QString &fileName)=0
 Loads a model from a file.

Static Public Member Functions

static IMeshModelcreateMeshModel (void)
 Creates a IMeshModel object.


Detailed Description

An IModel dedicated for loading models from files.

This class can be used to access models stored in files. After construction, no model data is available. It must be loaded with loadObjModel(). Currently only a subset of Wavefront .OBJ models files are supported. It can load the model's geometry, including position, normals and texture coords. It scales the model to fit into a unit shere. Missing attributes are filled with default values.


This class does not support loading of external material files, because IModel does not support material properties. Materials must be set by the user in the material dialog.


Member Function Documentation

virtual bool IMeshModel::loadObjModel ( const QString &  fileName  )  [pure virtual]

Loads a model from a file.

The file to load is assumed to be of .OBJ format. If loading fails, then this object looses the data stored in it.

Parameters:
fileName Name of the file to load.
Returns:
Ture if loading succeeded, flase otherwise.

Implemented in CObjModel.


The documentation for this class was generated from the following files:
Generated on Sun Mar 2 17:12:32 2008 for Shader Maker by  doxygen 1.5.4