Multi Component Mapping doesn't work with Reflect Filter

Hi again, ParaView community!

I’m loving the Multi Component Mapping feature in ParaView, which lets me have a 2 component scalar field be visualized by mapping the first component to the color of the visualization, and the second component to the opacity of the visualization.

However, I also rely on the Reflect filter when visualizing my results, since I take advantage of symmetries in my domain. What I’ve found is that if I combine these 2 features when visualizing some results, the multi component mapping stops to work. I can’t see how this would be intentional, so I assume it’s a bug. I’m posting here just to get that confirmed and potentially get help in reporting this behavior.

A small test example:

# vtk DataFile Version 3.0
vtk output
ASCII
DATASET STRUCTURED_POINTS
DIMENSIONS 3 3 2
SPACING 1 1 1
ORIGIN 0 0 0

CELL_DATA 4
SCALARS scalars float 2
LOOKUP_TABLE default
0.4 0
0 0
0.4 1
0 1

Then I perform all the actions showed in the GIF below
paraview-reflect-multi-comp-BUG2

OS: Ubuntu 18.04.4
Paraview version: 5.8.0
Graphics: NVC1

What you see is actually a completely different issue.

The reflect filter make your initial image data into a unstructured grid.
For some reasons (bug?) volume rendering does not work well with your dataset as an UG.

To work around, you just need to use RessampleToImage after your reflect filter.

By the way, when using volume rendering, it is in general beneficial in terms of performance to use ressample to image if possible.

1 Like

Thank you, it is obviously a work around, but it works fine atm :slight_smile:

Btw, would it be beneficial to Resample To Image even for a data set on a structured grid as well?

Not really, no, only on Unstructured data.

https://gitlab.kitware.com/paraview/paraview/-/issues/20008