Mercurial > hg > orthanc-stone
changeset 2058:c0627145b441 deep-learning
added OpenGLTexture::IsLinearInterpolation()
author | Sebastien Jodogne <s.jodogne@gmail.com> |
---|---|
date | Mon, 24 Apr 2023 17:09:23 +0200 |
parents | 8bb8d9c0cfd0 |
children | f7cbc58ff44d |
files | OrthancStone/Sources/OpenGL/OpenGLTexture.cpp OrthancStone/Sources/OpenGL/OpenGLTexture.h |
diffstat | 2 files changed, 9 insertions(+), 1 deletions(-) [+] |
line wrap: on
line diff
--- a/OrthancStone/Sources/OpenGL/OpenGLTexture.cpp Fri Apr 21 14:39:23 2023 +0200 +++ b/OrthancStone/Sources/OpenGL/OpenGLTexture.cpp Mon Apr 24 17:09:23 2023 +0200 @@ -43,7 +43,8 @@ width_(0), height_(0), format_(Orthanc::PixelFormat_Grayscale8), - context_(context) + context_(context), + isLinearInterpolation_(false) { if (!context_.IsContextLost()) { @@ -116,6 +117,7 @@ format_ = format; width_ = width; height_ = height; + isLinearInterpolation_ = isLinearInterpolation; GLint interpolation = (isLinearInterpolation ? GL_LINEAR : GL_NEAREST);
--- a/OrthancStone/Sources/OpenGL/OpenGLTexture.h Fri Apr 21 14:39:23 2023 +0200 +++ b/OrthancStone/Sources/OpenGL/OpenGLTexture.h Mon Apr 24 17:09:23 2023 +0200 @@ -44,6 +44,7 @@ Orthanc::PixelFormat format_; OpenGL::IOpenGLContext& context_; + bool isLinearInterpolation_; void Setup(Orthanc::PixelFormat format, unsigned int width, @@ -80,6 +81,11 @@ return height_; } + bool IsLinearInterpolation() const + { + return isLinearInterpolation_; + } + void Setup(Orthanc::PixelFormat format, unsigned int width, unsigned int height,