pauldmccarthy / fsleyes

This is a mirror. Feel free to use the issue tracker. PRs welcome.
https://git.fmrib.ox.ac.uk/fsl/fsleyes/fsleyes/
Other
22 stars 11 forks source link

Setting mask transparency #130

Closed davidmwatson closed 9 months ago

davidmwatson commented 10 months ago

Hi, I've been having some difficulty setting the transparency of mask overlays programmatically. I'm using fsleyes version 1.10.0. I've tried it on a couple of different computers (one Debian, the other Ubuntu) and have encountered the issue on both.

If I run something like:

fsleyes -std $FSLDIR/data/standard/MNI152_T1_2mm_brain_mask --overlayType mask --alpha 50 --maskColour 1 0 0

The mask overlay appears fully opaque, despite requesting 50% transparency. Strangely, if I omit the the --maskColour flag then the mask appears at the requested transparency (just with the default white colour). Is setting the mask colour somehow overriding the transparency?

Is there something obvious I'm doing wrong here? Or if this is a bug, is there a workaround?

Thanks, David

pauldmccarthy commented 10 months ago

Hi @davidmwatson, unfortunately this is a bug - I should be able to fix it quickly, and hopefully get a new release out next week. In the meantime, one work around I can think of, if you are displaying binary masks, is to use the volume overlay type with an appropriate colour map, e.g.:

fsleyes -std $FSLDIR/data/standard/MNI152_T1_2mm_brain_mask --alpha 50 --cmap Red
davidmwatson commented 10 months ago

Okay, thanks for looking into this. I'll give the workaround a go in the meantime.

pauldmccarthy commented 9 months ago

FWIW this should be fixed in the latest version of FSLeyes (1.10.2)