Inviwo 0.9.12-pre
Inviwo documentation
Loading...
Searching...
No Matches
inviwo::utilgl::DataMinMaxGL Class Reference

Utility class for computing min and max values using OpenGL. More...

#include <dataminmaxgl.h>

Public Member Functions

 DataMinMaxGL (const DataMinMaxGL &)=delete
 
 DataMinMaxGL (DataMinMaxGL &&) noexcept=default
 
DataMinMaxGLoperator= (const DataMinMaxGL &)=delete
 
DataMinMaxGLoperator= (DataMinMaxGL &&) noexcept=default
 
std::pair< dvec4, dvec4 > minMax (const Volume &volume)
 
std::pair< dvec4, dvec4 > minMax (const VolumeGL &volumeGL)
 
std::pair< dvec4, dvec4 > minMax (const Layer &layer)
 
std::pair< dvec4, dvec4 > minMax (const LayerGL &layerGL)
 
std::pair< dvec4, dvec4 > minMax (const BufferBase &buffer)
 
std::pair< dvec4, dvec4 > minMax (const BufferGL &bufferGL)
 

Static Public Member Functions

static bool isSuppportedByGPU ()
 

Detailed Description

Utility class for computing min and max values using OpenGL.

This class uses compute shaders to compute min and max values of Buffers, Layers, and Volumes. If compute shaders are not available, the corresponding CPU functions from modules/base/algorithm/dataminmax.h are used instead.

The GPU needs to support the following OpenGL extensions:

  • GL_KHR_shader_subgroup
  • for 8bit and 16bit data type support for SSBOs (int8_t, i8vec2, ...)
    • NVIDIA: GL_NV_gpu_shader5
    • AMD: GL_EXT_shader_explicit_arithmetic_types

Member Function Documentation

◆ isSuppportedByGPU()

static bool inviwo::utilgl::DataMinMaxGL::isSuppportedByGPU ( )
static

Check whether the GPU supports compute shaders and the necessary OpenGL extensions.

  • GL_KHR_shader_subgroup
  • for 8bit and 16bit data type support for SSBOs (int8_t, i8vec2, ...)
    • NVIDIA: GL_NV_gpu_shader5
    • AMD: GL_EXT_shader_explicit_arithmetic_types
Returns
true if the GPU fulfills all requirements

The documentation for this class was generated from the following file: