Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Shapes not responding well to opacity slider #310

Open
jonathanlurie opened this issue Jun 23, 2016 · 1 comment
Open

Shapes not responding well to opacity slider #310

jonathanlurie opened this issue Jun 23, 2016 · 1 comment

Comments

@jonathanlurie
Copy link
Collaborator

This issue is actually more obvious on Bigbrain Surface Viewer (which shares almost the same core) since we tend to load a larger number of shapes.

In some situations, the opacity slider does not work and makes some shapes visible or totally hidden, partially transparent is not possible. For example, the shape 253-white cortical surface right from BigBrain experiences this issue.

After investigation, BrainBrowser core does not seem responsible for that and the problem seems to rather be on THREE.js side. I made a test using a recent version of THREE (rev 76) in BigBrain Surface Viewer and the shape 253-white cortical surface right now plays well with opacity but some other shapes do not anymore.

No matter which version of THREE, the shapes that don't play well with opacity seems masked (or partially masked) by another shape rather than completely invisible. I noticed that with a rotation, some parts of the invisible shapes become visible.

Here are the possibilities that come to my mind (other than THREE has a bug):

  • the mesh encoding (in the json file) could be responsible
  • the normal vector is in the wrong direction
  • a shape can be masked by an invisible shape
@jonathanlurie
Copy link
Collaborator Author

To illustrate the last point "a shape can be masked by an invisible shape" , here are some snaps where the green shape continues to hide the grey shape even though it is invisible. It is especially clear in the the last image where we can see the demarcation at which the grey shape is not visible anymore. This border matches exactly the position of the green shape.

1
2
3
4

Though, in some other cases, overlapping several shapes that are all partially transparent works just fine.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant