~robot3d-team/robot3d/trunk

« back to all changes in this revision

Viewing changes to inc/srCore/loadComponents.h

  • Committer: Anne van Rossum
  • Date: 2010-08-10 15:58:55 UTC
  • Revision ID: anne@gamix-20100810155855-kve7x2vwouagdij9
Initial import

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
/**
 
2
 * @file loadComponents.h
 
3
 *
 
4
 * This file loadComponents.h is created at Almende B.V. It is open-source software and part
 
5
 * of the Common Hybrid Agent Platform (CHAP). A toolbox with a lot of open-source tools.
 
6
 * Ranging from thread pools, and TCP/IP components to control architectures and learning
 
7
 * algorithms. This software is published under the GNU Lesser General Public license,
 
8
 *
 
9
 * It is not possible to add usage restrictions to an open-source license. Nevertheless,
 
10
 * we personally strongly object against this software used by the military, in the
 
11
 * bio-industry, for animal experimentation, or anything that violates the Universal
 
12
 * Declaration of Human Rights.
 
13
 *
 
14
 * @author      Anne C. van Rossum
 
15
 * @date        Aug 4, 2010
 
16
 * @project     Replicator FP7
 
17
 * @company     Almende B.V.
 
18
 * @case        
 
19
 */
 
20
 
 
21
 
 
22
#ifndef LOADCOMPONENTS_H_
 
23
#define LOADCOMPONENTS_H_
 
24
 
 
25
// General files
 
26
#include <vector>
 
27
 
 
28
// Open Scene Graph
 
29
#include <osg/Referenced>
 
30
 
 
31
// Boost library
 
32
#include <boost/filesystem.hpp>
 
33
 
 
34
// Delta3D files
 
35
#include <dtGame/gameapplication.h>
 
36
 
 
37
namespace srCore {
 
38
 
 
39
/* **************************************************************************************
 
40
 * Interface of loadComponents
 
41
 * **************************************************************************************/
 
42
 
 
43
 
 
44
class LoadComponents: public osg::Referenced {
 
45
public:
 
46
        /**
 
47
         * Constructor loadComponents
 
48
         */
 
49
        LoadComponents();
 
50
 
 
51
        /**
 
52
         * Destructor ~loadComponents
 
53
         */
 
54
        virtual ~LoadComponents();
 
55
 
 
56
        /**
 
57
         *
 
58
         */
 
59
        void LoadLibs(dtGame::GameApplication &application);
 
60
 
 
61
        /**
 
62
         *
 
63
         */
 
64
        void SetLibPath(const std::string &libpath);
 
65
 
 
66
        /**
 
67
         * Get all .so files
 
68
         */
 
69
        void GetLibraries();
 
70
protected:
 
71
 
 
72
private:
 
73
        boost::filesystem::path path;
 
74
 
 
75
        std::vector<std::string> library;
 
76
 
 
77
        bool initialised;
 
78
 
 
79
        std::vector<void*> handles;
 
80
};
 
81
 
 
82
}
 
83
 
 
84
#endif /* LOADCOMPONENTS_H_ */