diff Framework/Scene2D/ColorTextureSceneLayer.h @ 590:5430bcffba57

FloatTextureSceneLayer
author Sebastien Jodogne <s.jodogne@gmail.com>
date Fri, 26 Apr 2019 11:33:57 +0200
parents 2a8ac2d426db
children 55411e7da2f7
line wrap: on
line diff
--- a/Framework/Scene2D/ColorTextureSceneLayer.h	Thu Apr 25 14:00:55 2019 +0200
+++ b/Framework/Scene2D/ColorTextureSceneLayer.h	Fri Apr 26 11:33:57 2019 +0200
@@ -21,58 +21,20 @@
 
 #pragma once
 
-#include "ISceneLayer.h"
-#include "../Toolbox/AffineTransform2D.h"
-
-#include <Core/Images/ImageAccessor.h>
-#include <memory>
+#include "TextureBaseSceneLayer.h"
 
 namespace OrthancStone
 {
-  class ColorTextureSceneLayer : public ISceneLayer
+  class ColorTextureSceneLayer : public TextureBaseSceneLayer
   {
-  private:
-    std::auto_ptr<Orthanc::ImageAccessor>  texture_;
-    double                                 originX_;
-    double                                 originY_;
-    double                                 pixelSpacingX_;
-    double                                 pixelSpacingY_;
-    double                                 angle_;
-    bool                                   isLinearInterpolation_;
-
   public:
-    ColorTextureSceneLayer(const Orthanc::ImageAccessor& texture,
-                           double originX,  // Center of the top-left pixel
-                           double originY,
-                           double pixelSpacingX,
-                           double pixelSpacingY,
-                           double angle,
-                           bool isLinearInterpolation);
+    ColorTextureSceneLayer(const Orthanc::ImageAccessor& texture);
 
     virtual ISceneLayer* Clone() const;
 
-    const Orthanc::ImageAccessor& GetTexture() const
-    {
-      return *texture_;
-    }
-
-    AffineTransform2D GetTransform() const;
-
-    bool IsLinearInterpolation() const
-    {
-      return isLinearInterpolation_;
-    }
-
     virtual Type GetType() const
     {
       return Type_ColorTexture;
     }
-
-    virtual bool GetBoundingBox(Extent2D& target) const;
-    
-    virtual uint64_t GetRevision() const
-    {
-      return 0;
-    }
   };
 }