remove FileLoader from PhyObj
This commit is contained in:
parent
e40a79435d
commit
89d98be780
@ -41,12 +41,9 @@ PhyObj::Geom::Geom(PhyObj::GeomType type, refptr< vector<float> > args)
|
|||||||
|
|
||||||
|
|
||||||
/********** PhyObj functions **********/
|
/********** PhyObj functions **********/
|
||||||
void PhyObj::load(FileLoader * fileLoader, const FileLoader::Path & path)
|
void PhyObj::load(unsigned char *data, unsigned int size)
|
||||||
{
|
{
|
||||||
FileLoader::Buffer buff = fileLoader->load(path);
|
string str((char *) data, size);
|
||||||
if (buff.size <= 0)
|
|
||||||
return;
|
|
||||||
string str(buff.data, buff.size);
|
|
||||||
stringstream istr(str, ios_base::in);
|
stringstream istr(str, ios_base::in);
|
||||||
while (!istr.eof())
|
while (!istr.eof())
|
||||||
{
|
{
|
||||||
|
@ -3,7 +3,6 @@
|
|||||||
#define PHYOBJ_H
|
#define PHYOBJ_H
|
||||||
|
|
||||||
#include "refptr/refptr.h"
|
#include "refptr/refptr.h"
|
||||||
#include "FileLoader/FileLoader.h"
|
|
||||||
#include <vector>
|
#include <vector>
|
||||||
|
|
||||||
class PhyObj
|
class PhyObj
|
||||||
@ -29,7 +28,7 @@ class PhyObj
|
|||||||
};
|
};
|
||||||
|
|
||||||
/* Methods */
|
/* Methods */
|
||||||
void load(FileLoader * fileLoader, const FileLoader::Path & path);
|
void load(unsigned char *data, unsigned int size);
|
||||||
size_t getNumGeoms() { return m_geoms.size(); }
|
size_t getNumGeoms() { return m_geoms.size(); }
|
||||||
refptr<Geom> getGeom(int i) { return m_geoms[i]; }
|
refptr<Geom> getGeom(int i) { return m_geoms[i]; }
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user