mirror of
https://gitlab.kitware.com/vtk/vtk-m
synced 2024-10-05 01:49:02 +00:00
Refer to field by name instead of index to fix crash in contour tree exmaple.
This commit is contained in:
parent
90706d53f8
commit
e598fd6351
@ -756,14 +756,13 @@ int main(int argc, char* argv[])
|
|||||||
//----Isovalue seleciton start
|
//----Isovalue seleciton start
|
||||||
if (numLevels > 0) // if compute isovalues
|
if (numLevels > 0) // if compute isovalues
|
||||||
{
|
{
|
||||||
// Get the data values for computing the explicit branch decomposition
|
// Get the data values for computing the explicit branch decomposition
|
||||||
#ifdef WITH_MPI
|
|
||||||
vtkm::cont::ArrayHandle<ValueType> dataField;
|
vtkm::cont::ArrayHandle<ValueType> dataField;
|
||||||
result.GetPartitions()[0].GetField(0).GetData().AsArrayHandle(dataField);
|
#ifdef WITH_MPI
|
||||||
|
result.GetPartitions()[0].GetField("values").GetData().AsArrayHandle(dataField);
|
||||||
bool dataFieldIsSorted = true;
|
bool dataFieldIsSorted = true;
|
||||||
#else
|
#else
|
||||||
vtkm::cont::ArrayHandle<ValueType> dataField;
|
useDataSet.GetField("values").GetData().AsArrayHandle(dataField);
|
||||||
useDataSet.GetField(0).GetData().AsArrayHandle(dataField);
|
|
||||||
bool dataFieldIsSorted = false;
|
bool dataFieldIsSorted = false;
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user