comparison OrthancStone/Sources/OpenGL/ImageProcessingProgram.h @ 2064:4e31d76c7ecd deep-learning

making ImageProcessingProgram compatible with 3D volumes
author Sebastien Jodogne <s.jodogne@gmail.com>
date Thu, 04 May 2023 11:06:19 +0200
parents 6ea5f40ea0e9
children
comparison
equal deleted inserted replaced
2063:b6b5e1ca1cc2 2064:4e31d76c7ecd
31 namespace OpenGL 31 namespace OpenGL
32 { 32 {
33 class OpenGLFramebuffer; 33 class OpenGLFramebuffer;
34 class OpenGLTexture; 34 class OpenGLTexture;
35 class OpenGLTextureArray; 35 class OpenGLTextureArray;
36 class OpenGLTextureVolume;
36 37
37 class ImageProcessingProgram : public boost::noncopyable 38 class ImageProcessingProgram : public boost::noncopyable
38 { 39 {
39 private: 40 private:
40 OpenGLProgram program_; 41 OpenGLProgram program_;
42 43
43 void SetupPosition(); 44 void SetupPosition();
44 45
45 public: 46 public:
46 ImageProcessingProgram(IOpenGLContext& context, 47 ImageProcessingProgram(IOpenGLContext& context,
47 const std::string& fragmentShader); 48 const std::string& fragmentShader,
49 bool addUniformZ /* for 3D texture sampling */);
48 50
49 ~ImageProcessingProgram(); 51 ~ImageProcessingProgram();
50 52
51 void Use(OpenGLTexture& target, 53 void Use(OpenGLTexture& target,
52 OpenGLFramebuffer& framebuffer, 54 OpenGLFramebuffer& framebuffer,
53 bool checkStatus); 55 bool checkStatus);
54 56
55 void Use(OpenGLTextureArray& target, 57 void Use(OpenGLTextureArray& target,
56 unsigned int targetLayer, 58 unsigned int targetLayer,
59 OpenGLFramebuffer& framebuffer,
60 bool checkStatus);
61
62 void Use(OpenGLTextureVolume& volume,
63 unsigned int z,
57 OpenGLFramebuffer& framebuffer, 64 OpenGLFramebuffer& framebuffer,
58 bool checkStatus); 65 bool checkStatus);
59 66
60 void Render(); 67 void Render();
61 68