x3d output in ParaView
From Pat Crossno: Hi,
We’ve been working with George O**** on integrating an X3D viewer into Slycat. The sample data that George has sent us of his can crush problem has raised several questions about how to generate X3D output and how to get specific features included. In particular, we would like to know if the following outputs are possible, and if so, how do we specify that we want these outputs within the user interface? The output example file that George generated does not include them.
<Bullets deleted, as Utkarsh replicates them below>
Pat
Reply from Utkarsh:
-
Question 1 - How can we get each part to be written as a separate topology? In other X3D files that we can find on the internet, individual parts are defined independently, which enables us to turn them on and off in our viewer. In the Paraview generated file, all parts were combined into a single topology. (#17557 (closed))
-
Reply 1 - ParaView exporter indeed creates a single shape node for all blocks/parts in a composite dataset. The exporter will needed to be changed to add support for saving each block individually. It's been ages since I looked at the X3D exporter, but I suspect that should be doable. As a side, Pat, do you have an example X3D file with separate parts just for validation?
-
Question 2 - We would like to retain the parts names as tags so that we can present a parts list in our GUI.
-
Reply 2 - Okay. Again an example that demonstrates this would be great, but should be doable. I am assuming X3D supports this (forgive my lack of recollection). (done as part of #17557 (closed)).
-
Question 3 - We need some way to output a legend. Since this isn’t really a 3D object, we were wondering if an image with the legend might make more sense than outputting a colored cylinder (also, the text in the legend needs to be included, so if we went with a 3D geometry for the legend, how would we retain the text components)?
-
Reply 3 - How fancy do you want to get with this? Or would a cylinder with title and min and max labels suffice? If title + min + max labels would be sufficient, we can indeed do something like a textured/colored cylinder or with 3D text for title and end labels. It's still unclear how we decide where in 3D we want to place the legend and at what size, but we can figure that out.
-
Question 4 - We need some way to output any text and annotations that are in the Paraview application, preferably maintaining fonts and formatting.
-
Reply 4 - As far as I can tell, there's no support for 2D annotations in X3D. So this will get tricky especially since if we convert 2D text in overlay to 3D and plop it in the scene it may not appear identical. So long as that's acceptable (or there's support for 2D text and I am just not aware of it), should be doable.
Utkarsh