[bug 6973] adding a pipeline filter changes transparency

About the development of the FEM module/workbench.

Moderator: bernd

User avatar
uwestoehr
Veteran
Posts: 4961
Joined: Sun Jan 27, 2019 3:21 am
Location: Germany
Contact:

[bug 6973] adding a pipeline filter changes transparency

Post by uwestoehr »

I noticed a bug when adding a pipeline filter:

- set the transparency of a pipeline object to e.g. 75
- select this pipeline and add a filter of your choice
result: the transparency of the pipeline is lost

This bug only occurs if the pipeline shows no field yet (Field is "None").

This is a bit annoying because the transparency was set that one can see the new filter result immediately.
user1234
Veteran
Posts: 3319
Joined: Mon Jul 11, 2016 5:08 pm

Re: [bug 6973] adding a pipeline filter changes transparency

Post by user1234 »

For me, it is even worse. When i only add a little bit ( > 0 ) of transparency, the colorbar is invalid. When i reset it to 0, then it works again.

But when i add a transparency and add a filter on it, then i have to delete the filter and edit the pipeline and change the field or the mode, to get it work again.

Generally no (pipeline) transparency, even on filters, does work for me.


1.png
1.png (183.18 KiB) Viewed 1313 times

2.png
2.png (202.27 KiB) Viewed 1313 times


Greetings
user1234
User avatar
uwestoehr
Veteran
Posts: 4961
Joined: Sun Jan 27, 2019 3:21 am
Location: Germany
Contact:

Re: [bug 6973] adding a pipeline filter changes transparency

Post by uwestoehr »

user1234 wrote: Mon Jun 06, 2022 9:50 pm For me, it is even worse. When i only add a little bit ( > 0 ) of transparency, the colorbar is invalid. When i reset it to 0, then it works again.
Do you have an example file please?

I cannot reproduce this. I have VTK 8.2. What is your VTK version?
user1234
Veteran
Posts: 3319
Joined: Mon Jul 11, 2016 5:08 pm

Re: [bug 6973] adding a pipeline filter changes transparency

Post by user1234 »

uwestoehr wrote: Mon Jun 06, 2022 10:24 pm Do you have an example file please?
It is repeatable on the file on this post, https://forum.freecadweb.org/viewtopic. ... 7&#p600402.
uwestoehr wrote: Mon Jun 06, 2022 10:24 pm What is your VTK version?
vtk9.0.1, but can be also graphic card/driver related.

Greetings
user1234
User avatar
uwestoehr
Veteran
Posts: 4961
Joined: Sun Jan 27, 2019 3:21 am
Location: Germany
Contact:

Re: [bug 6973] adding a pipeline filter changes transparency

Post by uwestoehr »

user1234 wrote: Mon Jun 06, 2022 10:40 pm It is repeatable on the file on this post, https://forum.freecadweb.org/viewtopic. ... 7&#p600402.
I cannot reproduce. I don't see there the points as ion your screenshots. So what do i have to do (step by step?)

VTK 9.0.x is known to make problems, therefore we kept VTK 8.2 for the Windows LibPack. Bug VTK 9.1 is available since a while and you should upgrade to this.
user1234
Veteran
Posts: 3319
Joined: Mon Jul 11, 2016 5:08 pm

Re: [bug 6973] adding a pipeline filter changes transparency

Post by user1234 »

uwestoehr wrote: Mon Jun 06, 2022 11:53 pm I don't see there the points as ion your screenshots.
OK, i have expressed it very extremly inconsequent (colorbar --> color of the bar (beam)). I mean, that the color of the points gets incorrect.
uwestoehr wrote: Mon Jun 06, 2022 11:53 pm So what do i have to do (step by step?)
test.FCStd
(210.85 KiB) Downloaded 19 times

- open the file
- go the FEM wb

- either
- double click on (open) the ResultPipeline
- change the transparency > 0
- the result is that the color of the wireframe is incorrect
- click OK

- or
- click on the ResultPipeline
- go to the property view
- go on the tab view
- change the transparency > 0
- the result is that the color of the wireframe is incorrect

- then
- click on the ResultPipeline
- change the transparency to 0
- the result is that the color of the wireframe is correct

- then
- click on the ResultPipeline
- go to the property view
- go on the tab view
- change the transparency > 0
- the result is that the color of the wireframe is again incorrect

- then
- click on the ResultPipeline
- add any filter, here for example Region clip filter on the pipeline
- click in the task view of the filter on Create --> Plane (result does not matter)
- click OK
- hide the filter and planes (all under the ResultPipeline) for better overview
- double click on (open) the ResultPipeline
- change the transparency to 0
- the result is that the color of the wireframe is still incorrect, what is unexpected, because before correcting it to 0 solved the visual error

- to solve it
- easiest way is to set the transparency to 0 and then change the field (for example from Displacement to van Mises Stress), the order is not important, but both must be changed, even when the transparency was 0 before.


here a screencast:
1.webm
(723.61 KiB) Downloaded 23 times

version:

Code: Select all

OS: Debian GNU/Linux 11 (bullseye) (X-Cinnamon/lightdm-xsession)
Word size of FreeCAD: 64-bit
Version: 0.20.29055 (Git)
Build type: Release
Branch: master
Hash: b9b21ddac562f03cef162bb1f7feb4eea3de8b1e
Python 3.9.2, Qt 5.15.2, Coin 4.0.0, OCC 7.6.2
Locale: English/United States (en_US)
uwestoehr wrote: Mon Jun 06, 2022 11:53 pm VTK 9.0.x is known to make problems, therefore we kept VTK 8.2 for the Windows LibPack. Bug VTK 9.1 is available since a while and you should upgrade to this.
The problem in that case is, that on Debian there is no vtk8, only a vtk7.1.1 and vtk9.01 is still the newest one. And this can often take ages, till they update. Also afaik, there is a paraview vtk dependeny issue atm (not for me since i do not use paraview). Also on other system the updates can take longer.

And also FreeCAD works with vtk9 since a very short time ago, see https://forum.freecadweb.org/viewtopic. ... 28#p583828.


Greetings
user1234
User avatar
uwestoehr
Veteran
Posts: 4961
Joined: Sun Jan 27, 2019 3:21 am
Location: Germany
Contact:

Re: [bug 6973] adding a pipeline filter changes transparency

Post by uwestoehr »

user1234 wrote: Tue Jun 07, 2022 3:35 pm - the result is that the color of the wireframe is incorrect
Confirmed (VTK 8.2). Maybe @wmayer knows why since he recently fixed the transparency.

To reproduce the issue, one can just
- select any result pipeline
- change its transparency to e.g. "4"
- IMPORTANT: the Display Mode must be set to "nodes" or "wireframe". With the "Surface" display mode, the bug does not occur.
user1234
Veteran
Posts: 3319
Joined: Mon Jul 11, 2016 5:08 pm

Re: [bug 6973] adding a pipeline filter changes transparency

Post by user1234 »

uwestoehr wrote: Tue Jun 07, 2022 5:38 pm - IMPORTANT: the Display Mode must be set to "nodes" or "wireframe". With the "Surface" display mode, the bug does not occur.
Yes, this works. Sorry for not testing it, but i never use surface mode, since it is a little bit unpractical (for me, not in general).

Greetings
user1234
wmayer
Founder
Posts: 20241
Joined: Thu Feb 19, 2009 10:32 am
Contact:

Re: [bug 6973] adding a pipeline filter changes transparency

Post by wmayer »

user1234 wrote: Mon Jun 06, 2022 9:50 pm For me, it is even worse. When i only add a little bit ( > 0 ) of transparency, the colorbar is invalid. When i reset it to 0, then it works again.
Confirmed if Display Modes is set to Nodes. For Surface it works fine.

However, I don't think it's a FreeCAD but either a graphic driver issue or a limitation of Coin3D. For those who are interested in debugging the problem: Transparency is handled (or not :)) inside SoShape::shouldGLRender.
VTK 9.0.x is known to make problems, therefore we kept VTK 8.2 for the Windows LibPack. Bug VTK 9.1 is available since a while and you should upgrade to this.
We don't use vtk for rendering but only its algorithms. Because it's a pure rendering problem it's unlikely that it's related to the used vtk version.
User avatar
uwestoehr
Veteran
Posts: 4961
Joined: Sun Jan 27, 2019 3:21 am
Location: Germany
Contact:

Re: [bug 6973] adding a pipeline filter changes transparency

Post by uwestoehr »

wmayer wrote: Wed Jun 08, 2022 8:15 am However, I don't think it's a FreeCAD but either a graphic driver issue or a limitation of Coin3D. For those who are interested in debugging the problem: Transparency is handled (or not :)) inside SoShape::shouldGLRender.
Thanks for having a look!

I learned recently that the mode or representation is preferred for professional inspections of results. Therefore not providing transparencies in the nodes representation is a an issue.
However, the bug is also in FC 0.19.

I will report it later as issue that this is not forgotten.
Post Reply