summaryrefslogtreecommitdiffstats
path: root/libdimensionxx/dimensionxx/objects.hpp
diff options
context:
space:
mode:
authorTavian Barnes <tavianator@gmail.com>2009-07-07 04:23:05 +0000
committerTavian Barnes <tavianator@gmail.com>2009-07-07 04:23:05 +0000
commit81c84a38992ce8e38106d86ce85ac3e88ed91a31 (patch)
tree08fb5913e141b7e208737b799b45921d477d45cc /libdimensionxx/dimensionxx/objects.hpp
parentd7b7b4b3391cf99ca63d8311eac3957df7a862ed (diff)
downloaddimension-81c84a38992ce8e38106d86ce85ac3e88ed91a31.tar.xz
Add shallow copy semantics to Camera's, Object's, and Scene's.
Diffstat (limited to 'libdimensionxx/dimensionxx/objects.hpp')
-rw-r--r--libdimensionxx/dimensionxx/objects.hpp18
1 files changed, 16 insertions, 2 deletions
diff --git a/libdimensionxx/dimensionxx/objects.hpp b/libdimensionxx/dimensionxx/objects.hpp
index 89aab14..5b43dc4 100644
--- a/libdimensionxx/dimensionxx/objects.hpp
+++ b/libdimensionxx/dimensionxx/objects.hpp
@@ -30,7 +30,14 @@ namespace Dimension
{
public:
Sphere();
- virtual ~Sphere();
+ ~Sphere();
+
+ Object* copy() const;
+
+ private:
+ // Copying prohibited, but used internally
+ Sphere(const Sphere& sphere);
+ Sphere& operator=(const Sphere&);
};
// A cube
@@ -38,7 +45,14 @@ namespace Dimension
{
public:
Cube();
- virtual ~Cube();
+ ~Cube();
+
+ Object* copy() const;
+
+ private:
+ // Copying prohibited, but used internally
+ Cube(const Cube& cube);
+ Cube& operator=(const Cube&);
};
}