question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Color map with alpha values disables interaction events

See original GitHub issue

In the recent example called slice-plane, the code works as expected. image

However, if you set a color map with alpha values, it doesn’t work anymore.

In my case, I created a color map with hundreds of opaque (alpha 1.0) rgb colors and only one transparent (alpha 0.0) color. Then I built a LUT with that color map. Setting this color map disables interaction events, even if pickable(True) is set.

I tried first setting a LUT with slice._mapper.SetLookupTable(lut) and then with vedo’s cmap slice.cmap(color_map, alpha=alpha_map).

Issue Analytics

  • State:closed
  • Created 3 years ago
  • Comments:7 (3 by maintainers)

github_iconTop GitHub Comments

1reaction
nantillecommented, Jan 13, 2021

Great fix for VTK 9, thank you! I feared that ForceOpaqueOn would also force black to opaque but it keeps transparency as desired. I suppose we can close this because there’s a way to fix the regression.

1reaction
nantillecommented, Jan 12, 2021

I confirm it works with vtk8, py37 and latest vedo (pip install -U git+https://github.com/marcomusy/vedo.git).

Screenshot 2021-01-12 at 14 54 48

Read more comments on GitHub >

github_iconTop Results From Across the Web

Use alpha channels, masks, and mattes in After Effects
Learn about alpha channels that contain transparency information, track mattes, traveling mattes, and feathering masks in After Effects.
Read more >
Albedo Color and Transparency - Unity - Manual
The alpha value of the Albedo colour controls the transparency level for the material. This only has an effect if the Rendering Mode...
Read more >
opacity - CSS: Cascading Style Sheets - MDN Web Docs
To change the opacity of a background only, use the background property with a color value that allows for an alpha channel. For...
Read more >
Visualization: GeoChart | Charts - Google Developers
A geochart is a map of a country, a continent, or a region with areas ... The region mode colors whole regions, such...
Read more >
Alpha Channel | 3ds Max 2021 - Autodesk Knowledge Network
Each channel has a particular intensity or value at each pixel. The intensity of each channel determines the color of the pixel.
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found