Commit f5ecff91 authored by Declara Denis's avatar Declara Denis Committed by Christian Schulte zu Berge
Browse files

Substituted shared_ptr with unique_ptr for geometry data

parent d505a70f
......@@ -215,7 +215,7 @@ namespace campvis {
tbb::mutex _localMutex; ///< Mutex protecting the local members
cgt::Shader* _paintShader; ///< GLSL shader for rendering the textures
std::shared_ptr<FaceGeometry> _quad; ///< Quad used for rendering
std::unique_ptr<FaceGeometry> _quad; ///< Quad used for rendering
cgt::ivec2 _numTiles; ///< number of tiles on texture overview
cgt::ivec2 _quadSize; ///< size in pixels for each tile in overview
......@@ -123,8 +123,8 @@ namespace campvis {
void renderTensorGlyph(const GenericImageRepresentationLocal<float, 3>* evals, const GenericImageRepresentationLocal<float, 9>* evecs, const cgt::vec3& position);
cgt::Shader* _shader; ///< Shader for glyph rendering
std::shared_ptr<GeometryData> _ellipsoidGeometry; ///< Geometry for ellipsoid rendering
std::shared_ptr<GeometryData> _cubeGeometry; ///< Geometry for cuboid rendering
std::unique_ptr<GeometryData> _ellipsoidGeometry; ///< Geometry for ellipsoid rendering
std::unique_ptr<GeometryData> _cubeGeometry; ///< Geometry for cuboid rendering
static const std::string loggerCat_;
......@@ -126,8 +126,8 @@ namespace campvis {
void renderVectorArrow(const GenericImageRepresentationLocal<float, 3>* vectors, const cgt::vec3& position, float scale);
std::shared_ptr<GeometryData> _arrowGeometry; ///< Geometry for arrow rendering
cgt::Shader* _shader; ///< Shader for arrow rendering
std::unique_ptr<GeometryData> _arrowGeometry; ///< Geometry for arrow rendering
cgt::Shader* _shader; ///< Shader for arrow rendering
static const std::string loggerCat_;
......@@ -89,7 +89,7 @@ namespace campvis {
// The closing face is the slice proxy geometry.
// This is probably not the fastest, but an elegant solution, which also supports arbitrary slice orientations. :)
cgt::Bounds volumeExtent = img->getParent()->getWorldBounds();
std::shared_ptr<MeshGeometry> cube = GeometryDataFactory::createCube(volumeExtent, cgt::Bounds(cgt::vec3(0.f), cgt::vec3(1.f)));
std::unique_ptr<MeshGeometry> cube = GeometryDataFactory::createCube(volumeExtent, cgt::Bounds(cgt::vec3(0.f), cgt::vec3(1.f)));
cgt::vec3 normal(0.f, 0.f, 1.f);
float p = img->getParent()->getMappingInformation().getOffset().z + (p_sliceNumber.getValue() * img->getParent()->getMappingInformation().getVoxelSize().z);
......@@ -106,7 +106,7 @@ namespace campvis {
cgt::Texture* _xorBitmaskTexture; ///< Texture holding the 128x128 possible combinations of uvec4 bitmasks
cgt::Texture* _hierarchyTexture; ///< The OpenGL texture storing the voxel hierarchy
std::shared_ptr<FaceGeometry> _quad;
std::unique_ptr<FaceGeometry> _quad;
static std::string loggerCat_;
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment