Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

source: orxonox.OLD/branches/new_class_id/src/lib/graphics/importer/resource_obj.h @ 9847

Last change on this file since 9847 was 9847, checked in by bensch, 18 years ago

renamed NewResource to Resource

File size: 952 bytes
Line 
1/*!
2 * @file resource_obj.h
3 * @brief Contains the ResourceOBJ class, that handles the Resource-specific loading part of the OBJ.
4 *
5 */
6
7#ifndef _RESOURCE_OBJ_H
8#define _RESOURCE_OBJ_H
9
10#include "util/loading/resource.h"
11#include "objModel.h"
12
13class ResourceOBJ : public StaticModel, public Resources::Resource
14{
15public:
16  ResourceOBJ(const std::string& imageName, float scaling = 1.0f);
17  static ResourceOBJ createFromString(const std::string& loadString);
18
19private:
20class OBJResourcePointer : public Resources::StorePointer
21  {
22  public:
23    OBJResourcePointer(const std::string& loadString, const Resources::KeepLevel& keepLevel, const StaticModelData::Pointer& data);
24    inline const StaticModelData::Pointer& ptr() const { return pointer; }
25    virtual bool last() const { return pointer.count() == 1; }
26private:
27    StaticModelData::Pointer pointer;
28  };
29
30private:
31  static Resources::tType<ResourceOBJ> type;
32};
33
34
35#endif /* _RESOURCE_OBJ_H */
Note: See TracBrowser for help on using the repository browser.