Project::OSiRiON - Git repositories
Project::OSiRiON
News . About . Screenshots . Downloads . Forum . Wiki . Tracker . Git
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorStijn Buys <ingar@osirion.org>2009-08-11 11:49:12 +0000
committerStijn Buys <ingar@osirion.org>2009-08-11 11:49:12 +0000
commit25bcd92706ce2cd6aee24cfb81e9ff2fd7dd4820 (patch)
tree19e71f817ffc36247f4db718454f3634904284b0 /src/model/fragment.h
parenta2ae048571310e80ba7502f1d81b5dd2eb1e38fa (diff)
misc_model support
Diffstat (limited to 'src/model/fragment.h')
-rw-r--r--src/model/fragment.h18
1 files changed, 16 insertions, 2 deletions
diff --git a/src/model/fragment.h b/src/model/fragment.h
index 9d992e1..0a9ca6a 100644
--- a/src/model/fragment.h
+++ b/src/model/fragment.h
@@ -26,6 +26,11 @@ public:
/// create a new fragment
Fragment(Type type, const Material *material);
+
+ /**
+ * @brief copy constructor
+ */
+ Fragment(const Fragment &other);
/// add a vertex to the fragment
size_t add_vertex(math::Vector3f const & vertex, math::Vector3f const &normal, bool detail);
@@ -95,6 +100,10 @@ public:
inline const float speed() const { return group_speed; }
+ inline const float scale() const { return group_scale; }
+
+ inline const bool transform() const { return group_transform; }
+
inline void set_type(const Type type) { group_type = type; }
@@ -104,6 +113,9 @@ public:
inline void set_speed(const float speed) { group_speed = speed; }
+ inline void set_scale(const float scale) { group_scale = scale; }
+
+ inline void set_transform(const bool transform) { group_transform = transform; }
inline iterator begin() { return group_fragments.begin(); }
@@ -111,7 +123,7 @@ public:
inline const size_t size() const { return group_fragments.size(); }
- inline void push_back(Fragment *fragment) { group_fragments.push_back(fragment); }
+ inline void add_fragment(Fragment *fragment) { group_fragments.push_back(fragment); }
void clear();
@@ -121,11 +133,13 @@ private:
Fragments group_fragments;
math::Vector3f group_location;
- math::Vector3f group_forward;
math::Axis group_axis;
Type group_type;
float group_speed;
+ float group_scale;
+
+ bool group_transform;
};
}