Maximum intensity projection in pyqtgraph using GLVolumeItem

Question:

I would like to use the maximum intensity projection (MIP) to view some 3D medical images in pyqtgraph using GLVolumeItem. I see that there are three pre-defined GLOptions settings. The translucent and additive mode both look like MIP. So my questions are

  1. Is it the real MIP view? If not, how should I change the GLOptions (e.g., GL_DEPTH_TEST, GL_BLEND, etc)?
  2. Is there a website that contains the GL configurations (e.g., GL_DEPTH_TEST, GL_BLEND, etc) for different display mode?

Update:

From this website, I set the GLOptions to be

{'glBlendFunc': (GL_ONE, GL_ONE), 'glBlendEquation': (GL_MAX_EXT), GL_BLEND: True}

However, an error pops up saying that GL_MAX_EXT is not defined. Any ideas how I should fix it?

Asked By: zjx1805

||

Answers:

Finally I found the answer:

from OpenGL.GL import *
from OpenGL import GL
from OpenGL.GL.EXT.blend_minmax import GL_MAX_EXT

glOptions = {'glBlendFunc': (GL_ONE, GL_ONE), 'glBlendEquation': (GL_MAX_EXT, ), GL_BLEND: True}

This should give you the real MIP view.

Answered By: zjx1805

May I ask, were you successful in this? Can the OpenGL MIP be used on a point cloud like a 3d scatter plot? I recently posted a question on it. I would greatly appreciate assistance.

Answered By: Marius
Categories: questions Tags: , ,
Answers are sorted by their score. The answer accepted by the question owner as the best is marked with
at the top-right corner.