Is there a way to modify the error messages which are generated by Paraview or VTK?
For example paraview generates this error for one of the case:
ERROR: In vtkDemandDrivenPipeline.cxx, line 779
vtkCompositeDataPipeline (000001568B503EE0): Input for connection index 0 on input port index 0 for algorithm vtkExtractBlockUsingDataAssembly (0000015688B37020) is of type vtkPartitionedDataSet, but a vtkPartitionedDataSetCollection is required.
But I want to modify this error message
Messages are hardcoded in the source. The only way to modify is to edit / rebuild the sources.
I get that, I have built Paraview from source. But this error is in vtkDemandDrivenPipeline.cxx which is missing from my build files. This file is in VTK/Common/ExecutionModel in superbuild but not in paraview build.
VTK is a git submodule in the ParaView source code. So If you follow the official build instructions, you should be able to modify the
VTK/Common/ExecutionModel/vtkDemandDrivenPipeline.cxx and rebuild ParaView.
Out of curiosity, why do you want to change this error message?
I built it using these instructions. But the build folder has the object file of vtkDemandDrivenPipeline in
VTK\Common\ExecutionModel\CMakeFiles\CommonExecutionModel.dir and I can’t edit that.
In the build process I had to change the last command from ninja to ninja install. Because just using the ninja did not install the .cxx or .h files and I could not include the header files (e.g. #include <pqApplicationCore.h>) in my custom application
cmake -GNinja -DPARAVIEW_USE_PYTHON=ON -DPARAVIEW_USE_MPI=ON -DVTK_SMP_IMPLEMENTATION_TYPE=STDThread -DCMAKE_BUILD_TYPE=Release ..\pv
I am creating a custom application and this particular error which I shared occurs due to one of the action specific to my custom application and I want to show a different error message to my users which is more specific to my application.
This is a code from the VTK project. To change it, you should:
- have a fork of VTK, where to commit the desired modification
- have a fork of ParaView, where the VTK submodule should point to your own
- modify the superbuild to get the ParaView from your fork (and the correct commit)
Or, ParaView superbuild also allows to maintains some patches to apply on the different projects. For your case, this last one may be easier
Got it, thanks. Actually I am just trying to give an error to my user if there are overlapping points on which same function (using calculator) has been applied.
Another workaround (more ideal) would be if I can somehow see if (in the below screenshot) ExtractSelection2 has points on which Calculator1 (or the function “Result”) was applied or not.