#include <simgear/math/SGMath.hxx>
#include <osg/ref_ptr>
-#include <osgDB/ReaderWriter>
namespace osg
{
class StateSet;
}
+#include <simgear/scene/model/SGReaderWriterXMLOptions.hxx>
#include <simgear/props/props.hxx>
#include <simgear/structure/SGSharedPtr.hxx>
#include <simgear/scene/util/SGSceneFeatures.hxx>
*/
SGMaterial( const osgDB::ReaderWriter::Options*, const SGPropertyNode *props);
+ SGMaterial(const simgear::SGReaderWriterXMLOptions*,
+ const SGPropertyNode *props);
/**
* Destructor.
*/
protected:
struct _internal_state {
+ _internal_state(simgear::Effect *e, bool l,
+ const simgear::SGReaderWriterXMLOptions *o);
_internal_state(simgear::Effect *e, const std::string &t, bool l,
- const osgDB::ReaderWriter::Options *o);
+ const simgear::SGReaderWriterXMLOptions *o);
+ void add_texture(const std::string &t, int i);
osg::ref_ptr<simgear::Effect> effect;
- std::string texture_path;
+ std::vector<std::pair<std::string,int> > texture_paths;
bool effect_realized;
- osg::ref_ptr<const osgDB::ReaderWriter::Options> options;
+ osg::ref_ptr<const simgear::SGReaderWriterXMLOptions> options;
};
private:
// Internal constructors and methods.
////////////////////////////////////////////////////////////////////
- void read_properties(const osgDB::ReaderWriter::Options* options,
+ void read_properties(const simgear::SGReaderWriterXMLOptions* options,
const SGPropertyNode *props);
- void buildEffectProperties(const osgDB::ReaderWriter::Options* options);
+ void buildEffectProperties(const simgear::SGReaderWriterXMLOptions* options);
};