rordenlab / MRIcroGL

v1.2 GLSL volume rendering. Able to view NIfTI, DICOM, MGH, MHD, NRRD, AFNI format images.
https://www.nitrc.org/plugins/mwiki/index.php/mricrogl:MainPage
Other
197 stars 31 forks source link

MRIcroGL overlay render depth #46

Closed TamerGezici closed 1 year ago

TamerGezici commented 1 year ago

Hi,

On MRIcron, when you do a render the brain is opaque, so you only see the surface activation.

However on MRIcroGL, when you do "surface overlay" the brain is transparent, so you see activation deep inside as well.

The issue is, when you modify the "overlay depth" it does not specify how deep you are looking into the cortex. Can someone please tell me how much in mm/cm does the overlay depth correspond to? Or how can I replicate the exact search depth that is used in MRIcron?

How can I make the brain opaque in MRIcroGL?

How can I find out the voxel-wise search depth in MRIcroGL? Which is an option in MRIcron like this:

image

neurolabusc commented 1 year ago

Use the OverlaySurface shader to make the background image completely opaque so overlays only appear if they are on the surface of the background image. Try the Scripting/Templates/cutout Python script for an example of this approach.

For the Default shader, the overlayDepth slider controls the opacity of the background image, which influences the amount of attenuation the background image experiences. Note with this shader the overlay does is not a binary visible and invisible, rather it becomes gradually more transparent the further away it is. The analogy is you are controlling how thick the fog of the background image is: in a thick fog, we can only see a car headlights just as they are at the edge of the fog bank, but with very light fog we can vaguely make out the car headlights even when the car is deep inside the fog bank.

TamerGezici commented 1 year ago

Thank you.