CapLek
(Oleh)
November 12, 2021, 10:06pm
1
Hi everyone,
In paraviewweb I need to output mesh and associated field data in the draco format. Known Python wrappers (actually, I’ve found only one so far, GitHub - seung-lab/DracoPy: Python wrapper for Google's Draco mesh compression library. ) do not support encoding of additional geometry attributes.
Basically, the idea is to create a C++ paraview plugin for filter which will use native C++ Draco API to output Draco encoded buffers. Then this plugin will be used by paraviewweb to forward compressed data further over the network.
So the question - is this possible and could theoretically work?
Thanks!
jourdain
(Sebastien Jourdain)
November 12, 2021, 10:59pm
2
It should be possible. But you will need to handle the
vtkPloyData => Draco ...network... Draco => vtkPolyData
The only unknown from my side is the draco API. But if you handle vtkDataArray => TypedArray
, you should be good with little remapping.
1 Like
CapLek
(Oleh)
November 15, 2021, 1:55pm
3
Sebastien, thank you for the help.
Could you please give another tip on how to declare a plugin method which is then can be called from pvpython?
jourdain
(Sebastien Jourdain)
November 17, 2021, 10:32pm
4
If your ParaView plugin have some vtk modules, those will be available in your python.
You can see it used here:
In that case it just expose some pre-existing code in VTK but you can see plugins with vtkModules in them as ref.