aboutsummaryrefslogtreecommitdiffhomepage
path: root/demos
diff options
context:
space:
mode:
authorGravatar Gael Guennebaud <g.gael@free.fr>2008-09-03 00:32:56 +0000
committerGravatar Gael Guennebaud <g.gael@free.fr>2008-09-03 00:32:56 +0000
commitf52d119b9c4f9b6dfbb91183de08143fdf3cc94c (patch)
tree2369642bacec55b4d372797d42d27c74c6ac75eb /demos
parentd8df318d77b8a9bd9d6274f25145639603c2e8d4 (diff)
Solve a big issue with data alignment and dynamic allocation:
* add a WithAlignedOperatorNew class with overloaded operator new * make Matrix (and Quaternion, Transform, Hyperplane, etc.) use it if needed such that "*(new Vector4) = xpr" does not failed anymore. * Please: make sure your classes having fixed size Eigen's vector or matrice attributes inherit WithAlignedOperatorNew * add a ei_new_allocator STL memory allocator to use with STL containers. This allocator really calls operator new on your types (unlike GCC's new_allocator). Example: std::vector<Vector4f> data(10); will segfault if the vectorization is enabled, instead use: std::vector<Vector4f,ei_new_allocator<Vector4f> > data(10); NOTE: you only have to worry if you deal with fixed-size matrix types with "sizeof(matrix_type)%16==0"...
Diffstat (limited to 'demos')
-rw-r--r--demos/CMakeLists.txt1
1 files changed, 1 insertions, 0 deletions
diff --git a/demos/CMakeLists.txt b/demos/CMakeLists.txt
index b1e206096..64298baf4 100644
--- a/demos/CMakeLists.txt
+++ b/demos/CMakeLists.txt
@@ -1,3 +1,4 @@
IF(BUILD_DEMOS)
ADD_SUBDIRECTORY(mandelbrot)
+ADD_SUBDIRECTORY(opengl)
ENDIF(BUILD_DEMOS)