diff OrthancStone/Sources/OpenGL/OpenGLTexture.h @ 2034:4b24b7533346 deep-learning

cont
author Sebastien Jodogne <s.jodogne@gmail.com>
date Fri, 27 Jan 2023 15:43:24 +0100
parents d10bab7cc396
children a73a8415780f
line wrap: on
line diff
--- a/OrthancStone/Sources/OpenGL/OpenGLTexture.h	Sun Jan 22 10:48:22 2023 +0100
+++ b/OrthancStone/Sources/OpenGL/OpenGLTexture.h	Fri Jan 27 15:43:24 2023 +0100
@@ -43,11 +43,22 @@
       unsigned int  height_;
       OpenGL::IOpenGLContext& context_;
 
+      void Setup(Orthanc::PixelFormat format,
+                 unsigned int width,
+                 unsigned int height,
+                 bool isLinearInterpolation,
+                 const void* data);
+
     public:
       explicit OpenGLTexture(OpenGL::IOpenGLContext& context);
 
       ~OpenGLTexture();
 
+      GLuint GetId() const
+      {
+        return texture_;
+      }
+
       unsigned int GetWidth() const
       {
         return width_;
@@ -58,6 +69,14 @@
         return height_;
       }
 
+      void Setup(Orthanc::PixelFormat format,
+                 unsigned int width,
+                 unsigned int height,
+                 bool isLinearInterpolation)
+      {
+        Setup(format, width, height, isLinearInterpolation, NULL);
+      }
+
       void Load(const Orthanc::ImageAccessor& image,
                 bool isLinearInterpolation);