I’m currently using this XML code to create an input with 3 elements:
default_values="0.0 0.0 0.0">
This works fine with 1, 2 or 3 elements, but fails with 4 or more elements. How can I solve this?
(I know that 4 elements should be possible because the Mandelbrot source has several inputs with multiple elements)
PS: i’m using PV 5.7.0
Thank in advance!
Please share the failing code.
Please, find in the attached file the XML file of a very basic programmable source that reproduces the problem: when “number_of_elements” is set to 4 (or larger), PV fails and close. Is there any way to create an input vector with 4 or more text boxes?
Thanks again !
TEST_DOUBLE_VECTOR_PROPERTY.xml (626 Bytes)
Here is a working one.
default_values="-1.75 -1.25 0.0 0.0"
<DoubleRangeDomain name="range" />
<Documentation>The four values of this property indicate (in order) the
components of C (real and imaginary) and the components of the initial
value, X (real and imaginary).</Documentation>
Thanks for your answer.
However, it fails when I include this script into my original script (PV crashes). After some research, I realized that the function that you have provided belongs to the class “vtkImageMandelbrotSource” (https://vtk.org/doc/nightly/html/classvtkImageMandelbrotSource.html) and it creates a Mandelbrot after execution. However, I’m trying to create a Python programmable source which requires the class “vtkPythonProgrammableFilter”. Do you know if there is an equivalent to “SetOriginCX” but valid for the vtkPythonProgrammableFilter class?
Thanks again !