early-access version 2853
This commit is contained in:
393
externals/vcpkg/ports/vtk/156fb524.patch
vendored
Executable file
393
externals/vcpkg/ports/vtk/156fb524.patch
vendored
Executable file
@@ -0,0 +1,393 @@
|
||||
diff --git a/Accelerators/Vtkm/Filters/CMakeLists.txt b/Accelerators/Vtkm/Filters/CMakeLists.txt
|
||||
index 14e84f1dd6e8b9da275045fe5d80868b2e52ad5a..3a41bc4d2bffca8c3df79da218443b90f8ceb7d3 100644
|
||||
--- a/Accelerators/Vtkm/Filters/CMakeLists.txt
|
||||
+++ b/Accelerators/Vtkm/Filters/CMakeLists.txt
|
||||
@@ -46,6 +46,10 @@ foreach (class IN LISTS impl_classes)
|
||||
list(APPEND headers "${class}.h")
|
||||
endforeach ()
|
||||
|
||||
+list(APPEND sources
|
||||
+ "vtkmClipInstantiationsWithField.cxx"
|
||||
+ "vtkmClipInstantiationsWithImplicitFunction.cxx")
|
||||
+
|
||||
configure_file(
|
||||
"${CMAKE_CURRENT_SOURCE_DIR}/vtkmConfigFilters.h.in"
|
||||
"${CMAKE_CURRENT_BINARY_DIR}/vtkmConfigFilters.h"
|
||||
diff --git a/Accelerators/Vtkm/Filters/vtkmClip.cxx b/Accelerators/Vtkm/Filters/vtkmClip.cxx
|
||||
index 0b1dc86d3bedd425d4846f524818a68ada052ce9..65fec3110ebb6522900cbc965c5298031921e1e4 100644
|
||||
--- a/Accelerators/Vtkm/Filters/vtkmClip.cxx
|
||||
+++ b/Accelerators/Vtkm/Filters/vtkmClip.cxx
|
||||
@@ -14,6 +14,7 @@
|
||||
=========================================================================*/
|
||||
|
||||
#include "vtkmClip.h"
|
||||
+#include "vtkmClipInternals.h"
|
||||
|
||||
#include "vtkCellIterator.h"
|
||||
#include "vtkDataArray.h"
|
||||
@@ -36,11 +37,9 @@
|
||||
|
||||
#include "vtkmFilterPolicy.h"
|
||||
|
||||
+#include <vtkm/cont/DataSet.h>
|
||||
#include <vtkm/cont/RuntimeDeviceTracker.h>
|
||||
|
||||
-#include <vtkm/filter/ClipWithField.h>
|
||||
-#include <vtkm/filter/ClipWithImplicitFunction.h>
|
||||
-
|
||||
#include <algorithm>
|
||||
|
||||
vtkStandardNewMacro(vtkmClip);
|
||||
@@ -50,19 +49,17 @@ void vtkmClip::PrintSelf(std::ostream& os, vtkIndent indent)
|
||||
{
|
||||
this->Superclass::PrintSelf(os, indent);
|
||||
|
||||
- os << indent << "ClipValue: " << this->ClipValue << "\n";
|
||||
+ os << indent << "ClipValue: " << this->GetClipValue() << "\n";
|
||||
os << indent << "ClipFunction: \n";
|
||||
- this->ClipFunction->PrintSelf(os, indent.GetNextIndent());
|
||||
- os << indent << "ComputeScalars: " << this->ComputeScalars << "\n";
|
||||
+ this->GetClipFunction()->PrintSelf(os, indent.GetNextIndent());
|
||||
+ os << indent << "ComputeScalars: " << this->GetComputeScalars() << "\n";
|
||||
}
|
||||
|
||||
//------------------------------------------------------------------------------
|
||||
vtkmClip::vtkmClip()
|
||||
- : ClipValue(0.)
|
||||
- , ComputeScalars(true)
|
||||
- , ClipFunction(nullptr)
|
||||
- , ClipFunctionConverter(new tovtkm::ImplicitFunctionConverter)
|
||||
+ : Internals(new vtkmClip::internals)
|
||||
{
|
||||
+ this->Internals->ClipFunctionConverter.reset(new tovtkm::ImplicitFunctionConverter());
|
||||
// Clip active point scalars by default
|
||||
this->SetInputArrayToProcess(
|
||||
0, 0, 0, vtkDataObject::FIELD_ASSOCIATION_POINTS, vtkDataSetAttributes::SCALARS);
|
||||
@@ -75,24 +72,54 @@ vtkmClip::~vtkmClip() = default;
|
||||
vtkMTimeType vtkmClip::GetMTime()
|
||||
{
|
||||
vtkMTimeType mTime = this->Superclass::GetMTime();
|
||||
- if (this->ClipFunction)
|
||||
+ if (this->GetClipFunction())
|
||||
{
|
||||
- mTime = std::max(mTime, this->ClipFunction->GetMTime());
|
||||
+ mTime = std::max(mTime, this->GetClipFunction()->GetMTime());
|
||||
}
|
||||
return mTime;
|
||||
}
|
||||
|
||||
+//------------------------------------------------------------------------------
|
||||
+double vtkmClip::GetClipValue()
|
||||
+{
|
||||
+ return this->Internals->ClipValue;
|
||||
+}
|
||||
+
|
||||
+//------------------------------------------------------------------------------
|
||||
+void vtkmClip::SetClipValue(double val)
|
||||
+{
|
||||
+ this->Internals->ClipValue = val;
|
||||
+}
|
||||
+
|
||||
+//------------------------------------------------------------------------------
|
||||
+bool vtkmClip::GetComputeScalars()
|
||||
+{
|
||||
+ return this->Internals->ComputeScalars;
|
||||
+}
|
||||
+
|
||||
+//------------------------------------------------------------------------------
|
||||
+void vtkmClip::SetComputeScalars(bool val)
|
||||
+{
|
||||
+ this->Internals->ComputeScalars = val;
|
||||
+}
|
||||
+
|
||||
//------------------------------------------------------------------------------
|
||||
void vtkmClip::SetClipFunction(vtkImplicitFunction* clipFunction)
|
||||
{
|
||||
- if (this->ClipFunction != clipFunction)
|
||||
+ if (this->GetClipFunction() != clipFunction)
|
||||
{
|
||||
- this->ClipFunction = clipFunction;
|
||||
- this->ClipFunctionConverter->Set(clipFunction);
|
||||
+ this->Internals->ClipFunction = clipFunction;
|
||||
+ this->Internals->ClipFunctionConverter->Set(clipFunction);
|
||||
this->Modified();
|
||||
}
|
||||
}
|
||||
|
||||
+//------------------------------------------------------------------------------
|
||||
+vtkImplicitFunction* vtkmClip::GetClipFunction()
|
||||
+{
|
||||
+ return this->Internals->ClipFunction;
|
||||
+}
|
||||
+
|
||||
//------------------------------------------------------------------------------
|
||||
int vtkmClip::RequestData(
|
||||
vtkInformation*, vtkInformationVector** inInfoVec, vtkInformationVector* outInfoVec)
|
||||
@@ -111,7 +138,7 @@ int vtkmClip::RequestData(
|
||||
// Find the scalar array:
|
||||
int assoc = this->GetInputArrayAssociation(0, inInfoVec);
|
||||
vtkDataArray* scalars = this->GetInputArrayToProcess(0, inInfoVec);
|
||||
- if (!this->ClipFunction &&
|
||||
+ if (!this->GetClipFunction() &&
|
||||
(assoc != vtkDataObject::FIELD_ASSOCIATION_POINTS || scalars == nullptr ||
|
||||
scalars->GetName() == nullptr || scalars->GetName()[0] == '\0'))
|
||||
{
|
||||
@@ -129,37 +156,18 @@ int vtkmClip::RequestData(
|
||||
{
|
||||
// Convert inputs to vtkm objects:
|
||||
auto fieldsFlag =
|
||||
- this->ComputeScalars ? tovtkm::FieldsFlag::PointsAndCells : tovtkm::FieldsFlag::None;
|
||||
+ this->GetComputeScalars() ? tovtkm::FieldsFlag::PointsAndCells : tovtkm::FieldsFlag::None;
|
||||
auto in = tovtkm::Convert(input, fieldsFlag);
|
||||
|
||||
// Run filter:
|
||||
vtkm::cont::DataSet result;
|
||||
- if (this->ClipFunction)
|
||||
+ if (this->GetClipFunction())
|
||||
{
|
||||
- vtkm::filter::ClipWithImplicitFunction functionFilter;
|
||||
- auto function = this->ClipFunctionConverter->Get();
|
||||
- if (function.GetValid())
|
||||
- {
|
||||
- functionFilter.SetImplicitFunction(function);
|
||||
- result = functionFilter.Execute(in);
|
||||
- }
|
||||
+ result = this->Internals->ExecuteClipWithImplicitFunction(in);
|
||||
}
|
||||
else
|
||||
{
|
||||
- vtkm::filter::ClipWithField fieldFilter;
|
||||
- if (!this->ComputeScalars)
|
||||
- {
|
||||
- // explicitly convert just the field we need
|
||||
- auto inField = tovtkm::Convert(scalars, assoc);
|
||||
- in.AddField(inField);
|
||||
- // don't pass this field
|
||||
- fieldFilter.SetFieldsToPass(
|
||||
- vtkm::filter::FieldSelection(vtkm::filter::FieldSelection::MODE_NONE));
|
||||
- }
|
||||
-
|
||||
- fieldFilter.SetActiveField(scalars->GetName(), vtkm::cont::Field::Association::POINTS);
|
||||
- fieldFilter.SetClipValue(this->ClipValue);
|
||||
- result = fieldFilter.Execute(in);
|
||||
+ result = this->Internals->ExecuteClipWithField(in, scalars, assoc);
|
||||
}
|
||||
|
||||
// Convert result to output:
|
||||
@@ -169,7 +177,7 @@ int vtkmClip::RequestData(
|
||||
return 0;
|
||||
}
|
||||
|
||||
- if (!this->ClipFunction && this->ComputeScalars)
|
||||
+ if (!this->GetClipFunction() && this->GetComputeScalars())
|
||||
{
|
||||
output->GetPointData()->SetActiveScalars(scalars->GetName());
|
||||
}
|
||||
@@ -189,8 +197,8 @@ int vtkmClip::RequestData(
|
||||
<< "Falling back to serial implementation.");
|
||||
|
||||
vtkNew<vtkTableBasedClipDataSet> filter;
|
||||
- filter->SetClipFunction(this->ClipFunction);
|
||||
- filter->SetValue(this->ClipValue);
|
||||
+ filter->SetClipFunction(this->GetClipFunction());
|
||||
+ filter->SetValue(this->GetClipValue());
|
||||
filter->SetInputData(input);
|
||||
filter->Update();
|
||||
output->ShallowCopy(filter->GetOutput());
|
||||
diff --git a/Accelerators/Vtkm/Filters/vtkmClip.h b/Accelerators/Vtkm/Filters/vtkmClip.h
|
||||
index edb3cebfadc9ebeddf3c5030716ba532c0e149fe..6f33d36460d72de340eb81bb321ee868d70e6b5b 100644
|
||||
--- a/Accelerators/Vtkm/Filters/vtkmClip.h
|
||||
+++ b/Accelerators/Vtkm/Filters/vtkmClip.h
|
||||
@@ -32,13 +32,6 @@
|
||||
|
||||
class vtkImplicitFunction;
|
||||
|
||||
-namespace tovtkm
|
||||
-{
|
||||
-
|
||||
-class ImplicitFunctionConverter;
|
||||
-
|
||||
-} // namespace tovtkm
|
||||
-
|
||||
class VTKACCELERATORSVTKMFILTERS_EXPORT vtkmClip : public vtkUnstructuredGridAlgorithm
|
||||
{
|
||||
public:
|
||||
@@ -50,15 +43,15 @@ public:
|
||||
* The scalar value to use when clipping the dataset. Values greater than
|
||||
* ClipValue are preserved in the output dataset. Default is 0.
|
||||
*/
|
||||
- vtkGetMacro(ClipValue, double);
|
||||
- vtkSetMacro(ClipValue, double);
|
||||
+ double GetClipValue();
|
||||
+ void SetClipValue(double);
|
||||
|
||||
/**
|
||||
* If true, all input point data arrays will be mapped onto the output
|
||||
* dataset. Default is true.
|
||||
*/
|
||||
- vtkGetMacro(ComputeScalars, bool);
|
||||
- vtkSetMacro(ComputeScalars, bool);
|
||||
+ bool GetComputeScalars();
|
||||
+ void SetComputeScalars(bool);
|
||||
|
||||
/**
|
||||
* Set the implicit function with which to perform the clipping. If set,
|
||||
@@ -66,7 +59,7 @@ public:
|
||||
* function.
|
||||
*/
|
||||
void SetClipFunction(vtkImplicitFunction*);
|
||||
- vtkGetObjectMacro(ClipFunction, vtkImplicitFunction);
|
||||
+ vtkImplicitFunction* GetClipFunction();
|
||||
|
||||
vtkMTimeType GetMTime() override;
|
||||
|
||||
@@ -87,17 +80,13 @@ protected:
|
||||
~vtkmClip() override;
|
||||
|
||||
int RequestData(vtkInformation*, vtkInformationVector**, vtkInformationVector*) override;
|
||||
-
|
||||
int FillInputPortInformation(int port, vtkInformation* info) override;
|
||||
|
||||
- double ClipValue;
|
||||
- bool ComputeScalars;
|
||||
-
|
||||
- vtkImplicitFunction* ClipFunction;
|
||||
- std::unique_ptr<tovtkm::ImplicitFunctionConverter> ClipFunctionConverter;
|
||||
-
|
||||
vtkTypeBool ForceVTKm = false;
|
||||
|
||||
+ struct internals;
|
||||
+ std::unique_ptr<internals> Internals;
|
||||
+
|
||||
private:
|
||||
vtkmClip(const vtkmClip&) = delete;
|
||||
void operator=(const vtkmClip&) = delete;
|
||||
diff --git a/Accelerators/Vtkm/Filters/vtkmClipInstantiationsWithField.cxx b/Accelerators/Vtkm/Filters/vtkmClipInstantiationsWithField.cxx
|
||||
new file mode 100644
|
||||
index 0000000000000000000000000000000000000000..e81b5cdab62a436ef09afac33ffa0599cb9dd2a8
|
||||
--- /dev/null
|
||||
+++ b/Accelerators/Vtkm/Filters/vtkmClipInstantiationsWithField.cxx
|
||||
@@ -0,0 +1,39 @@
|
||||
+/*=========================================================================
|
||||
+
|
||||
+ Program: Visualization Toolkit
|
||||
+ Module: vtkmClipInstantiationsWithField.cxx
|
||||
+
|
||||
+ Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen
|
||||
+ All rights reserved.
|
||||
+ See Copyright.txt or http://www.kitware.com/Copyright.htm for details.
|
||||
+
|
||||
+ This software is distributed WITHOUT ANY WARRANTY; without even
|
||||
+ the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
|
||||
+ PURPOSE. See the above copyright notice for more information.
|
||||
+
|
||||
+=========================================================================*/
|
||||
+
|
||||
+#include "vtkmClipInternals.h"
|
||||
+#include "vtkmlib/DataSetConverters.h"
|
||||
+
|
||||
+#include <vtkm/filter/ClipWithField.h>
|
||||
+
|
||||
+//------------------------------------------------------------------------------
|
||||
+vtkm::cont::DataSet vtkmClip::internals::ExecuteClipWithField(
|
||||
+ vtkm::cont::DataSet& in, vtkDataArray* scalars, int assoc)
|
||||
+{
|
||||
+ vtkm::filter::ClipWithField fieldFilter;
|
||||
+ if (!this->ComputeScalars)
|
||||
+ {
|
||||
+ // explicitly convert just the field we need
|
||||
+ auto inField = tovtkm::Convert(scalars, assoc);
|
||||
+ in.AddField(inField);
|
||||
+ // don't pass this field
|
||||
+ fieldFilter.SetFieldsToPass(
|
||||
+ vtkm::filter::FieldSelection(vtkm::filter::FieldSelection::MODE_NONE));
|
||||
+ }
|
||||
+
|
||||
+ fieldFilter.SetActiveField(scalars->GetName(), vtkm::cont::Field::Association::POINTS);
|
||||
+ fieldFilter.SetClipValue(this->ClipValue);
|
||||
+ return fieldFilter.Execute(in);
|
||||
+}
|
||||
diff --git a/Accelerators/Vtkm/Filters/vtkmClipInstantiationsWithImplicitFunction.cxx b/Accelerators/Vtkm/Filters/vtkmClipInstantiationsWithImplicitFunction.cxx
|
||||
new file mode 100644
|
||||
index 0000000000000000000000000000000000000000..04a637a92d487b019742bbf81884750c48ba105d
|
||||
--- /dev/null
|
||||
+++ b/Accelerators/Vtkm/Filters/vtkmClipInstantiationsWithImplicitFunction.cxx
|
||||
@@ -0,0 +1,35 @@
|
||||
+/*=========================================================================
|
||||
+
|
||||
+ Program: Visualization Toolkit
|
||||
+ Module: vtkmClipInstantiationsWithImplicitFunction.cxx
|
||||
+
|
||||
+ Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen
|
||||
+ All rights reserved.
|
||||
+ See Copyright.txt or http://www.kitware.com/Copyright.htm for details.
|
||||
+
|
||||
+ This software is distributed WITHOUT ANY WARRANTY; without even
|
||||
+ the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
|
||||
+ PURPOSE. See the above copyright notice for more information.
|
||||
+
|
||||
+=========================================================================*/
|
||||
+
|
||||
+#include "vtkmClipInternals.h"
|
||||
+#include "vtkmlib/DataSetConverters.h"
|
||||
+
|
||||
+#include <vtkm/filter/ClipWithImplicitFunction.h>
|
||||
+
|
||||
+//------------------------------------------------------------------------------
|
||||
+vtkm::cont::DataSet vtkmClip::internals::ExecuteClipWithImplicitFunction(vtkm::cont::DataSet& in)
|
||||
+{
|
||||
+ auto function = this->ClipFunctionConverter->Get();
|
||||
+
|
||||
+ vtkm::cont::DataSet result;
|
||||
+ if (function.GetValid())
|
||||
+ {
|
||||
+ vtkm::filter::ClipWithImplicitFunction functionFilter;
|
||||
+ functionFilter.SetImplicitFunction(function);
|
||||
+ result = functionFilter.Execute(in);
|
||||
+ }
|
||||
+
|
||||
+ return result;
|
||||
+}
|
||||
diff --git a/Accelerators/Vtkm/Filters/vtkmClipInternals.h b/Accelerators/Vtkm/Filters/vtkmClipInternals.h
|
||||
new file mode 100644
|
||||
index 0000000000000000000000000000000000000000..5384347bf9d48f04f5d2847753c92b64fc82346e
|
||||
--- /dev/null
|
||||
+++ b/Accelerators/Vtkm/Filters/vtkmClipInternals.h
|
||||
@@ -0,0 +1,37 @@
|
||||
+/*=========================================================================
|
||||
+
|
||||
+ Program: Visualization Toolkit
|
||||
+ Module: vtkmClipInternals.h
|
||||
+
|
||||
+ Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen
|
||||
+ All rights reserved.
|
||||
+ See Copyright.txt or http://www.kitware.com/Copyright.htm for details.
|
||||
+
|
||||
+ This software is distributed WITHOUT ANY WARRANTY; without even
|
||||
+ the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
|
||||
+ PURPOSE. See the above copyright notice for more information.
|
||||
+
|
||||
+=========================================================================*/
|
||||
+
|
||||
+#ifndef vtkmClipInternals_h
|
||||
+#define vtkmClipInternals_h
|
||||
+
|
||||
+#include "vtkDataArray.h"
|
||||
+#include "vtkmClip.h"
|
||||
+#include "vtkmlib/ImplicitFunctionConverter.h"
|
||||
+
|
||||
+#include <vtkm/cont/DataSet.h>
|
||||
+
|
||||
+struct vtkmClip::internals
|
||||
+{
|
||||
+ double ClipValue = .0;
|
||||
+ bool ComputeScalars = true;
|
||||
+
|
||||
+ vtkImplicitFunction* ClipFunction = nullptr;
|
||||
+ std::unique_ptr<tovtkm::ImplicitFunctionConverter> ClipFunctionConverter;
|
||||
+
|
||||
+ vtkm::cont::DataSet ExecuteClipWithImplicitFunction(vtkm::cont::DataSet&);
|
||||
+ vtkm::cont::DataSet ExecuteClipWithField(vtkm::cont::DataSet&, vtkDataArray*, int);
|
||||
+};
|
||||
+
|
||||
+#endif
|
||||
185
externals/vcpkg/ports/vtk/1f00a0c9.patch
vendored
Executable file
185
externals/vcpkg/ports/vtk/1f00a0c9.patch
vendored
Executable file
@@ -0,0 +1,185 @@
|
||||
diff --git a/Accelerators/Vtkm/DataModel/vtkmDataSet.cxx b/Accelerators/Vtkm/DataModel/vtkmDataSet.cxx
|
||||
index da8f2e6498c2a08165500fc458eb3c9c7dc0b7e6..147c3c6e175dbd342095805750bfc4fee81735dc 100644
|
||||
--- a/Accelerators/Vtkm/DataModel/vtkmDataSet.cxx
|
||||
+++ b/Accelerators/Vtkm/DataModel/vtkmDataSet.cxx
|
||||
@@ -265,7 +265,7 @@ vtkIdType vtkmDataSet::FindPoint(double x[3])
|
||||
std::lock_guard<std::mutex> lock(locator.lock);
|
||||
if (locator.buildTime < this->GetMTime())
|
||||
{
|
||||
- locator.control.reset(new vtkm::cont::PointLocatorUniformGrid);
|
||||
+ locator.control.reset(new vtkm::cont::PointLocatorSparseGrid);
|
||||
locator.control->SetCoordinates(this->Internals->Coordinates);
|
||||
locator.control->Update();
|
||||
locator.buildTime = this->GetMTime();
|
||||
diff --git a/Accelerators/Vtkm/DataModel/vtkmlib/DataSetConverters.cxx b/Accelerators/Vtkm/DataModel/vtkmlib/DataSetConverters.cxx
|
||||
index f311f90e17814a05d082a0df67108f242018bb69..7ecfa50e4aa9922987fd33f7b29eb1bf4be3577a 100644
|
||||
--- a/Accelerators/Vtkm/DataModel/vtkmlib/DataSetConverters.cxx
|
||||
+++ b/Accelerators/Vtkm/DataModel/vtkmlib/DataSetConverters.cxx
|
||||
@@ -240,11 +240,11 @@ bool Convert(const vtkm::cont::DataSet& vtkmOut, vtkRectilinearGrid* output, vtk
|
||||
auto coordsArray = vtkm::cont::Cast<coordType>(vtkmOut.GetCoordinateSystem().GetData());
|
||||
|
||||
vtkSmartPointer<vtkDataArray> xArray =
|
||||
- Convert(vtkm::cont::make_FieldPoint("xArray", coordsArray.GetStorage().GetFirstArray()));
|
||||
+ Convert(vtkm::cont::make_FieldPoint("xArray", coordsArray.GetFirstArray()));
|
||||
vtkSmartPointer<vtkDataArray> yArray =
|
||||
- Convert(vtkm::cont::make_FieldPoint("yArray", coordsArray.GetStorage().GetSecondArray()));
|
||||
+ Convert(vtkm::cont::make_FieldPoint("yArray", coordsArray.GetSecondArray()));
|
||||
vtkSmartPointer<vtkDataArray> zArray =
|
||||
- Convert(vtkm::cont::make_FieldPoint("zArray", coordsArray.GetStorage().GetThirdArray()));
|
||||
+ Convert(vtkm::cont::make_FieldPoint("zArray", coordsArray.GetThirdArray()));
|
||||
|
||||
if (!xArray || !yArray || !zArray)
|
||||
{
|
||||
diff --git a/Accelerators/Vtkm/Filters/vtkmAverageToCells.cxx b/Accelerators/Vtkm/Filters/vtkmAverageToCells.cxx
|
||||
index 334ec1219dd269e323ae11e61a5a68e9e6e3d2e7..ed9d58fe91713a12e7b2588471275e694f71f618 100644
|
||||
--- a/Accelerators/Vtkm/Filters/vtkmAverageToCells.cxx
|
||||
+++ b/Accelerators/Vtkm/Filters/vtkmAverageToCells.cxx
|
||||
@@ -27,7 +27,6 @@
|
||||
#include "vtkmFilterPolicy.h"
|
||||
|
||||
#include <vtkm/filter/CellAverage.h>
|
||||
-#include <vtkm/filter/CellAverage.hxx>
|
||||
|
||||
vtkStandardNewMacro(vtkmAverageToCells);
|
||||
|
||||
diff --git a/Accelerators/Vtkm/Filters/vtkmAverageToPoints.cxx b/Accelerators/Vtkm/Filters/vtkmAverageToPoints.cxx
|
||||
index 1003f88c4d4e1dcf0be24b7f9f4e6d58e4e735f0..00c722f3162ebb042fb3973bb28a3c1c2fb48c45 100644
|
||||
--- a/Accelerators/Vtkm/Filters/vtkmAverageToPoints.cxx
|
||||
+++ b/Accelerators/Vtkm/Filters/vtkmAverageToPoints.cxx
|
||||
@@ -28,7 +28,6 @@
|
||||
#include "vtkmFilterPolicy.h"
|
||||
|
||||
#include <vtkm/filter/PointAverage.h>
|
||||
-#include <vtkm/filter/PointAverage.hxx>
|
||||
|
||||
vtkStandardNewMacro(vtkmAverageToPoints);
|
||||
|
||||
diff --git a/Accelerators/Vtkm/Filters/vtkmCleanGrid.cxx b/Accelerators/Vtkm/Filters/vtkmCleanGrid.cxx
|
||||
index 98f0fdb70a296a8dd97df56f706f11e0aca20f32..0cfde7e99f8f07289b08310675ee16f438bc61be 100644
|
||||
--- a/Accelerators/Vtkm/Filters/vtkmCleanGrid.cxx
|
||||
+++ b/Accelerators/Vtkm/Filters/vtkmCleanGrid.cxx
|
||||
@@ -30,7 +30,6 @@
|
||||
#include "vtkmFilterPolicy.h"
|
||||
|
||||
#include <vtkm/filter/CleanGrid.h>
|
||||
-#include <vtkm/filter/CleanGrid.hxx>
|
||||
|
||||
vtkStandardNewMacro(vtkmCleanGrid);
|
||||
|
||||
diff --git a/Accelerators/Vtkm/Filters/vtkmClip.cxx b/Accelerators/Vtkm/Filters/vtkmClip.cxx
|
||||
index 2649b2da024310f58159574758d278318e23f4b9..0b1dc86d3bedd425d4846f524818a68ada052ce9 100644
|
||||
--- a/Accelerators/Vtkm/Filters/vtkmClip.cxx
|
||||
+++ b/Accelerators/Vtkm/Filters/vtkmClip.cxx
|
||||
@@ -39,9 +39,7 @@
|
||||
#include <vtkm/cont/RuntimeDeviceTracker.h>
|
||||
|
||||
#include <vtkm/filter/ClipWithField.h>
|
||||
-#include <vtkm/filter/ClipWithField.hxx>
|
||||
#include <vtkm/filter/ClipWithImplicitFunction.h>
|
||||
-#include <vtkm/filter/ClipWithImplicitFunction.hxx>
|
||||
|
||||
#include <algorithm>
|
||||
|
||||
diff --git a/Accelerators/Vtkm/Filters/vtkmContour.cxx b/Accelerators/Vtkm/Filters/vtkmContour.cxx
|
||||
index c9d35a544641a629ee4fb4f54c4d8245be8e6fd5..eae3a03398ffeef8b0f8ec449f89163f8c275122 100644
|
||||
--- a/Accelerators/Vtkm/Filters/vtkmContour.cxx
|
||||
+++ b/Accelerators/Vtkm/Filters/vtkmContour.cxx
|
||||
@@ -33,7 +33,6 @@
|
||||
|
||||
#include <vtkm/cont/RuntimeDeviceTracker.h>
|
||||
#include <vtkm/filter/Contour.h>
|
||||
-#include <vtkm/filter/Contour.hxx>
|
||||
|
||||
vtkStandardNewMacro(vtkmContour);
|
||||
|
||||
diff --git a/Accelerators/Vtkm/Filters/vtkmExternalFaces.cxx b/Accelerators/Vtkm/Filters/vtkmExternalFaces.cxx
|
||||
index 58969b5707aab56e6fcd6300ca650c9b2d88e32f..3661060164d738eb9055316fd6c0b023b09ef72f 100644
|
||||
--- a/Accelerators/Vtkm/Filters/vtkmExternalFaces.cxx
|
||||
+++ b/Accelerators/Vtkm/Filters/vtkmExternalFaces.cxx
|
||||
@@ -33,7 +33,6 @@
|
||||
#include "vtkmFilterPolicy.h"
|
||||
|
||||
#include <vtkm/filter/ExternalFaces.h>
|
||||
-#include <vtkm/filter/ExternalFaces.hxx>
|
||||
|
||||
vtkStandardNewMacro(vtkmExternalFaces);
|
||||
|
||||
diff --git a/Accelerators/Vtkm/Filters/vtkmExtractVOI.cxx b/Accelerators/Vtkm/Filters/vtkmExtractVOI.cxx
|
||||
index 3606f28de2229436afbcb8b0cf3ed61430055b8e..32bf94f630931a0d052cf5880d950df4588046cb 100644
|
||||
--- a/Accelerators/Vtkm/Filters/vtkmExtractVOI.cxx
|
||||
+++ b/Accelerators/Vtkm/Filters/vtkmExtractVOI.cxx
|
||||
@@ -27,7 +27,6 @@
|
||||
#include "vtkmFilterPolicy.h"
|
||||
|
||||
#include "vtkm/filter/ExtractStructured.h"
|
||||
-#include "vtkm/filter/ExtractStructured.hxx"
|
||||
|
||||
vtkStandardNewMacro(vtkmExtractVOI);
|
||||
|
||||
diff --git a/Accelerators/Vtkm/Filters/vtkmGradient.cxx b/Accelerators/Vtkm/Filters/vtkmGradient.cxx
|
||||
index 9b79c9e5a5e434ae810df73b51bc6bf52cefa829..6aa284878c88e2fcaf243f6721477536891f002f 100644
|
||||
--- a/Accelerators/Vtkm/Filters/vtkmGradient.cxx
|
||||
+++ b/Accelerators/Vtkm/Filters/vtkmGradient.cxx
|
||||
@@ -31,7 +31,6 @@
|
||||
|
||||
#include <vtkm/filter/Gradient.h>
|
||||
#include <vtkm/filter/PointAverage.h>
|
||||
-#include <vtkm/filter/PointAverage.hxx>
|
||||
|
||||
vtkStandardNewMacro(vtkmGradient);
|
||||
|
||||
diff --git a/Accelerators/Vtkm/Filters/vtkmHistogram.cxx b/Accelerators/Vtkm/Filters/vtkmHistogram.cxx
|
||||
index ed09a73d938997fe0dab1ae7eb4338f4914bad15..c13fd742477686e2dd51e95c4757628630788a77 100644
|
||||
--- a/Accelerators/Vtkm/Filters/vtkmHistogram.cxx
|
||||
+++ b/Accelerators/Vtkm/Filters/vtkmHistogram.cxx
|
||||
@@ -32,7 +32,6 @@
|
||||
#include "vtkSmartPointer.h"
|
||||
|
||||
#include "vtkmFilterPolicy.h"
|
||||
-#include <vtkm/cont/ArrayRangeCompute.hxx>
|
||||
#include <vtkm/filter/Histogram.h>
|
||||
|
||||
vtkStandardNewMacro(vtkmHistogram);
|
||||
diff --git a/Accelerators/Vtkm/Filters/vtkmLevelOfDetail.cxx b/Accelerators/Vtkm/Filters/vtkmLevelOfDetail.cxx
|
||||
index 04ccdce35f14b708c111302c759b5d328225cdef..db8d3f64b5e9b96f9b3e491f044056b14ae1bcdd 100644
|
||||
--- a/Accelerators/Vtkm/Filters/vtkmLevelOfDetail.cxx
|
||||
+++ b/Accelerators/Vtkm/Filters/vtkmLevelOfDetail.cxx
|
||||
@@ -33,7 +33,6 @@
|
||||
#include <vtkm/filter/VertexClustering.h>
|
||||
// To handle computing custom coordinate sets bounds we need to include
|
||||
// the following
|
||||
-#include <vtkm/cont/ArrayRangeCompute.hxx>
|
||||
|
||||
vtkStandardNewMacro(vtkmLevelOfDetail);
|
||||
|
||||
diff --git a/Accelerators/Vtkm/Filters/vtkmPointTransform.cxx b/Accelerators/Vtkm/Filters/vtkmPointTransform.cxx
|
||||
index 9906573f18312cb803e5ab2bce30218e4f95772c..685fb618764fc62969b5373cd922aaea7d1311e3 100644
|
||||
--- a/Accelerators/Vtkm/Filters/vtkmPointTransform.cxx
|
||||
+++ b/Accelerators/Vtkm/Filters/vtkmPointTransform.cxx
|
||||
@@ -33,7 +33,6 @@
|
||||
|
||||
#include "vtkm/cont/Error.h"
|
||||
#include "vtkm/filter/PointTransform.h"
|
||||
-#include "vtkm/filter/PointTransform.hxx"
|
||||
|
||||
#include "vtkmFilterPolicy.h"
|
||||
|
||||
diff --git a/Accelerators/Vtkm/Filters/vtkmThreshold.cxx b/Accelerators/Vtkm/Filters/vtkmThreshold.cxx
|
||||
index 7604acd333978a72b1e34584d14640e097b34292..647514050c42771cda57b439280d238de72911e2 100644
|
||||
--- a/Accelerators/Vtkm/Filters/vtkmThreshold.cxx
|
||||
+++ b/Accelerators/Vtkm/Filters/vtkmThreshold.cxx
|
||||
@@ -31,7 +31,6 @@
|
||||
#include "vtkmFilterPolicy.h"
|
||||
|
||||
#include <vtkm/filter/Threshold.h>
|
||||
-#include <vtkm/filter/Threshold.hxx>
|
||||
|
||||
vtkStandardNewMacro(vtkmThreshold);
|
||||
|
||||
diff --git a/ThirdParty/vtkm/vtkvtkm/vtk-m b/ThirdParty/vtkm/vtkvtkm/vtk-m
|
||||
index 0457427ed7b4d21e1a8e33e96713414ca11a42fc..ff7de5a72e917eac39f9a3c3a0002da5fa26c3f7 160000
|
||||
--- a/ThirdParty/vtkm/vtkvtkm/vtk-m
|
||||
+++ b/ThirdParty/vtkm/vtkvtkm/vtk-m
|
||||
@@ -1 +1 @@
|
||||
-Subproject commit 0457427ed7b4d21e1a8e33e96713414ca11a42fc
|
||||
+Subproject commit ff7de5a72e917eac39f9a3c3a0002da5fa26c3f7
|
||||
48
externals/vcpkg/ports/vtk/FindExpat.patch
vendored
Executable file
48
externals/vcpkg/ports/vtk/FindExpat.patch
vendored
Executable file
@@ -0,0 +1,48 @@
|
||||
diff --git a/CMake/FindEXPAT.cmake b/CMake/FindEXPAT.cmake
|
||||
index 45d923764..0ebcd3c83 100644
|
||||
--- a/CMake/FindEXPAT.cmake
|
||||
+++ b/CMake/FindEXPAT.cmake
|
||||
@@ -73,15 +73,37 @@ if(EXPAT_FOUND)
|
||||
|
||||
if(NOT TARGET EXPAT::EXPAT)
|
||||
include(vtkDetectLibraryType)
|
||||
- vtk_detect_library_type(expat_library_type
|
||||
- PATH "${EXPAT_LIBRARY}")
|
||||
+ if(EXPAT_LIBRARY_RELEASE)
|
||||
+ vtk_detect_library_type(expat_library_type
|
||||
+ PATH "${EXPAT_LIBRARY_RELEASE}")
|
||||
+ elseif(EXPAT_LIBRARY_DEBUG)
|
||||
+ vtk_detect_library_type(expat_library_type
|
||||
+ PATH "${EXPAT_LIBRARY_RELEASE}")
|
||||
+ else()
|
||||
+ vtk_detect_library_type(expat_library_type
|
||||
+ PATH "${EXPAT_LIBRARY}")
|
||||
+ endif()
|
||||
+
|
||||
add_library(EXPAT::EXPAT "${expat_library_type}" IMPORTED)
|
||||
unset(expat_library_type)
|
||||
set_target_properties(EXPAT::EXPAT PROPERTIES
|
||||
- IMPORTED_LINK_INTERFACE_LANGUAGES "C"
|
||||
- IMPORTED_LOCATION "${EXPAT_LIBRARY}"
|
||||
- IMPORTED_IMPLIB "${EXPAT_LIBRARY}"
|
||||
- INTERFACE_INCLUDE_DIRECTORIES "${EXPAT_INCLUDE_DIRS}")
|
||||
+ IMPORTED_LINK_INTERFACE_LANGUAGES "C"
|
||||
+ INTERFACE_INCLUDE_DIRECTORIES "${EXPAT_INCLUDE_DIRS}")
|
||||
+ if(EXPAT_LIBRARY_RELEASE)
|
||||
+ set_target_properties(EXPAT::EXPAT PROPERTIES
|
||||
+ IMPORTED_LOCATION_RELEASE "${EXPAT_LIBRARY_RELEASE}"
|
||||
+ IMPORTED_IMPLIB_RELEASE "${EXPAT_LIBRARY_RELEASE}")
|
||||
+ endif()
|
||||
+ if(EXPAT_LIBRARY_DEBUG)
|
||||
+ set_target_properties(EXPAT::EXPAT PROPERTIES
|
||||
+ IMPORTED_LOCATION_DEBUG "${EXPAT_LIBRARY_DEBUG}"
|
||||
+ IMPORTED_IMPLIB_DEBUG "${EXPAT_LIBRARY_DEBUG}")
|
||||
+ endif()
|
||||
+ if(EXPAT_LIBRARY_RELEASE OR EXPAT_LIBRARY_DEBUG AND NOT (EXPAT_LIBRARY_RELEASE AND EXPAT_LIBRARY_DEBUG))
|
||||
+ set_target_properties(EXPAT::EXPAT PROPERTIES
|
||||
+ IMPORTED_LOCATION "${EXPAT_LIBRARY}"
|
||||
+ IMPORTED_IMPLIB "${EXPAT_LIBRARY}")
|
||||
+ endif()
|
||||
endif()
|
||||
endif()
|
||||
|
||||
30
externals/vcpkg/ports/vtk/FindHDF5.cmake
vendored
Executable file
30
externals/vcpkg/ports/vtk/FindHDF5.cmake
vendored
Executable file
@@ -0,0 +1,30 @@
|
||||
find_package(hdf5 QUIET NO_MODULE)
|
||||
if(TARGET hdf5::hdf5-shared)
|
||||
set_target_properties(hdf5::hdf5-shared PROPERTIES IMPORTED_GLOBAL TRUE)
|
||||
if(NOT TARGET hdf5::hdf5)
|
||||
add_library(hdf5::hdf5 ALIAS hdf5::hdf5-shared)
|
||||
endif()
|
||||
elseif(TARGET hdf5::hdf5-static)
|
||||
set_target_properties(hdf5::hdf5-static PROPERTIES IMPORTED_GLOBAL TRUE)
|
||||
if(NOT TARGET hdf5::hdf5)
|
||||
add_library(hdf5::hdf5 ALIAS hdf5::hdf5-static)
|
||||
endif()
|
||||
else()
|
||||
message(FATAL_ERROR "HDF5 target not found")
|
||||
endif()
|
||||
if(TARGET hdf5::hdf5_hl-shared)
|
||||
set_target_properties(hdf5::hdf5_hl-shared PROPERTIES IMPORTED_GLOBAL TRUE)
|
||||
if(NOT TARGET hdf5::hdf5_hl)
|
||||
add_library(hdf5::hdf5_hl ALIAS hdf5::hdf5_hl-shared)
|
||||
endif()
|
||||
elseif(TARGET hdf5::hdf5_hl-static)
|
||||
set_target_properties(hdf5::hdf5_hl-static PROPERTIES IMPORTED_GLOBAL TRUE)
|
||||
if(NOT TARGET hdf5::hdf5_hl)
|
||||
add_library(hdf5::hdf5_hl ALIAS hdf5::hdf5_hl-static)
|
||||
endif()
|
||||
else()
|
||||
message(FATAL_ERROR "HDF5 HL target not found")
|
||||
endif()
|
||||
set(HDF5_IS_PARALLEL ${HDF5_ENABLE_PARALLEL} CACHE BOOL "" FORCE)
|
||||
set(HDF5_FOUND ON CACHE BOOL "" FORCE)
|
||||
set(hdf5_FOUND ON CACHE BOOL "" FORCE)
|
||||
49
externals/vcpkg/ports/vtk/FindLZ4.patch
vendored
Executable file
49
externals/vcpkg/ports/vtk/FindLZ4.patch
vendored
Executable file
@@ -0,0 +1,49 @@
|
||||
diff --git a/CMake/FindLZ4.cmake b/CMake/FindLZ4.cmake
|
||||
index 8c94e3bcd..ade3f9451 100644
|
||||
--- a/CMake/FindLZ4.cmake
|
||||
+++ b/CMake/FindLZ4.cmake
|
||||
@@ -1,38 +1,5 @@
|
||||
-find_path(LZ4_INCLUDE_DIR
|
||||
- NAMES lz4.h
|
||||
- DOC "lz4 include directory")
|
||||
-mark_as_advanced(LZ4_INCLUDE_DIR)
|
||||
-find_library(LZ4_LIBRARY
|
||||
- NAMES lz4 liblz4
|
||||
- DOC "lz4 library")
|
||||
-mark_as_advanced(LZ4_LIBRARY)
|
||||
-
|
||||
-if (LZ4_INCLUDE_DIR)
|
||||
- file(STRINGS "${LZ4_INCLUDE_DIR}/lz4.h" _lz4_version_lines
|
||||
- REGEX "#define[ \t]+LZ4_VERSION_(MAJOR|MINOR|RELEASE)")
|
||||
- string(REGEX REPLACE ".*LZ4_VERSION_MAJOR *\([0-9]*\).*" "\\1" _lz4_version_major "${_lz4_version_lines}")
|
||||
- string(REGEX REPLACE ".*LZ4_VERSION_MINOR *\([0-9]*\).*" "\\1" _lz4_version_minor "${_lz4_version_lines}")
|
||||
- string(REGEX REPLACE ".*LZ4_VERSION_RELEASE *\([0-9]*\).*" "\\1" _lz4_version_release "${_lz4_version_lines}")
|
||||
- set(LZ4_VERSION "${_lz4_version_major}.${_lz4_version_minor}.${_lz4_version_release}")
|
||||
- unset(_lz4_version_major)
|
||||
- unset(_lz4_version_minor)
|
||||
- unset(_lz4_version_release)
|
||||
- unset(_lz4_version_lines)
|
||||
-endif ()
|
||||
-
|
||||
-include(FindPackageHandleStandardArgs)
|
||||
-find_package_handle_standard_args(LZ4
|
||||
- REQUIRED_VARS LZ4_LIBRARY LZ4_INCLUDE_DIR
|
||||
- VERSION_VAR LZ4_VERSION)
|
||||
-
|
||||
-if (LZ4_FOUND)
|
||||
- set(LZ4_INCLUDE_DIRS "${LZ4_INCLUDE_DIR}")
|
||||
- set(LZ4_LIBRARIES "${LZ4_LIBRARY}")
|
||||
-
|
||||
- if (NOT TARGET LZ4::LZ4)
|
||||
- add_library(LZ4::LZ4 UNKNOWN IMPORTED)
|
||||
- set_target_properties(LZ4::LZ4 PROPERTIES
|
||||
- IMPORTED_LOCATION "${LZ4_LIBRARY}"
|
||||
- INTERFACE_INCLUDE_DIRECTORIES "${LZ4_INCLUDE_DIR}")
|
||||
- endif ()
|
||||
-endif ()
|
||||
+find_package(LZ4 CONFIG REQUIRED)
|
||||
+if(NOT TARGET LZ4::LZ4)
|
||||
+ add_library(LZ4::LZ4 INTERFACE IMPORTED)
|
||||
+ target_link_libraries(LZ4::LZ4 INTERFACE lz4::lz4)
|
||||
+endif()
|
||||
\ No newline at end of file
|
||||
16
externals/vcpkg/ports/vtk/FindLZMA.patch
vendored
Executable file
16
externals/vcpkg/ports/vtk/FindLZMA.patch
vendored
Executable file
@@ -0,0 +1,16 @@
|
||||
diff --git a/CMake/FindLZMA.cmake b/CMake/FindLZMA.cmake
|
||||
index 0c8c794..796558c 100644
|
||||
--- a/CMake/FindLZMA.cmake
|
||||
+++ b/CMake/FindLZMA.cmake
|
||||
@@ -1,3 +1,11 @@
|
||||
+find_package(LibLZMA)
|
||||
+set(LZMA_INCLUDE_DIR "${LIBLZMA_INCLUDE_DIR}" CACHE INTERNAL "")
|
||||
+set(LZMA_LIBRARY "${LIBLZMA_LIBRARIES}" CACHE INTERNAL "")
|
||||
+if(NOT TARGET LZMA::LZMA)
|
||||
+ add_library(LZMA::LZMA INTERFACE IMPORTED)
|
||||
+ target_link_libraries(LZMA::LZMA INTERFACE LibLZMA::LibLZMA)
|
||||
+endif()
|
||||
+
|
||||
find_path(LZMA_INCLUDE_DIR
|
||||
NAMES lzma.h
|
||||
DOC "lzma include directory")
|
||||
13
externals/vcpkg/ports/vtk/Findproj.patch
vendored
Executable file
13
externals/vcpkg/ports/vtk/Findproj.patch
vendored
Executable file
@@ -0,0 +1,13 @@
|
||||
diff --git a/CMake/FindLibPROJ.cmake b/CMake/FindLibPROJ.cmake
|
||||
index e2344bb17..bac4c747e 100644
|
||||
--- a/CMake/FindLibPROJ.cmake
|
||||
+++ b/CMake/FindLibPROJ.cmake
|
||||
@@ -9,7 +9,7 @@ find_library(LibPROJ_LIBRARY_RELEASE
|
||||
mark_as_advanced(LibPROJ_LIBRARY_RELEASE)
|
||||
|
||||
find_library(LibPROJ_LIBRARY_DEBUG
|
||||
- NAMES projd
|
||||
+ NAMES projd proj_d proj NAMES_PER_DIR
|
||||
DOC "libproj debug library")
|
||||
mark_as_advanced(LibPROJ_LIBRARY_DEBUG)
|
||||
|
||||
13
externals/vcpkg/ports/vtk/NoUndefDebug.patch
vendored
Executable file
13
externals/vcpkg/ports/vtk/NoUndefDebug.patch
vendored
Executable file
@@ -0,0 +1,13 @@
|
||||
diff --git a/Utilities/Python/vtkPython.h b/Utilities/Python/vtkPython.h
|
||||
index 166f24104..79ae1d371 100644
|
||||
--- a/Utilities/Python/vtkPython.h
|
||||
+++ b/Utilities/Python/vtkPython.h
|
||||
@@ -53,7 +53,7 @@
|
||||
#include <sys/stat.h>
|
||||
#include <time.h>
|
||||
#include <wchar.h>
|
||||
-#undef _DEBUG
|
||||
+
|
||||
#if defined(_MSC_VER)
|
||||
#define _CRT_NOFORCE_MANIFEST 1
|
||||
#endif
|
||||
149
externals/vcpkg/ports/vtk/UseProj5Api.patch
vendored
Executable file
149
externals/vcpkg/ports/vtk/UseProj5Api.patch
vendored
Executable file
@@ -0,0 +1,149 @@
|
||||
From 0325638832e35c8c8c6fc96e2c1d887aeea3dd43 Mon Sep 17 00:00:00 2001
|
||||
From: Julien Schueller <schueller@phimeca.com>
|
||||
Date: Mon, 8 Mar 2021 10:57:46 +0100
|
||||
Subject: [PATCH] Geovis: Use proj>=5 api
|
||||
|
||||
Closes #18130
|
||||
---
|
||||
Geovis/Core/vtkGeoProjection.cxx | 17 ++++++++++++++++-
|
||||
Geovis/Core/vtkGeoTransform.cxx | 28 ++++++++++++++--------------
|
||||
ThirdParty/libproj/vtk_libproj.h.in | 7 +------
|
||||
3 files changed, 31 insertions(+), 21 deletions(-)
|
||||
|
||||
diff --git a/Geovis/Core/vtkGeoProjection.cxx b/Geovis/Core/vtkGeoProjection.cxx
|
||||
index 7ff6526a5d..0a0d06eba1 100644
|
||||
--- a/Geovis/Core/vtkGeoProjection.cxx
|
||||
+++ b/Geovis/Core/vtkGeoProjection.cxx
|
||||
@@ -121,7 +121,11 @@ vtkGeoProjection::~vtkGeoProjection()
|
||||
this->SetPROJ4String(nullptr);
|
||||
if (this->Projection)
|
||||
{
|
||||
+#if PROJ_VERSION_MAJOR >= 5
|
||||
+ proj_destroy(this->Projection);
|
||||
+#else
|
||||
pj_free(this->Projection);
|
||||
+#endif
|
||||
}
|
||||
delete this->Internals;
|
||||
this->Internals = nullptr;
|
||||
@@ -185,13 +189,21 @@ int vtkGeoProjection::UpdateProjection()
|
||||
|
||||
if (this->Projection)
|
||||
{
|
||||
+#if PROJ_VERSION_MAJOR >= 5
|
||||
+ proj_destroy(this->Projection);
|
||||
+#else
|
||||
pj_free(this->Projection);
|
||||
+#endif
|
||||
this->Projection = nullptr;
|
||||
}
|
||||
|
||||
if (this->PROJ4String && strlen(this->PROJ4String))
|
||||
{
|
||||
+#if PROJ_VERSION_MAJOR >= 5
|
||||
+ this->Projection = proj_create(PJ_DEFAULT_CTX, this->PROJ4String);
|
||||
+#else
|
||||
this->Projection = pj_init_plus(this->PROJ4String);
|
||||
+#endif
|
||||
if (!this->Projection)
|
||||
{
|
||||
vtkErrorMacro("Cannot set projection with string " << this->PROJ4String);
|
||||
@@ -234,8 +246,11 @@ int vtkGeoProjection::UpdateProjection()
|
||||
stringHolder[i] = param.str();
|
||||
pjArgs[3 + i] = stringHolder[i].c_str();
|
||||
}
|
||||
-
|
||||
+#if PROJ_VERSION_MAJOR >= 5
|
||||
+ this->Projection = proj_create_argv(PJ_DEFAULT_CTX, argSize, const_cast<char**>(pjArgs));
|
||||
+#else
|
||||
this->Projection = pj_init(argSize, const_cast<char**>(pjArgs));
|
||||
+#endif
|
||||
delete[] pjArgs;
|
||||
}
|
||||
this->ProjectionMTime = this->GetMTime();
|
||||
diff --git a/Geovis/Core/vtkGeoTransform.cxx b/Geovis/Core/vtkGeoTransform.cxx
|
||||
index 5c2c74279d..1c99b6b11b 100644
|
||||
--- a/Geovis/Core/vtkGeoTransform.cxx
|
||||
+++ b/Geovis/Core/vtkGeoTransform.cxx
|
||||
@@ -163,8 +163,12 @@ void vtkGeoTransform::InternalTransformPoints(double* x, vtkIdType numPts, int s
|
||||
projPJ src = this->SourceProjection ? this->SourceProjection->GetProjection() : nullptr;
|
||||
projPJ dst = this->DestinationProjection ? this->DestinationProjection->GetProjection() : nullptr;
|
||||
int delta = stride - 2;
|
||||
+#if PROJ_VERSION_MAJOR >= 5
|
||||
+ PJ_COORD c, c_out;
|
||||
+#else
|
||||
projLP lp;
|
||||
projXY xy;
|
||||
+#endif
|
||||
if (src)
|
||||
{
|
||||
// Convert from src system to lat/long using inverse of src transform
|
||||
@@ -172,17 +176,15 @@ void vtkGeoTransform::InternalTransformPoints(double* x, vtkIdType numPts, int s
|
||||
for (vtkIdType i = 0; i < numPts; ++i)
|
||||
{
|
||||
#if PROJ_VERSION_MAJOR >= 5
|
||||
- xy.x = coord[0];
|
||||
- xy.y = coord[1];
|
||||
+ c.xy.x = coord[0];
|
||||
+ c.xy.y = coord[1];
|
||||
+ c_out = proj_trans(src, PJ_INV, c);
|
||||
+ coord[0] = c_out.lp.lam;
|
||||
+ coord[1] = c_out.lp.phi;
|
||||
#else
|
||||
xy.u = coord[0];
|
||||
xy.v = coord[1];
|
||||
-#endif
|
||||
lp = pj_inv(xy, src);
|
||||
-#if PROJ_VERSION_MAJOR >= 5
|
||||
- coord[0] = lp.lam;
|
||||
- coord[1] = lp.phi;
|
||||
-#else
|
||||
coord[0] = lp.u;
|
||||
coord[1] = lp.v;
|
||||
#endif
|
||||
@@ -208,17 +210,15 @@ void vtkGeoTransform::InternalTransformPoints(double* x, vtkIdType numPts, int s
|
||||
for (vtkIdType i = 0; i < numPts; ++i)
|
||||
{
|
||||
#if PROJ_VERSION_MAJOR >= 5
|
||||
- lp.lam = coord[0];
|
||||
- lp.phi = coord[1];
|
||||
+ c.lp.lam = coord[0];
|
||||
+ c.lp.phi = coord[1];
|
||||
+ c_out = proj_trans(src, PJ_FWD, c);
|
||||
+ coord[0] = c_out.xy.x;
|
||||
+ coord[1] = c_out.xy.y;
|
||||
#else
|
||||
lp.u = coord[0];
|
||||
lp.v = coord[1];
|
||||
-#endif
|
||||
xy = pj_fwd(lp, dst);
|
||||
-#if PROJ_VERSION_MAJOR >= 5
|
||||
- coord[0] = xy.x;
|
||||
- coord[1] = xy.y;
|
||||
-#else
|
||||
coord[0] = xy.u;
|
||||
coord[1] = xy.v;
|
||||
#endif
|
||||
diff --git a/ThirdParty/libproj/vtk_libproj.h.in b/ThirdParty/libproj/vtk_libproj.h.in
|
||||
index 4d8ffc3c5d..c4182c4db2 100644
|
||||
--- a/ThirdParty/libproj/vtk_libproj.h.in
|
||||
+++ b/ThirdParty/libproj/vtk_libproj.h.in
|
||||
@@ -28,14 +28,9 @@
|
||||
#if VTK_MODULE_USE_EXTERNAL_vtklibproj
|
||||
# if VTK_LibPROJ_MAJOR_VERSION >= 5
|
||||
# include <proj.h>
|
||||
-# endif
|
||||
-# if VTK_LibPROJ_MAJOR_VERSION < 6
|
||||
+# else
|
||||
# include <projects.h>
|
||||
# endif
|
||||
-# if VTK_LibPROJ_MAJOR_VERSION >= 6
|
||||
-# define ACCEPT_USE_OF_DEPRECATED_PROJ_API_H 1
|
||||
-# endif
|
||||
-# include <proj_api.h>
|
||||
# include <geodesic.h>
|
||||
#else
|
||||
# include <vtklibproj/src/projects.h>
|
||||
--
|
||||
2.32.0.windows.1
|
||||
|
||||
291
externals/vcpkg/ports/vtk/d107698a.patch
vendored
Executable file
291
externals/vcpkg/ports/vtk/d107698a.patch
vendored
Executable file
@@ -0,0 +1,291 @@
|
||||
diff --git a/Accelerators/Vtkm/Core/vtkmlib/DataArrayConverters.h b/Accelerators/Vtkm/Core/vtkmlib/DataArrayConverters.h
|
||||
index 0b3f1a963063cdf5f1685dbde55deaaea7a77d2f..24198dada846d6d81fb9f1c155e5a6612e1e7055 100644
|
||||
--- a/Accelerators/Vtkm/Core/vtkmlib/DataArrayConverters.h
|
||||
+++ b/Accelerators/Vtkm/Core/vtkmlib/DataArrayConverters.h
|
||||
@@ -25,6 +25,7 @@
|
||||
|
||||
#include <vtkm/cont/ArrayHandleSOA.h>
|
||||
#include <vtkm/cont/Field.h>
|
||||
+#include <vtkm/cont/VariantArrayHandle.h>
|
||||
|
||||
#include <type_traits> // for std::underlying_type
|
||||
|
||||
diff --git a/Accelerators/Vtkm/DataModel/Testing/Cxx/TestVTKMDataSet.cxx b/Accelerators/Vtkm/DataModel/Testing/Cxx/TestVTKMDataSet.cxx
|
||||
index ec41b18b60db354a8c4a1532eb5cedfd70ce7534..2493ae5b03cf29c5dfc90614489a8049fc623715 100644
|
||||
--- a/Accelerators/Vtkm/DataModel/Testing/Cxx/TestVTKMDataSet.cxx
|
||||
+++ b/Accelerators/Vtkm/DataModel/Testing/Cxx/TestVTKMDataSet.cxx
|
||||
@@ -274,18 +274,19 @@ vtkm::cont::testing::MakeTestDataSet Maker;
|
||||
void TestUniformDataSet()
|
||||
{
|
||||
auto dataset = Maker.Make3DUniformDataSet0();
|
||||
- auto coords =
|
||||
- dataset.GetCoordinateSystem().GetData().Cast<vtkm::cont::ArrayHandleUniformPointCoordinates>();
|
||||
+ auto coords = dataset.GetCoordinateSystem()
|
||||
+ .GetData()
|
||||
+ .AsArrayHandle<vtkm::cont::ArrayHandleUniformPointCoordinates>();
|
||||
auto portal = coords.ReadPortal();
|
||||
auto dims = portal.GetDimensions();
|
||||
auto origin = portal.GetOrigin();
|
||||
auto spacing = portal.GetSpacing();
|
||||
|
||||
vtkNew<vtkFloatArray> pointField, cellField;
|
||||
- FieldCopy(dataset.GetField("pointvar").GetData().Cast<vtkm::cont::ArrayHandle<float>>(),
|
||||
+ FieldCopy(dataset.GetField("pointvar").GetData().AsArrayHandle<vtkm::cont::ArrayHandle<float>>(),
|
||||
"pointvar", pointField);
|
||||
- FieldCopy(dataset.GetField("cellvar").GetData().Cast<vtkm::cont::ArrayHandle<float>>(), "cellvar",
|
||||
- cellField);
|
||||
+ FieldCopy(dataset.GetField("cellvar").GetData().AsArrayHandle<vtkm::cont::ArrayHandle<float>>(),
|
||||
+ "cellvar", cellField);
|
||||
|
||||
vtkNew<vtkImageData> imageData;
|
||||
imageData->SetDimensions(dims[0], dims[1], dims[2]);
|
||||
@@ -315,10 +316,10 @@ void TestCurvilinearDataSet()
|
||||
CoordsCopy(dataset.GetCoordinateSystem(), points);
|
||||
|
||||
vtkNew<vtkFloatArray> pointField, cellField;
|
||||
- FieldCopy(dataset.GetField("pointvar").GetData().Cast<vtkm::cont::ArrayHandle<float>>(),
|
||||
+ FieldCopy(dataset.GetField("pointvar").GetData().AsArrayHandle<vtkm::cont::ArrayHandle<float>>(),
|
||||
"pointvar", pointField);
|
||||
- FieldCopy(dataset.GetField("cellvar").GetData().Cast<vtkm::cont::ArrayHandle<float>>(), "cellvar",
|
||||
- cellField);
|
||||
+ FieldCopy(dataset.GetField("cellvar").GetData().AsArrayHandle<vtkm::cont::ArrayHandle<float>>(),
|
||||
+ "cellvar", cellField);
|
||||
|
||||
vtkNew<vtkStructuredGrid> dsVtk;
|
||||
dsVtk->SetDimensions(dims[0], dims[1], dims[2]);
|
||||
@@ -357,10 +358,10 @@ void TestExplicitDataSet()
|
||||
}
|
||||
|
||||
vtkNew<vtkFloatArray> pointField, cellField;
|
||||
- FieldCopy(dataset.GetField("pointvar").GetData().Cast<vtkm::cont::ArrayHandle<float>>(),
|
||||
+ FieldCopy(dataset.GetField("pointvar").GetData().AsArrayHandle<vtkm::cont::ArrayHandle<float>>(),
|
||||
"pointvar", pointField);
|
||||
- FieldCopy(dataset.GetField("cellvar").GetData().Cast<vtkm::cont::ArrayHandle<float>>(), "cellvar",
|
||||
- cellField);
|
||||
+ FieldCopy(dataset.GetField("cellvar").GetData().AsArrayHandle<vtkm::cont::ArrayHandle<float>>(),
|
||||
+ "cellvar", cellField);
|
||||
|
||||
vtkNew<vtkUnstructuredGrid> dsVtk;
|
||||
dsVtk->SetPoints(points);
|
||||
diff --git a/Accelerators/Vtkm/DataModel/vtkmDataSet.cxx b/Accelerators/Vtkm/DataModel/vtkmDataSet.cxx
|
||||
index 147c3c6e175dbd342095805750bfc4fee81735dc..f1ef72ffae91ca843ca56bdc305ab68bbc955157 100644
|
||||
--- a/Accelerators/Vtkm/DataModel/vtkmDataSet.cxx
|
||||
+++ b/Accelerators/Vtkm/DataModel/vtkmDataSet.cxx
|
||||
@@ -35,8 +35,7 @@
|
||||
#include <vtkm/cont/CellLocatorGeneral.h>
|
||||
#include <vtkm/cont/DataSet.h>
|
||||
#include <vtkm/cont/Invoker.h>
|
||||
-#include <vtkm/cont/PointLocator.h>
|
||||
-#include <vtkm/cont/PointLocatorUniformGrid.h>
|
||||
+#include <vtkm/cont/PointLocatorSparseGrid.h>
|
||||
#include <vtkm/worklet/ScatterPermutation.h>
|
||||
|
||||
#include <mutex>
|
||||
@@ -62,8 +61,8 @@ struct vtkmDataSet::DataMembers
|
||||
vtkm::cont::CoordinateSystem Coordinates;
|
||||
vtkNew<vtkGenericCell> Cell;
|
||||
|
||||
- VtkmLocator<vtkm::cont::PointLocator> PointLocator;
|
||||
- VtkmLocator<vtkm::cont::CellLocator> CellLocator;
|
||||
+ VtkmLocator<vtkm::cont::PointLocatorSparseGrid> PointLocator;
|
||||
+ VtkmLocator<vtkm::cont::CellLocatorGeneral> CellLocator;
|
||||
};
|
||||
|
||||
//------------------------------------------------------------------------------
|
||||
@@ -172,7 +171,7 @@ void vtkmDataSet::GetCellBounds(vtkIdType cellId, double bounds[6])
|
||||
this->Internals->CellSet.IsType<vtkm::cont::CellSetStructured<3>>())
|
||||
{
|
||||
auto portal = this->Internals->Coordinates.GetData()
|
||||
- .Cast<vtkm::cont::ArrayHandleUniformPointCoordinates>()
|
||||
+ .AsArrayHandle<vtkm::cont::ArrayHandleUniformPointCoordinates>()
|
||||
.ReadPortal();
|
||||
|
||||
vtkm::internal::ConnectivityStructuredInternals<3> helper;
|
||||
@@ -279,7 +278,7 @@ vtkIdType vtkmDataSet::FindPoint(double x[3])
|
||||
vtkm::Id pointId = -1;
|
||||
vtkm::FloatDefault d2 = 0;
|
||||
// exec object created for the Serial device can be called directly
|
||||
- execLocator->FindNearestNeighbor(point, pointId, d2);
|
||||
+ execLocator.FindNearestNeighbor(point, pointId, d2);
|
||||
return pointId;
|
||||
}
|
||||
|
||||
@@ -316,7 +315,7 @@ vtkIdType vtkmDataSet::FindCell(double x[3], vtkCell*, vtkGenericCell*, vtkIdTyp
|
||||
vtkm::Vec<vtkm::FloatDefault, 3> pc;
|
||||
vtkm::Id cellId = -1;
|
||||
// exec object created for the Serial device can be called directly
|
||||
- execLocator->FindCell(point, cellId, pc);
|
||||
+ execLocator.FindCell(point, cellId, pc);
|
||||
|
||||
if (cellId >= 0)
|
||||
{
|
||||
diff --git a/Accelerators/Vtkm/DataModel/vtkmlib/ImageDataConverter.cxx b/Accelerators/Vtkm/DataModel/vtkmlib/ImageDataConverter.cxx
|
||||
index 351c0d5ce169cf455d2d3c0a1307ba8e60510371..c7ecff3c9fc5eafecb9dd11d9dbea15cbd44bd3d 100644
|
||||
--- a/Accelerators/Vtkm/DataModel/vtkmlib/ImageDataConverter.cxx
|
||||
+++ b/Accelerators/Vtkm/DataModel/vtkmlib/ImageDataConverter.cxx
|
||||
@@ -121,7 +121,7 @@ bool Convert(
|
||||
return false;
|
||||
}
|
||||
|
||||
- auto points = cs.GetData().Cast<vtkm::cont::ArrayHandleUniformPointCoordinates>();
|
||||
+ auto points = cs.GetData().AsArrayHandle<vtkm::cont::ArrayHandleUniformPointCoordinates>();
|
||||
auto portal = points.ReadPortal();
|
||||
|
||||
auto origin = portal.GetOrigin();
|
||||
@@ -156,7 +156,7 @@ bool Convert(const vtkm::cont::DataSet& voutput, vtkImageData* output, vtkDataSe
|
||||
return false;
|
||||
}
|
||||
|
||||
- auto points = cs.GetData().Cast<vtkm::cont::ArrayHandleUniformPointCoordinates>();
|
||||
+ auto points = cs.GetData().AsArrayHandle<vtkm::cont::ArrayHandleUniformPointCoordinates>();
|
||||
auto portal = points.ReadPortal();
|
||||
|
||||
auto dim = portal.GetDimensions();
|
||||
diff --git a/Accelerators/Vtkm/DataModel/vtkmlib/ImplicitFunctionConverter.cxx b/Accelerators/Vtkm/DataModel/vtkmlib/ImplicitFunctionConverter.cxx
|
||||
index f2411d0e70505435cd312ee23b3cb2e653eb28d8..814af43cc168b4c3b44107b0c19e68cc1b42538d 100644
|
||||
--- a/Accelerators/Vtkm/DataModel/vtkmlib/ImplicitFunctionConverter.cxx
|
||||
+++ b/Accelerators/Vtkm/DataModel/vtkmlib/ImplicitFunctionConverter.cxx
|
||||
@@ -52,8 +52,7 @@ void ImplicitFunctionConverter::Set(vtkImplicitFunction* function)
|
||||
box->GetXMin(xmin);
|
||||
box->GetXMax(xmax);
|
||||
|
||||
- auto b = new vtkm::Box(MakeFVec3(xmin), MakeFVec3(xmax));
|
||||
- this->OutFunction.Reset(b, true);
|
||||
+ this->OutFunction = vtkm::Box(MakeFVec3(xmin), MakeFVec3(xmax));
|
||||
}
|
||||
else if ((cylinder = vtkCylinder::SafeDownCast(function)))
|
||||
{
|
||||
@@ -62,9 +61,8 @@ void ImplicitFunctionConverter::Set(vtkImplicitFunction* function)
|
||||
cylinder->GetAxis(axis);
|
||||
radius = cylinder->GetRadius();
|
||||
|
||||
- auto c = new vtkm::Cylinder(
|
||||
- MakeFVec3(center), MakeFVec3(axis), static_cast<vtkm::FloatDefault>(radius));
|
||||
- this->OutFunction.Reset(c, true);
|
||||
+ this->OutFunction =
|
||||
+ vtkm::Cylinder(MakeFVec3(center), MakeFVec3(axis), static_cast<vtkm::FloatDefault>(radius));
|
||||
}
|
||||
else if ((plane = vtkPlane::SafeDownCast(function)))
|
||||
{
|
||||
@@ -72,8 +70,7 @@ void ImplicitFunctionConverter::Set(vtkImplicitFunction* function)
|
||||
plane->GetOrigin(origin);
|
||||
plane->GetNormal(normal);
|
||||
|
||||
- auto p = new vtkm::Plane(MakeFVec3(origin), MakeFVec3(normal));
|
||||
- this->OutFunction.Reset(p, true);
|
||||
+ this->OutFunction = vtkm::Plane(MakeFVec3(origin), MakeFVec3(normal));
|
||||
}
|
||||
else if ((sphere = vtkSphere::SafeDownCast(function)))
|
||||
{
|
||||
@@ -81,8 +78,7 @@ void ImplicitFunctionConverter::Set(vtkImplicitFunction* function)
|
||||
sphere->GetCenter(center);
|
||||
radius = sphere->GetRadius();
|
||||
|
||||
- auto s = new vtkm::Sphere(MakeFVec3(center), static_cast<vtkm::FloatDefault>(radius));
|
||||
- this->OutFunction.Reset(s, true);
|
||||
+ this->OutFunction = vtkm::Sphere(MakeFVec3(center), static_cast<vtkm::FloatDefault>(radius));
|
||||
}
|
||||
else
|
||||
{
|
||||
@@ -95,7 +91,7 @@ void ImplicitFunctionConverter::Set(vtkImplicitFunction* function)
|
||||
this->InFunction = function;
|
||||
}
|
||||
|
||||
-const vtkm::cont::ImplicitFunctionHandle& ImplicitFunctionConverter::Get() const
|
||||
+const vtkm::ImplicitFunctionGeneral& ImplicitFunctionConverter::Get()
|
||||
{
|
||||
if (this->InFunction && (this->MTime < this->InFunction->GetMTime()))
|
||||
{
|
||||
@@ -110,9 +106,7 @@ const vtkm::cont::ImplicitFunctionHandle& ImplicitFunctionConverter::Get() const
|
||||
box->GetXMin(xmin);
|
||||
box->GetXMax(xmax);
|
||||
|
||||
- auto b = static_cast<vtkm::Box*>(this->OutFunction.Get());
|
||||
- b->SetMinPoint(MakeFVec3(xmin));
|
||||
- b->SetMaxPoint(MakeFVec3(xmax));
|
||||
+ this->OutFunction = vtkm::Box(MakeFVec3(xmin), MakeFVec3(xmax));
|
||||
}
|
||||
else if ((cylinder = vtkCylinder::SafeDownCast(this->InFunction)))
|
||||
{
|
||||
@@ -121,10 +115,8 @@ const vtkm::cont::ImplicitFunctionHandle& ImplicitFunctionConverter::Get() const
|
||||
cylinder->GetAxis(axis);
|
||||
radius = cylinder->GetRadius();
|
||||
|
||||
- auto c = static_cast<vtkm::Cylinder*>(this->OutFunction.Get());
|
||||
- c->SetCenter(MakeFVec3(center));
|
||||
- c->SetAxis(MakeFVec3(axis));
|
||||
- c->SetRadius(static_cast<vtkm::FloatDefault>(radius));
|
||||
+ this->OutFunction =
|
||||
+ vtkm::Cylinder(MakeFVec3(center), MakeFVec3(axis), static_cast<vtkm::FloatDefault>(radius));
|
||||
}
|
||||
else if ((plane = vtkPlane::SafeDownCast(this->InFunction)))
|
||||
{
|
||||
@@ -132,9 +124,7 @@ const vtkm::cont::ImplicitFunctionHandle& ImplicitFunctionConverter::Get() const
|
||||
plane->GetOrigin(origin);
|
||||
plane->GetNormal(normal);
|
||||
|
||||
- auto p = static_cast<vtkm::Plane*>(this->OutFunction.Get());
|
||||
- p->SetOrigin(MakeFVec3(origin));
|
||||
- p->SetNormal(MakeFVec3(normal));
|
||||
+ this->OutFunction = vtkm::Plane(MakeFVec3(origin), MakeFVec3(normal));
|
||||
}
|
||||
else if ((sphere = vtkSphere::SafeDownCast(this->InFunction)))
|
||||
{
|
||||
@@ -142,9 +132,7 @@ const vtkm::cont::ImplicitFunctionHandle& ImplicitFunctionConverter::Get() const
|
||||
sphere->GetCenter(center);
|
||||
radius = sphere->GetRadius();
|
||||
|
||||
- auto s = static_cast<vtkm::Sphere*>(this->OutFunction.Get());
|
||||
- s->SetCenter(MakeFVec3(center));
|
||||
- s->SetRadius(static_cast<vtkm::FloatDefault>(radius));
|
||||
+ this->OutFunction = vtkm::Sphere(MakeFVec3(center), static_cast<vtkm::FloatDefault>(radius));
|
||||
}
|
||||
|
||||
this->MTime = this->InFunction->GetMTime();
|
||||
diff --git a/Accelerators/Vtkm/DataModel/vtkmlib/ImplicitFunctionConverter.h b/Accelerators/Vtkm/DataModel/vtkmlib/ImplicitFunctionConverter.h
|
||||
index 10e2ae99ae819ca86516bf7ab5a0988c75b6323e..a1a571c93d44a7d62f79afc86aab05d1f359af82 100644
|
||||
--- a/Accelerators/Vtkm/DataModel/vtkmlib/ImplicitFunctionConverter.h
|
||||
+++ b/Accelerators/Vtkm/DataModel/vtkmlib/ImplicitFunctionConverter.h
|
||||
@@ -20,7 +20,7 @@
|
||||
#include "vtkType.h" // For vtkMTimeType
|
||||
#include "vtkmConfigDataModel.h" //required for general vtkm setup
|
||||
|
||||
-#include "vtkm/cont/ImplicitFunctionHandle.h"
|
||||
+#include "vtkm/ImplicitFunction.h"
|
||||
|
||||
class vtkImplicitFunction;
|
||||
|
||||
@@ -33,11 +33,11 @@ public:
|
||||
ImplicitFunctionConverter();
|
||||
|
||||
void Set(vtkImplicitFunction*);
|
||||
- const vtkm::cont::ImplicitFunctionHandle& Get() const;
|
||||
+ const vtkm::ImplicitFunctionGeneral& Get();
|
||||
|
||||
private:
|
||||
vtkImplicitFunction* InFunction;
|
||||
- vtkm::cont::ImplicitFunctionHandle OutFunction;
|
||||
+ vtkm::ImplicitFunctionGeneral OutFunction;
|
||||
mutable vtkMTimeType MTime;
|
||||
};
|
||||
|
||||
diff --git a/Accelerators/Vtkm/Filters/vtkmClipInstantiationsWithImplicitFunction.cxx b/Accelerators/Vtkm/Filters/vtkmClipInstantiationsWithImplicitFunction.cxx
|
||||
index 04a637a92d487b019742bbf81884750c48ba105d..674d9b6e0dfe36edd787e519e70ec0bf46602c81 100644
|
||||
--- a/Accelerators/Vtkm/Filters/vtkmClipInstantiationsWithImplicitFunction.cxx
|
||||
+++ b/Accelerators/Vtkm/Filters/vtkmClipInstantiationsWithImplicitFunction.cxx
|
||||
@@ -24,12 +24,9 @@ vtkm::cont::DataSet vtkmClip::internals::ExecuteClipWithImplicitFunction(vtkm::c
|
||||
auto function = this->ClipFunctionConverter->Get();
|
||||
|
||||
vtkm::cont::DataSet result;
|
||||
- if (function.GetValid())
|
||||
- {
|
||||
- vtkm::filter::ClipWithImplicitFunction functionFilter;
|
||||
- functionFilter.SetImplicitFunction(function);
|
||||
- result = functionFilter.Execute(in);
|
||||
- }
|
||||
+ vtkm::filter::ClipWithImplicitFunction functionFilter;
|
||||
+ functionFilter.SetImplicitFunction(function);
|
||||
+ result = functionFilter.Execute(in);
|
||||
|
||||
return result;
|
||||
}
|
||||
39
externals/vcpkg/ports/vtk/fix-gdal.patch
vendored
Executable file
39
externals/vcpkg/ports/vtk/fix-gdal.patch
vendored
Executable file
@@ -0,0 +1,39 @@
|
||||
diff --git a/CMake/vtkInstallCMakePackage.cmake b/CMake/vtkInstallCMakePackage.cmake
|
||||
index bcb2044..c87bb9c 100644
|
||||
--- a/CMake/vtkInstallCMakePackage.cmake
|
||||
+++ b/CMake/vtkInstallCMakePackage.cmake
|
||||
@@ -113,7 +113,6 @@ set(vtk_cmake_patch_files
|
||||
patches/3.18/FindPython/Support.cmake
|
||||
patches/3.18/FindPython2.cmake
|
||||
patches/3.18/FindPython3.cmake
|
||||
- patches/99/FindGDAL.cmake
|
||||
patches/99/FindHDF5.cmake
|
||||
patches/99/FindJPEG.cmake
|
||||
patches/99/FindLibArchive.cmake
|
||||
diff --git a/Geovis/GDAL/CMakeLists.txt b/Geovis/GDAL/CMakeLists.txt
|
||||
index dfd58f0..f46177f 100644
|
||||
--- a/Geovis/GDAL/CMakeLists.txt
|
||||
+++ b/Geovis/GDAL/CMakeLists.txt
|
||||
@@ -9,4 +9,7 @@ vtk_module_add_module(VTK::GeovisGDAL
|
||||
CLASSES ${classes})
|
||||
vtk_module_link(VTK::GeovisGDAL
|
||||
PRIVATE
|
||||
- GDAL::GDAL)
|
||||
+ ${GDAL_LIBRARIES})
|
||||
+vtk_module_include(VTK::GeovisGDAL
|
||||
+ PRIVATE
|
||||
+ ${GDAL_INCLUDE_DIRS})
|
||||
diff --git a/IO/GDAL/CMakeLists.txt b/IO/GDAL/CMakeLists.txt
|
||||
index 0a1248a..621a060 100644
|
||||
--- a/IO/GDAL/CMakeLists.txt
|
||||
+++ b/IO/GDAL/CMakeLists.txt
|
||||
@@ -9,4 +9,7 @@ vtk_module_add_module(VTK::IOGDAL
|
||||
CLASSES ${classes})
|
||||
vtk_module_link(VTK::IOGDAL
|
||||
PRIVATE
|
||||
- GDAL::GDAL)
|
||||
+ ${GDAL_LIBRARIES})
|
||||
+vtk_module_include(VTK::IOGDAL
|
||||
+ PRIVATE
|
||||
+ ${GDAL_INCLUDE_DIRS})
|
||||
\ No newline at end of file
|
||||
22
externals/vcpkg/ports/vtk/fix-using-hdf5.patch
vendored
Executable file
22
externals/vcpkg/ports/vtk/fix-using-hdf5.patch
vendored
Executable file
@@ -0,0 +1,22 @@
|
||||
diff --git a/ThirdParty/h5part/vtkh5part/src/H5Part.c b/ThirdParty/h5part/vtkh5part/src/H5Part.c
|
||||
index 228d246..41af04d 100644
|
||||
--- a/ThirdParty/h5part/vtkh5part/src/H5Part.c
|
||||
+++ b/ThirdParty/h5part/vtkh5part/src/H5Part.c
|
||||
@@ -2092,7 +2092,7 @@ _H5Part_iteration_operator2 (
|
||||
case H5L_TYPE_HARD: {
|
||||
|
||||
H5O_info_t objinfo;
|
||||
- if( H5Oget_info_by_name( group_id, member_name, &objinfo, H5P_DEFAULT ) < 0 ) {
|
||||
+ if( H5Oget_info_by_name1( group_id, member_name, &objinfo, H5P_DEFAULT ) < 0 ) {
|
||||
return (herr_t)HANDLE_H5G_GET_OBJINFO_ERR ( member_name );
|
||||
}
|
||||
|
||||
@@ -2142,7 +2142,7 @@ _H5Part_iteration_operator2 (
|
||||
if ( obj_id < 0 ) {
|
||||
return (herr_t)HANDLE_H5G_OPEN_ERR ( member_name );
|
||||
}
|
||||
- else if ( H5Oget_info ( obj_id, &objinfo ) < 0 ) {
|
||||
+ else if ( H5Oget_info1 ( obj_id, &objinfo ) < 0 ) {
|
||||
return (herr_t)HANDLE_H5G_GET_OBJINFO_ERR ( member_name );
|
||||
}
|
||||
else {
|
||||
48
externals/vcpkg/ports/vtk/missing-limits.patch
vendored
Executable file
48
externals/vcpkg/ports/vtk/missing-limits.patch
vendored
Executable file
@@ -0,0 +1,48 @@
|
||||
diff --git a/Common/Core/vtkGenericDataArrayLookupHelper.h b/Common/Core/vtkGenericDataArrayLookupHelper.h
|
||||
index ab9d572..202aaa2 100644
|
||||
--- a/Common/Core/vtkGenericDataArrayLookupHelper.h
|
||||
+++ b/Common/Core/vtkGenericDataArrayLookupHelper.h
|
||||
@@ -25,6 +25,7 @@
|
||||
#include "vtkIdList.h"
|
||||
#include <algorithm>
|
||||
#include <cmath>
|
||||
+#include <limits>
|
||||
#include <unordered_map>
|
||||
#include <vector>
|
||||
|
||||
diff --git a/Common/DataModel/vtkPiecewiseFunction.cxx b/Common/DataModel/vtkPiecewiseFunction.cxx
|
||||
index 22eca0b..11086f1 100644
|
||||
--- a/Common/DataModel/vtkPiecewiseFunction.cxx
|
||||
+++ b/Common/DataModel/vtkPiecewiseFunction.cxx
|
||||
@@ -22,6 +22,7 @@
|
||||
#include <cassert>
|
||||
#include <cmath>
|
||||
#include <iterator>
|
||||
+#include <limits>
|
||||
#include <set>
|
||||
#include <vector>
|
||||
|
||||
diff --git a/Filters/HyperTree/vtkHyperTreeGridThreshold.cxx b/Filters/HyperTree/vtkHyperTreeGridThreshold.cxx
|
||||
index a16bb27..1052192 100644
|
||||
--- a/Filters/HyperTree/vtkHyperTreeGridThreshold.cxx
|
||||
+++ b/Filters/HyperTree/vtkHyperTreeGridThreshold.cxx
|
||||
@@ -27,6 +27,7 @@
|
||||
#include "vtkHyperTreeGridNonOrientedCursor.h"
|
||||
|
||||
#include <cmath>
|
||||
+#include <limits>
|
||||
|
||||
vtkStandardNewMacro(vtkHyperTreeGridThreshold);
|
||||
|
||||
diff --git a/Rendering/Core/vtkColorTransferFunction.cxx b/Rendering/Core/vtkColorTransferFunction.cxx
|
||||
index 55c046b..1be0291 100644
|
||||
--- a/Rendering/Core/vtkColorTransferFunction.cxx
|
||||
+++ b/Rendering/Core/vtkColorTransferFunction.cxx
|
||||
@@ -21,6 +21,7 @@
|
||||
#include <algorithm>
|
||||
#include <cmath>
|
||||
#include <iterator>
|
||||
+#include <limits>
|
||||
#include <set>
|
||||
#include <vector>
|
||||
|
||||
73
externals/vcpkg/ports/vtk/pegtl.patch
vendored
Executable file
73
externals/vcpkg/ports/vtk/pegtl.patch
vendored
Executable file
@@ -0,0 +1,73 @@
|
||||
diff --git a/CMake/FindPEGTL.cmake b/CMake/FindPEGTL.cmake
|
||||
index 73eee02f7..22d8bc159 100644
|
||||
--- a/CMake/FindPEGTL.cmake
|
||||
+++ b/CMake/FindPEGTL.cmake
|
||||
@@ -19,31 +19,42 @@
|
||||
# Copyright (c) 2009 Benoit Jacob <jacob.benoit.1@gmail.com>
|
||||
# Redistribution and use is allowed according to the terms of the 2-clause BSD license.
|
||||
|
||||
-find_path(PEGTL_INCLUDE_DIR
|
||||
- NAMES pegtl/version.hpp
|
||||
- PATH_SUFFIXES tao
|
||||
- DOC "Path to PEGTL headers")
|
||||
-mark_as_advanced(PEGTL_INCLUDE_DIR)
|
||||
+message(STATUS "Searching for PEGTL")
|
||||
+find_package(PEGTL CONFIG NAMES PEGTL-2)
|
||||
+if(TARGET taocpp::pegtl)
|
||||
+ message(STATUS "Searching for PEGTL - found target taocpp::pegtl")
|
||||
+ set_target_properties(taocpp::pegtl PROPERTIES IMPORTED_GLOBAL TRUE)
|
||||
+ if(NOT TARGET PEGTL::PEGTL)
|
||||
+ add_library(PEGTL::PEGTL ALIAS taocpp::pegtl)
|
||||
+ endif()
|
||||
+else()
|
||||
+ find_path(PEGTL_INCLUDE_DIR
|
||||
+ NAMES pegtl/version.hpp
|
||||
+ PATH_SUFFIXES tao
|
||||
+ DOC "Path to PEGTL headers")
|
||||
+ mark_as_advanced(PEGTL_INCLUDE_DIR)
|
||||
|
||||
-if (PEGTL_INCLUDE_DIR)
|
||||
- file(STRINGS "${PEGTL_INCLUDE_DIR}/pegtl/version.hpp" _pegtl_version_header
|
||||
- REGEX "TAO_PEGTL_VERSION")
|
||||
- string(REGEX MATCH "define[ \t]+TAO_PEGTL_VERSION[ \t]+\"([0-9.]+)\"" _pegtl_version_match "${_pegtl_version_header}")
|
||||
- set(PEGTL_VERSION "${CMAKE_MATCH_1}")
|
||||
- unset(_pegtl_version_header)
|
||||
- unset(_pegtl_version_match)
|
||||
-endif ()
|
||||
+ if (PEGTL_INCLUDE_DIR)
|
||||
+ file(STRINGS "${PEGTL_INCLUDE_DIR}/pegtl/version.hpp" _pegtl_version_header
|
||||
+ REGEX "TAO_PEGTL_VERSION")
|
||||
+ string(REGEX MATCH "define[ \t]+TAO_PEGTL_VERSION[ \t]+\"([0-9.]+)\"" _pegtl_version_match "${_pegtl_version_header}")
|
||||
+ set(PEGTL_VERSION "${CMAKE_MATCH_1}")
|
||||
+ unset(_pegtl_version_header)
|
||||
+ unset(_pegtl_version_match)
|
||||
+ endif ()
|
||||
|
||||
-include(FindPackageHandleStandardArgs)
|
||||
-find_package_handle_standard_args(PEGTL
|
||||
- REQUIRED_VARS PEGTL_INCLUDE_DIR
|
||||
- VERSION_VAR PEGTL_VERSION)
|
||||
+ include(FindPackageHandleStandardArgs)
|
||||
+ find_package_handle_standard_args(PEGTL
|
||||
+ REQUIRED_VARS PEGTL_INCLUDE_DIR
|
||||
+ VERSION_VAR PEGTL_VERSION)
|
||||
|
||||
-if (PEGTL_FOUND)
|
||||
- set(PEGTL_INCLUDE_DIRS "${PEGTL_INCLUDE_DIR}")
|
||||
- if (NOT TARGET PEGTL::PEGTL)
|
||||
- add_library(PEGTL::PEGTL INTERFACE IMPORTED)
|
||||
- set_target_properties(PEGTL::PEGTL PROPERTIES
|
||||
- INTERFACE_INCLUDE_DIRECTORIES "${PEGTL_INCLUDE_DIR}")
|
||||
- endif ()
|
||||
-endif ()
|
||||
+ if (PEGTL_FOUND)
|
||||
+ set(PEGTL_INCLUDE_DIRS "${PEGTL_INCLUDE_DIR}")
|
||||
+ if (NOT TARGET PEGTL::PEGTL)
|
||||
+ add_library(PEGTL::PEGTL INTERFACE IMPORTED)
|
||||
+ set_target_properties(PEGTL::PEGTL PROPERTIES
|
||||
+ INTERFACE_INCLUDE_DIRECTORIES "${PEGTL_INCLUDE_DIR}")
|
||||
+ endif ()
|
||||
+ message(STATUS "Searching for PEGTL - found")
|
||||
+ endif ()
|
||||
+endif ()
|
||||
\ No newline at end of file
|
||||
306
externals/vcpkg/ports/vtk/portfile.cmake
vendored
Executable file
306
externals/vcpkg/ports/vtk/portfile.cmake
vendored
Executable file
@@ -0,0 +1,306 @@
|
||||
if(NOT VCPKG_TARGET_IS_WINDOWS)
|
||||
message(WARNING "You will need to install Xorg dependencies to build vtk:\napt-get install libxt-dev\n")
|
||||
endif()
|
||||
|
||||
# =============================================================================
|
||||
# Clone & patch
|
||||
vcpkg_from_github(
|
||||
OUT_SOURCE_PATH SOURCE_PATH
|
||||
REPO Kitware/VTK
|
||||
REF 2959413ff190bc6e3ff40f5b6c1342edd2e5233f # v9.0.x used by ParaView 5.9.1
|
||||
SHA512 16229c107ed904e8fa6850c3814b8bdcdf9700ef44f6ff5b3a77e7d793ce19954fc2c7b1219a0162cf588def6e990883cd3f808c316a4db6e65bd6cd1769dd3f
|
||||
HEAD_REF master
|
||||
PATCHES
|
||||
FindLZMA.patch
|
||||
FindLZ4.patch
|
||||
Findproj.patch
|
||||
pegtl.patch
|
||||
pythonwrapper.patch # Required by ParaView to Wrap required classes
|
||||
NoUndefDebug.patch # Required to link against correct Python library depending on build type.
|
||||
python_debug.patch
|
||||
fix-using-hdf5.patch
|
||||
# CHECK: module-name-mangling.patch
|
||||
# Last patch TODO: Patch out internal loguru
|
||||
FindExpat.patch # The find_library calls are taken care of by vcpkg-cmake-wrapper.cmake of expat
|
||||
# upstream vtkm patches to make it work with vtkm 1.6
|
||||
vtkm.patch # To include an external VTKm build
|
||||
1f00a0c9.patch
|
||||
156fb524.patch
|
||||
d107698a.patch
|
||||
fix-gdal.patch
|
||||
missing-limits.patch # This patch can be removed in next version. Since it has been merged to upstream via https://gitlab.kitware.com/vtk/vtk/-/merge_requests/7611
|
||||
UseProj5Api.patch # Allow Proj 8.0+ (commit b66e4a7, backported). Should be in soon after 9.0.3
|
||||
)
|
||||
|
||||
# =============================================================================
|
||||
#Overwrite outdated modules if they have not been patched:
|
||||
file(COPY "${CURRENT_PORT_DIR}/FindHDF5.cmake" DESTINATION "${SOURCE_PATH}/CMake/patches/99") # due to usage of targets in netcdf-c
|
||||
# =============================================================================
|
||||
|
||||
# =============================================================================
|
||||
# Options:
|
||||
# Collect CMake options for optional components
|
||||
|
||||
# TODO:
|
||||
# - add loguru as a dependency requires #8682
|
||||
vcpkg_check_features(OUT_FEATURE_OPTIONS VTK_FEATURE_OPTIONS
|
||||
FEATURES
|
||||
"qt" VTK_GROUP_ENABLE_Qt
|
||||
"qt" VTK_MODULE_ENABLE_VTK_GUISupportQt
|
||||
"qt" VTK_MODULE_ENABLE_VTK_GUISupportQtSQL
|
||||
"qt" VTK_MODULE_ENABLE_VTK_RenderingQt
|
||||
"qt" VTK_MODULE_ENABLE_VTK_ViewsQt
|
||||
"atlmfc" VTK_MODULE_ENABLE_VTK_GUISupportMFC
|
||||
"vtkm" VTK_MODULE_ENABLE_VTK_AcceleratorsVTKmCore
|
||||
"vtkm" VTK_MODULE_ENABLE_VTK_AcceleratorsVTKmDataModel
|
||||
"vtkm" VTK_MODULE_ENABLE_VTK_AcceleratorsVTKmFilters
|
||||
"vtkm" VTK_MODULE_ENABLE_VTK_vtkm
|
||||
"python" VTK_MODULE_ENABLE_VTK_Python
|
||||
"python" VTK_MODULE_ENABLE_VTK_PythonContext2D
|
||||
"python" VTK_MODULE_ENABLE_VTK_PythonInterpreter
|
||||
"paraview" VTK_MODULE_ENABLE_VTK_FiltersParallelStatistics
|
||||
"paraview" VTK_MODULE_ENABLE_VTK_IOParallelExodus
|
||||
"paraview" VTK_MODULE_ENABLE_VTK_RenderingParallel
|
||||
"paraview" VTK_MODULE_ENABLE_VTK_RenderingVolumeAMR
|
||||
"paraview" VTK_MODULE_ENABLE_VTK_IOXdmf2
|
||||
"paraview" VTK_MODULE_ENABLE_VTK_IOH5part
|
||||
"paraview" VTK_MODULE_ENABLE_VTK_IOParallelLSDyna
|
||||
"paraview" VTK_MODULE_ENABLE_VTK_IOTRUCHAS
|
||||
"paraview" VTK_MODULE_ENABLE_VTK_IOVPIC
|
||||
"paraview" VTK_MODULE_ENABLE_VTK_RenderingAnnotation
|
||||
"paraview" VTK_MODULE_ENABLE_VTK_DomainsChemistry
|
||||
"paraview" VTK_MODULE_ENABLE_VTK_FiltersParallelDIY2
|
||||
"mpi" VTK_GROUP_ENABLE_MPI
|
||||
"opengl" VTK_MODULE_ENABLE_VTK_ImagingOpenGL2
|
||||
"opengl" VTK_MODULE_ENABLE_VTK_RenderingGL2PSOpenGL2
|
||||
"opengl" VTK_MODULE_ENABLE_VTK_RenderingOpenGL2
|
||||
"opengl" VTK_MODULE_ENABLE_VTK_RenderingVolumeOpenGL2
|
||||
"opengl" VTK_MODULE_ENABLE_VTK_opengl
|
||||
"openvr" VTK_MODULE_ENABLE_VTK_RenderingOpenVR
|
||||
"gdal" VTK_MODULE_ENABLE_VTK_IOGDAL
|
||||
"geojson" VTK_MODULE_ENABLE_VTK_IOGeoJSON
|
||||
)
|
||||
|
||||
# Replace common value to vtk value
|
||||
list(TRANSFORM VTK_FEATURE_OPTIONS REPLACE "=ON" "=YES")
|
||||
list(TRANSFORM VTK_FEATURE_OPTIONS REPLACE "=OFF" "=DONT_WANT")
|
||||
|
||||
if("python" IN_LIST FEATURES)
|
||||
vcpkg_find_acquire_program(PYTHON3)
|
||||
list(APPEND ADDITIONAL_OPTIONS
|
||||
-DVTK_WRAP_PYTHON=ON
|
||||
-DVTK_PYTHON_VERSION=3
|
||||
-DPython3_FIND_REGISTRY=NEVER
|
||||
"-DPython3_EXECUTABLE:PATH=${PYTHON3}"
|
||||
)
|
||||
#VTK_PYTHON_SITE_PACKAGES_SUFFIX should be set to the install dir of the site-packages
|
||||
endif()
|
||||
|
||||
if ("paraview" IN_LIST FEATURES OR "opengl" IN_LIST FEATURES)
|
||||
list(APPEND ADDITIONAL_OPTIONS
|
||||
-DVTK_MODULE_ENABLE_VTK_RenderingContextOpenGL2=YES
|
||||
-DVTK_MODULE_ENABLE_VTK_RenderingLICOpenGL2=YES
|
||||
-DVTK_MODULE_ENABLE_VTK_DomainsChemistryOpenGL2=YES
|
||||
)
|
||||
endif()
|
||||
|
||||
if("paraview" IN_LIST FEATURES AND "python" IN_LIST FEATURES)
|
||||
list(APPEND ADDITIONAL_OPTIONS
|
||||
-DVTK_MODULE_ENABLE_VTK_RenderingMatplotlib=YES
|
||||
)
|
||||
endif()
|
||||
|
||||
if("mpi" IN_LIST FEATURES AND "python" IN_LIST FEATURES)
|
||||
list(APPEND ADDITIONAL_OPTIONS
|
||||
-DVTK_MODULE_USE_EXTERNAL_VTK_mpi4py=OFF
|
||||
)
|
||||
endif()
|
||||
|
||||
if("cuda" IN_LIST FEATURES AND CMAKE_HOST_WIN32)
|
||||
vcpkg_add_to_path("$ENV{CUDA_PATH}/bin")
|
||||
endif()
|
||||
|
||||
if("utf8" IN_LIST FEATURES)
|
||||
list(APPEND ADDITIONAL_OPTIONS
|
||||
-DKWSYS_ENCODING_DEFAULT_CODEPAGE=CP_UTF8
|
||||
)
|
||||
endif()
|
||||
|
||||
if("all" IN_LIST FEATURES)
|
||||
list(APPEND ADDITIONAL_OPTIONS
|
||||
-DVTK_USE_TK=OFF # TCL/TK currently not included in vcpkg
|
||||
-DVTK_FORBID_DOWNLOADS=OFF
|
||||
)
|
||||
else()
|
||||
list(APPEND ADDITIONAL_OPTIONS
|
||||
-DVTK_FORBID_DOWNLOADS=ON
|
||||
)
|
||||
endif()
|
||||
|
||||
vcpkg_check_features(OUT_FEATURE_OPTIONS FEATURE_OPTIONS
|
||||
FEATURES
|
||||
"cuda" VTK_USE_CUDA
|
||||
"mpi" VTK_USE_MPI
|
||||
"all" VTK_BUILD_ALL_MODULES
|
||||
)
|
||||
# =============================================================================
|
||||
# Configure & Install
|
||||
|
||||
# We set all libraries to "system" and explicitly list the ones that should use embedded copies
|
||||
vcpkg_cmake_configure(
|
||||
SOURCE_PATH "${SOURCE_PATH}"
|
||||
OPTIONS
|
||||
${FEATURE_OPTIONS}
|
||||
${VTK_FEATURE_OPTIONS}
|
||||
-DBUILD_TESTING=OFF
|
||||
-DVTK_BUILD_TESTING=OFF
|
||||
-DVTK_BUILD_EXAMPLES=OFF
|
||||
-DVTK_ENABLE_REMOTE_MODULES=OFF
|
||||
# VTK groups to enable
|
||||
-DVTK_GROUP_ENABLE_StandAlone=YES
|
||||
-DVTK_GROUP_ENABLE_Rendering=YES
|
||||
-DVTK_GROUP_ENABLE_Views=YES
|
||||
# Disable deps not in VCPKG
|
||||
-DVTK_USE_TK=OFF # TCL/TK currently not included in vcpkg
|
||||
# Select modules / groups to install
|
||||
-DVTK_USE_EXTERNAL:BOOL=ON
|
||||
-DVTK_MODULE_USE_EXTERNAL_VTK_gl2ps:BOOL=OFF # Not yet in VCPKG
|
||||
${ADDITIONAL_OPTIONS}
|
||||
-DVTK_DEBUG_MODULE_ALL=ON
|
||||
-DVTK_DEBUG_MODULE=ON
|
||||
)
|
||||
|
||||
vcpkg_cmake_install()
|
||||
vcpkg_copy_pdbs()
|
||||
|
||||
# =============================================================================
|
||||
# Fixup target files
|
||||
vcpkg_cmake_config_fixup(CONFIG_PATH lib/cmake/vtk-9.0)
|
||||
|
||||
# =============================================================================
|
||||
# Clean-up other directories
|
||||
|
||||
# Delete the debug binary TOOL_NAME that is not required
|
||||
function(_vtk_remove_debug_tool TOOL_NAME)
|
||||
set(filename "${CURRENT_PACKAGES_DIR}/debug/bin/${TOOL_NAME}${VCPKG_TARGET_EXECUTABLE_SUFFIX}")
|
||||
if(EXISTS "${filename}")
|
||||
file(REMOVE "${filename}")
|
||||
endif()
|
||||
set(filename "${CURRENT_PACKAGES_DIR}/debug/bin/${TOOL_NAME}d${VCPKG_TARGET_EXECUTABLE_SUFFIX}")
|
||||
if(EXISTS "${filename}")
|
||||
file(REMOVE "${filename}")
|
||||
endif()
|
||||
if (NOT VCPKG_BUILD_TYPE OR VCPKG_BUILD_TYPE STREQUAL debug)
|
||||
# we also have to bend the lines referencing the tools in VTKTargets-debug.cmake
|
||||
# to make them point to the release version of the tools
|
||||
file(READ "${CURRENT_PACKAGES_DIR}/share/vtk/VTK-targets-debug.cmake" VTK_TARGETS_CONTENT_DEBUG)
|
||||
string(REPLACE "debug/bin/${TOOL_NAME}" "tools/vtk/${TOOL_NAME}" VTK_TARGETS_CONTENT_DEBUG "${VTK_TARGETS_CONTENT_DEBUG}")
|
||||
string(REPLACE "tools/vtk/${TOOL_NAME}d" "tools/vtk/${TOOL_NAME}" VTK_TARGETS_CONTENT_DEBUG "${VTK_TARGETS_CONTENT_DEBUG}")
|
||||
file(WRITE "${CURRENT_PACKAGES_DIR}/share/vtk/VTK-targets-debug.cmake" "${VTK_TARGETS_CONTENT_DEBUG}")
|
||||
endif()
|
||||
endfunction()
|
||||
|
||||
# Move the release binary TOOL_NAME from bin to tools
|
||||
function(_vtk_move_release_tool TOOL_NAME)
|
||||
set(old_filename "${CURRENT_PACKAGES_DIR}/bin/${TOOL_NAME}${VCPKG_TARGET_EXECUTABLE_SUFFIX}")
|
||||
if(EXISTS "${old_filename}")
|
||||
file(INSTALL "${old_filename}" DESTINATION "${CURRENT_PACKAGES_DIR}/tools/vtk" USE_SOURCE_PERMISSIONS)
|
||||
file(REMOVE "${old_filename}")
|
||||
endif()
|
||||
|
||||
if (NOT VCPKG_BUILD_TYPE OR VCPKG_BUILD_TYPE STREQUAL release)
|
||||
# we also have to bend the lines referencing the tools in VTKTargets-release.cmake
|
||||
# to make them point to the tool folder
|
||||
file(READ "${CURRENT_PACKAGES_DIR}/share/vtk/VTK-targets-release.cmake" VTK_TARGETS_CONTENT_RELEASE)
|
||||
string(REPLACE "bin/${TOOL_NAME}" "tools/vtk/${TOOL_NAME}" VTK_TARGETS_CONTENT_RELEASE "${VTK_TARGETS_CONTENT_RELEASE}")
|
||||
file(WRITE "${CURRENT_PACKAGES_DIR}/share/vtk/VTK-targets-release.cmake" "${VTK_TARGETS_CONTENT_RELEASE}")
|
||||
endif()
|
||||
endfunction()
|
||||
|
||||
set(VTK_SHORT_VERSION 9.0)
|
||||
set(VTK_TOOLS
|
||||
vtkEncodeString-${VTK_SHORT_VERSION}
|
||||
vtkHashSource-${VTK_SHORT_VERSION}
|
||||
vtkWrapTclInit-${VTK_SHORT_VERSION}
|
||||
vtkWrapTcl-${VTK_SHORT_VERSION}
|
||||
vtkWrapPythonInit-${VTK_SHORT_VERSION}
|
||||
vtkWrapPython-${VTK_SHORT_VERSION}
|
||||
vtkWrapJava-${VTK_SHORT_VERSION}
|
||||
vtkWrapHierarchy-${VTK_SHORT_VERSION}
|
||||
vtkParseJava-${VTK_SHORT_VERSION}
|
||||
vtkParseOGLExt-${VTK_SHORT_VERSION}
|
||||
vtkProbeOpenGLVersion-${VTK_SHORT_VERSION}
|
||||
vtkTestOpenGLVersion-${VTK_SHORT_VERSION}
|
||||
vtkpython
|
||||
pvtkpython
|
||||
)
|
||||
# TODO: Replace with vcpkg_copy_tools if known which tools are built with which feature
|
||||
# or add and option to vcpkg_copy_tools which does not require the tool to be present
|
||||
foreach(TOOL_NAME IN LISTS VTK_TOOLS)
|
||||
_vtk_remove_debug_tool("${TOOL_NAME}")
|
||||
_vtk_move_release_tool("${TOOL_NAME}")
|
||||
endforeach()
|
||||
|
||||
if(VCPKG_LIBRARY_LINKAGE STREQUAL "static")
|
||||
file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/bin"
|
||||
"${CURRENT_PACKAGES_DIR}/debug/bin")
|
||||
endif()
|
||||
|
||||
file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/debug/include")
|
||||
file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/debug/share")
|
||||
|
||||
vcpkg_copy_tool_dependencies("${CURRENT_PACKAGES_DIR}/tools/vtk")
|
||||
|
||||
## Files Modules needed by ParaView
|
||||
if("paraview" IN_LIST FEATURES)
|
||||
set(VTK_CMAKE_NEEDED vtkCompilerChecks vtkCompilerPlatformFlags vtkCompilerExtraFlags vtkInitializeBuildType
|
||||
vtkSupportMacros vtkVersion FindPythonModules vtkModuleDebugging vtkExternalData)
|
||||
foreach(module ${VTK_CMAKE_NEEDED})
|
||||
file(INSTALL "${SOURCE_PATH}/CMake/${module}.cmake" DESTINATION "${CURRENT_PACKAGES_DIR}/share/vtk")
|
||||
endforeach()
|
||||
|
||||
## Check List on UPDATE !!
|
||||
file(INSTALL "${SOURCE_PATH}/CMake/vtkRequireLargeFilesSupport.cxx" DESTINATION "${CURRENT_PACKAGES_DIR}/share/vtk")
|
||||
file(INSTALL "${SOURCE_PATH}/Rendering/Volume/vtkBlockSortHelper.h" DESTINATION "${CURRENT_PACKAGES_DIR}/include/vtk-${VTK_SHORT_VERSION}") # this should get installed by VTK
|
||||
file(INSTALL "${SOURCE_PATH}/Filters/ParallelDIY2/vtkDIYKdTreeUtilities.h" DESTINATION "${CURRENT_PACKAGES_DIR}/include/vtk-${VTK_SHORT_VERSION}")
|
||||
file(INSTALL "${SOURCE_PATH}/Parallel/DIY/vtkDIYUtilities.txx" DESTINATION "${CURRENT_PACKAGES_DIR}/include/vtk-${VTK_SHORT_VERSION}")
|
||||
|
||||
file(INSTALL "${CURRENT_BUILDTREES_DIR}/${TARGET_TRIPLET}-rel/Rendering/OpenGL2/vtkTextureObjectVS.h" DESTINATION "${CURRENT_PACKAGES_DIR}/include/vtk-${VTK_SHORT_VERSION}")
|
||||
|
||||
endif()
|
||||
|
||||
if(VCPKG_LIBRARY_LINKAGE STREQUAL "static")
|
||||
if(EXISTS "${CURRENT_BUILDTREES_DIR}/${TARGET_TRIPLET}-rel/CMakeFiles/vtkpythonmodules/static_python") #python headers
|
||||
file(GLOB_RECURSE STATIC_PYTHON_FILES "${CURRENT_BUILDTREES_DIR}/${TARGET_TRIPLET}-rel/CMakeFiles/*/static_python/*.h")
|
||||
file(INSTALL ${STATIC_PYTHON_FILES} DESTINATION "${CURRENT_PACKAGES_DIR}/include/vtk-${VTK_SHORT_VERSION}")
|
||||
endif()
|
||||
endif()
|
||||
|
||||
#remove one get_filename_component(_vtk_module_import_prefix "${_vtk_module_import_prefix}" DIRECTORY) from vtk-prefix.cmake and VTK-vtk-module-properties and vtk-python.cmake
|
||||
set(filenames_fix_prefix vtk-prefix VTK-vtk-module-properties vtk-python)
|
||||
foreach(name IN LISTS filenames_fix_prefix)
|
||||
if(EXISTS "${CURRENT_PACKAGES_DIR}/share/vtk/${name}.cmake")
|
||||
file(READ "${CURRENT_PACKAGES_DIR}/share/vtk/${name}.cmake" _contents)
|
||||
string(REPLACE
|
||||
[[set(_vtk_module_import_prefix "${CMAKE_CURRENT_LIST_DIR}")
|
||||
get_filename_component(_vtk_module_import_prefix "${_vtk_module_import_prefix}" DIRECTORY)]]
|
||||
[[set(_vtk_module_import_prefix "${CMAKE_CURRENT_LIST_DIR}")]] _contents "${_contents}")
|
||||
file(WRITE "${CURRENT_PACKAGES_DIR}/share/vtk/${name}.cmake" "${_contents}")
|
||||
else()
|
||||
debug_message("FILE:${CURRENT_PACKAGES_DIR}/share/vtk/${name}.cmake does not exist! No prefix correction!")
|
||||
endif()
|
||||
endforeach()
|
||||
|
||||
# Use vcpkg provided find method
|
||||
file(REMOVE "${CURRENT_PACKAGES_DIR}/share/${PORT}/FindEXPAT.cmake")
|
||||
|
||||
file(RENAME "${CURRENT_PACKAGES_DIR}/share/licenses" "${CURRENT_PACKAGES_DIR}/share/${PORT}/licenses")
|
||||
|
||||
if(EXISTS "${CURRENT_PACKAGES_DIR}/include/vtk-9.0/vtkChemistryConfigure.h")
|
||||
vcpkg_replace_string("${CURRENT_PACKAGES_DIR}/include/vtk-9.0/vtkChemistryConfigure.h" "${SOURCE_PATH}" "not/existing")
|
||||
endif()
|
||||
# =============================================================================
|
||||
# Usage
|
||||
configure_file("${CMAKE_CURRENT_LIST_DIR}/usage" "${CURRENT_PACKAGES_DIR}/share/${PORT}/usage" COPYONLY)
|
||||
# Handle copyright
|
||||
file(INSTALL "${SOURCE_PATH}/Copyright.txt" DESTINATION "${CURRENT_PACKAGES_DIR}/share/${PORT}" RENAME "copyright")
|
||||
13
externals/vcpkg/ports/vtk/python_debug.patch
vendored
Executable file
13
externals/vcpkg/ports/vtk/python_debug.patch
vendored
Executable file
@@ -0,0 +1,13 @@
|
||||
diff --git a/CMake/patches/3.18/FindPython/Support.cmake b/CMake/patches/3.18/FindPython/Support.cmake
|
||||
index 0879537ed..122e7228d 100644
|
||||
--- a/CMake/patches/3.18/FindPython/Support.cmake
|
||||
+++ b/CMake/patches/3.18/FindPython/Support.cmake
|
||||
@@ -2253,7 +2257,7 @@ if (("Development.Module" IN_LIST ${_PYTHON_PREFIX}_FIND_COMPONENTS
|
||||
NAMES ${_${_PYTHON_PREFIX}_LIB_NAMES_DEBUG}
|
||||
NAMES_PER_DIR
|
||||
HINTS "${_${_PYTHON_PREFIX}_PATH}" ${_${_PYTHON_PREFIX}_HINTS}
|
||||
- NO_DEFAULT_PATH)
|
||||
+ )
|
||||
endif()
|
||||
|
||||
# retrieve runtime libraries
|
||||
19
externals/vcpkg/ports/vtk/pythonwrapper.patch
vendored
Executable file
19
externals/vcpkg/ports/vtk/pythonwrapper.patch
vendored
Executable file
@@ -0,0 +1,19 @@
|
||||
diff --git a/CMake/vtkModuleWrapPython.cmake b/CMake/vtkModuleWrapPython.cmake
|
||||
index 5d2c2e1bf..e33a16d68 100644
|
||||
--- a/CMake/vtkModuleWrapPython.cmake
|
||||
+++ b/CMake/vtkModuleWrapPython.cmake
|
||||
@@ -152,11 +152,14 @@ function (_vtk_module_wrap_python_sources module sources classes)
|
||||
set(_vtk_python_genex_compile_definitions
|
||||
"$<TARGET_PROPERTY:${_vtk_python_target_name},COMPILE_DEFINITIONS>")
|
||||
set(_vtk_python_genex_include_directories
|
||||
"$<TARGET_PROPERTY:${_vtk_python_target_name},INCLUDE_DIRECTORIES>")
|
||||
+ set(_vtk_python_genex_interface_include_directories
|
||||
+ "$<TARGET_PROPERTY:${_vtk_python_target_name},INTERFACE_INCLUDE_DIRECTORIES>")
|
||||
file(GENERATE
|
||||
OUTPUT "${_vtk_python_args_file}"
|
||||
CONTENT "$<$<BOOL:${_vtk_python_genex_compile_definitions}>:\n-D\'$<JOIN:${_vtk_python_genex_compile_definitions},\'\n-D\'>\'>\n
|
||||
$<$<BOOL:${_vtk_python_genex_include_directories}>:\n-I\'$<JOIN:${_vtk_python_genex_include_directories},\'\n-I\'>\'>\n
|
||||
+$<$<BOOL:${_vtk_python_genex_interface_include_directories}>:\n-I\'$<JOIN:${_vtk_python_genex_interface_include_directories},\'\n-I\'>\'>\n
|
||||
$<$<BOOL:${_vtk_python_hierarchy_files}>:\n--types \'$<JOIN:${_vtk_python_hierarchy_files},\'\n--types \'>\'>\n")
|
||||
|
||||
set(_vtk_python_sources)
|
||||
5
externals/vcpkg/ports/vtk/usage
vendored
Executable file
5
externals/vcpkg/ports/vtk/usage
vendored
Executable file
@@ -0,0 +1,5 @@
|
||||
The package vtk provides CMake targets:
|
||||
|
||||
find_package(VTK REQUIRED)
|
||||
include("${VTK_USE_FILE}")
|
||||
target_link_libraries(main PRIVATE ${VTK_LIBRARIES})
|
||||
201
externals/vcpkg/ports/vtk/vcpkg.json
vendored
Executable file
201
externals/vcpkg/ports/vtk/vcpkg.json
vendored
Executable file
@@ -0,0 +1,201 @@
|
||||
{
|
||||
"name": "vtk",
|
||||
"version-semver": "9.0.3-pv5.9.1",
|
||||
"port-version": 10,
|
||||
"description": "Software system for 3D computer graphics, image processing, and visualization",
|
||||
"homepage": "https://github.com/Kitware/VTK",
|
||||
"license": "BSD-3-Clause",
|
||||
"dependencies": [
|
||||
"double-conversion",
|
||||
"eigen3",
|
||||
"expat",
|
||||
"freetype",
|
||||
"glew",
|
||||
{
|
||||
"name": "hdf5",
|
||||
"default-features": false
|
||||
},
|
||||
"jsoncpp",
|
||||
{
|
||||
"name": "libharu",
|
||||
"features": [
|
||||
"notiffsymbols"
|
||||
]
|
||||
},
|
||||
"libjpeg-turbo",
|
||||
"liblzma",
|
||||
"libogg",
|
||||
"libpng",
|
||||
"libtheora",
|
||||
"libxml2",
|
||||
"lz4",
|
||||
"netcdf-c",
|
||||
"pegtl-2",
|
||||
"proj",
|
||||
"pugixml",
|
||||
"sqlite3",
|
||||
"tiff",
|
||||
"utfcpp",
|
||||
{
|
||||
"name": "vcpkg-cmake",
|
||||
"host": true
|
||||
},
|
||||
{
|
||||
"name": "vcpkg-cmake-config",
|
||||
"host": true
|
||||
},
|
||||
"zlib"
|
||||
],
|
||||
"features": {
|
||||
"all": {
|
||||
"description": "Build all vtk modules",
|
||||
"dependencies": [
|
||||
"ffmpeg",
|
||||
"libmysql",
|
||||
{
|
||||
"name": "vtk",
|
||||
"default-features": false,
|
||||
"features": [
|
||||
"gdal",
|
||||
"geojson",
|
||||
"mpi",
|
||||
"python",
|
||||
"qt"
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "vtk",
|
||||
"default-features": false,
|
||||
"features": [
|
||||
"atlmfc",
|
||||
"utf8"
|
||||
],
|
||||
"platform": "windows"
|
||||
}
|
||||
]
|
||||
},
|
||||
"atlmfc": {
|
||||
"description": "Mfc functionality for vtk on Windows",
|
||||
"dependencies": [
|
||||
{
|
||||
"name": "atlmfc",
|
||||
"platform": "windows"
|
||||
}
|
||||
]
|
||||
},
|
||||
"cuda": {
|
||||
"description": "Support CUDA compilation",
|
||||
"dependencies": [
|
||||
"cuda"
|
||||
]
|
||||
},
|
||||
"gdal": {
|
||||
"description": "Support GDAL compilation",
|
||||
"dependencies": [
|
||||
"gdal",
|
||||
{
|
||||
"name": "vtk",
|
||||
"default-features": false,
|
||||
"features": [
|
||||
"mpi"
|
||||
]
|
||||
}
|
||||
]
|
||||
},
|
||||
"geojson": {
|
||||
"description": "Convert Geo JSON format to vtkPolyData"
|
||||
},
|
||||
"mpi": {
|
||||
"description": "MPI functionality for VTK",
|
||||
"dependencies": [
|
||||
{
|
||||
"name": "hdf5",
|
||||
"default-features": false,
|
||||
"features": [
|
||||
"parallel"
|
||||
]
|
||||
},
|
||||
"mpi",
|
||||
{
|
||||
"name": "vtk-m",
|
||||
"default-features": false,
|
||||
"features": [
|
||||
"mpi"
|
||||
]
|
||||
}
|
||||
]
|
||||
},
|
||||
"opengl": {
|
||||
"description": "All opengl related modules",
|
||||
"dependencies": [
|
||||
{
|
||||
"name": "vtk",
|
||||
"default-features": false
|
||||
}
|
||||
]
|
||||
},
|
||||
"openvr": {
|
||||
"description": "OpenVR functionality for VTK",
|
||||
"dependencies": [
|
||||
"openvr",
|
||||
"sdl2"
|
||||
]
|
||||
},
|
||||
"paraview": {
|
||||
"description": "Build vtk modules required by paraview",
|
||||
"dependencies": [
|
||||
{
|
||||
"name": "vtk",
|
||||
"default-features": false,
|
||||
"features": [
|
||||
"qt"
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "vtk",
|
||||
"default-features": false,
|
||||
"features": [
|
||||
"atlmfc"
|
||||
],
|
||||
"platform": "windows"
|
||||
}
|
||||
]
|
||||
},
|
||||
"python": {
|
||||
"description": "Python functionality for VTK",
|
||||
"dependencies": [
|
||||
"python3"
|
||||
]
|
||||
},
|
||||
"qt": {
|
||||
"description": "Qt functionality for VTK",
|
||||
"dependencies": [
|
||||
"qt5-imageformats",
|
||||
"qt5-tools",
|
||||
{
|
||||
"name": "qt5-x11extras",
|
||||
"platform": "linux"
|
||||
},
|
||||
"qt5-xmlpatterns"
|
||||
]
|
||||
},
|
||||
"utf8": {
|
||||
"description": "Enables vtk reader/writer with utf-8 path support",
|
||||
"dependencies": [
|
||||
{
|
||||
"name": "vtk",
|
||||
"default-features": false
|
||||
}
|
||||
]
|
||||
},
|
||||
"vtkm": {
|
||||
"description": "Build with vtk-m accelerator and module.",
|
||||
"dependencies": [
|
||||
{
|
||||
"name": "vtk-m",
|
||||
"default-features": false
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
||||
}
|
||||
168
externals/vcpkg/ports/vtk/vtkm.patch
vendored
Executable file
168
externals/vcpkg/ports/vtk/vtkm.patch
vendored
Executable file
@@ -0,0 +1,168 @@
|
||||
diff --git a/Accelerators/Vtkm/Core/CMakeLists.txt b/Accelerators/Vtkm/Core/CMakeLists.txt
|
||||
index b889a771f..317d83f75 100644
|
||||
--- a/Accelerators/Vtkm/Core/CMakeLists.txt
|
||||
+++ b/Accelerators/Vtkm/Core/CMakeLists.txt
|
||||
@@ -14,8 +14,9 @@
|
||||
##
|
||||
##=============================================================================
|
||||
|
||||
-list(INSERT 0 CMAKE_MODULE_PATH
|
||||
- "${VTK_SOURCE_DIR}/ThirdParty/vtkm/vtkvtkm/vtk-m/CMake")
|
||||
+find_package(VTKm CONFIG REQUIRED)
|
||||
+#list(INSERT 0 CMAKE_MODULE_PATH
|
||||
+# "${VTK_SOURCE_DIR}/ThirdParty/vtkm/vtkvtkm/vtk-m/CMake")
|
||||
|
||||
set(private_headers
|
||||
vtkmlib/DataArrayConverters.hxx
|
||||
@@ -77,9 +78,9 @@ vtkm_add_target_information(${vtkm_accel_target}
|
||||
MODIFY_CUDA_FLAGS
|
||||
DEVICE_SOURCES ${sources})
|
||||
|
||||
-vtk_module_set_property(VTK::AcceleratorsVTKmCore
|
||||
- PROPERTY JOB_POOL_COMPILE
|
||||
- VALUE vtkm_pool)
|
||||
+#vtk_module_set_property(VTK::AcceleratorsVTKmCore
|
||||
+# PROPERTY JOB_POOL_COMPILE
|
||||
+# VALUE vtkm_pool)
|
||||
|
||||
if (TARGET vtkm::cuda)
|
||||
vtk_module_set_property(VTK::AcceleratorsVTKmCore
|
||||
diff --git a/Accelerators/Vtkm/DataModel/CMakeLists.txt b/Accelerators/Vtkm/DataModel/CMakeLists.txt
|
||||
index 56307be8d..30fff98e8 100644
|
||||
--- a/Accelerators/Vtkm/DataModel/CMakeLists.txt
|
||||
+++ b/Accelerators/Vtkm/DataModel/CMakeLists.txt
|
||||
@@ -14,8 +14,9 @@
|
||||
##
|
||||
##=============================================================================
|
||||
|
||||
-list(INSERT 0 CMAKE_MODULE_PATH
|
||||
- "${VTK_SOURCE_DIR}/ThirdParty/vtkm/vtkvtkm/vtk-m/CMake")
|
||||
+find_package(VTKm CONFIG REQUIRED)
|
||||
+#list(INSERT 0 CMAKE_MODULE_PATH
|
||||
+# "${VTK_SOURCE_DIR}/ThirdParty/vtkm/vtkvtkm/vtk-m/CMake")
|
||||
|
||||
set(sources
|
||||
vtkmlib/ArrayConvertersReal.cxx
|
||||
@@ -85,9 +86,9 @@ vtkm_add_target_information(${vtkm_accel_target}
|
||||
MODIFY_CUDA_FLAGS
|
||||
DEVICE_SOURCES ${sources})
|
||||
|
||||
-vtk_module_set_property(VTK::AcceleratorsVTKmDataModel
|
||||
- PROPERTY JOB_POOL_COMPILE
|
||||
- VALUE vtkm_pool)
|
||||
+#vtk_module_set_property(VTK::AcceleratorsVTKmDataModel
|
||||
+# PROPERTY JOB_POOL_COMPILE
|
||||
+# VALUE vtkm_pool)
|
||||
|
||||
if (TARGET vtkm::cuda)
|
||||
vtk_module_set_property(VTK::AcceleratorsVTKmDataModel
|
||||
diff --git a/Accelerators/Vtkm/Filters/CMakeLists.txt b/Accelerators/Vtkm/Filters/CMakeLists.txt
|
||||
index 14e84f1dd..0a931285d 100644
|
||||
--- a/Accelerators/Vtkm/Filters/CMakeLists.txt
|
||||
+++ b/Accelerators/Vtkm/Filters/CMakeLists.txt
|
||||
@@ -14,8 +14,9 @@
|
||||
##
|
||||
##=============================================================================
|
||||
|
||||
-list(INSERT 0 CMAKE_MODULE_PATH
|
||||
- "${VTK_SOURCE_DIR}/ThirdParty/vtkm/vtkvtkm/vtk-m/CMake")
|
||||
+find_package(VTKm CONFIG REQUIRED)
|
||||
+#list(INSERT 0 CMAKE_MODULE_PATH
|
||||
+# "${VTK_SOURCE_DIR}/ThirdParty/vtkm/vtkvtkm/vtk-m/CMake")
|
||||
|
||||
set(impl_classes
|
||||
vtkmAverageToCells
|
||||
@@ -80,9 +81,9 @@ vtkm_add_target_information(${vtkm_accel_target}
|
||||
MODIFY_CUDA_FLAGS
|
||||
DEVICE_SOURCES ${sources})
|
||||
|
||||
-vtk_module_set_property(VTK::AcceleratorsVTKmFilters
|
||||
- PROPERTY JOB_POOL_COMPILE
|
||||
- VALUE vtkm_pool)
|
||||
+#vtk_module_set_property(VTK::AcceleratorsVTKmFilters
|
||||
+# PROPERTY JOB_POOL_COMPILE
|
||||
+# VALUE vtkm_pool)
|
||||
vtk_module_link(VTK::AcceleratorsVTKmFilters
|
||||
PRIVATE
|
||||
vtkm_worklet
|
||||
diff --git a/CMake/vtk-config.cmake.in b/CMake/vtk-config.cmake.in
|
||||
index 5a5e8b8df..96413875f 100644
|
||||
--- a/CMake/vtk-config.cmake.in
|
||||
+++ b/CMake/vtk-config.cmake.in
|
||||
@@ -121,9 +121,7 @@ set("${CMAKE_FIND_PACKAGE_NAME}_AVAILABLE_COMPONENTS" "@vtk_all_components@")
|
||||
unset("${CMAKE_FIND_PACKAGE_NAME}_FOUND")
|
||||
set("${CMAKE_FIND_PACKAGE_NAME}_HAS_VTKm" "@vtk_has_vtkm@")
|
||||
if (${CMAKE_FIND_PACKAGE_NAME}_HAS_VTKm)
|
||||
- find_package(VTKm
|
||||
- PATHS "${CMAKE_CURRENT_LIST_DIR}/vtkm"
|
||||
- NO_DEFAULT_PATH)
|
||||
+ find_package(VTKm CONFIG REQUIRED)
|
||||
if (NOT VTKm_FOUND)
|
||||
set("${CMAKE_FIND_PACKAGE_NAME}_FOUND" 0)
|
||||
endif ()
|
||||
diff --git a/ThirdParty/vtkm/CMakeLists.txt b/ThirdParty/vtkm/CMakeLists.txt
|
||||
index 5817d42f8..f21d17da8 100644
|
||||
--- a/ThirdParty/vtkm/CMakeLists.txt
|
||||
+++ b/ThirdParty/vtkm/CMakeLists.txt
|
||||
@@ -1,6 +1,41 @@
|
||||
-vtk_module_third_party_internal(
|
||||
- LICENSE_FILES "vtkvtkm/vtk-m/LICENSE.txt"
|
||||
- VERSION "master"
|
||||
- SUBDIRECTORY vtkvtkm
|
||||
- STANDARD_INCLUDE_DIRS
|
||||
- INTERFACE)
|
||||
+#vtk_module_third_party_internal(
|
||||
+# LICENSE_FILES "vtkvtkm/vtk-m/LICENSE.txt"
|
||||
+# VERSION "master"
|
||||
+# SUBDIRECTORY vtkvtkm
|
||||
+# STANDARD_INCLUDE_DIRS
|
||||
+# INTERFACE)
|
||||
+
|
||||
+message(STATUS "VTK_MODULE_USE_EXTERNAL_VTK_vtkm: ${VTK_MODULE_USE_EXTERNAL_VTK_vtkm}")
|
||||
+if(TRUE)
|
||||
+ message(STATUS "Searching for external VTKm")
|
||||
+ find_package(VTKm CONFIG REQUIRED)
|
||||
+ if(TARGET vtkm_compiler_flags)
|
||||
+ get_target_property(VTKm_INCLUDE_DIRS vtkm_compiler_flags INTERFACE_INCLUDE_DIRECTORIES)
|
||||
+ message(STATUS "INCLUDE: ${VTKm_INCLUDE_DIRS}")
|
||||
+ get_target_property(VTKm_DIY_INCLUDE_DIRS vtkm_diy INTERFACE_INCLUDE_DIRECTORIES)
|
||||
+ get_target_property(VTKm_OPTION_INCLUDE_DIRS vtkm_optionparser INTERFACE_INCLUDE_DIRECTORIES)
|
||||
+ if(MSVC)
|
||||
+ set(VTKm_DEFINITIONS /bigobj)
|
||||
+ endif()
|
||||
+ else()
|
||||
+ message(FATAL_ERROR "VTKM target missing")
|
||||
+ endif()
|
||||
+ if(VTKM_FOUND)
|
||||
+ message(STATUS "Found VTKm")
|
||||
+ endif()
|
||||
+endif()
|
||||
+
|
||||
+vtk_module_third_party(
|
||||
+ INTERNAL
|
||||
+ HEADER_ONLY
|
||||
+ LICENSE_FILES "vtkvtkm/vtk-m/LICENSE.txt"
|
||||
+ VERSION "master"
|
||||
+ SUBDIRECTORY vtkvtkm
|
||||
+ STANDARD_INCLUDE_DIRS
|
||||
+ INTERFACE
|
||||
+ EXTERNAL
|
||||
+ PACKAGE VTKm
|
||||
+ TARGETS vtkm_cont vtkm_filter vtkm_diy vtkm_optionparser vtkm_taotuple
|
||||
+ #LIBRARIES vtkm_cont vtkm_filter vtkm_diy vtkm_optionparser vtkm_taotuple
|
||||
+ INCLUDE_DIRS VTKm_INCLUDE_DIRS VTKm_DIY_INCLUDE_DIRS VTKm_OPTION_INCLUDE_DIRS
|
||||
+)
|
||||
\ No newline at end of file
|
||||
diff --git a/ThirdParty/vtkm/vtk.module b/ThirdParty/vtkm/vtk.module
|
||||
index a8e4dad0f..c7bbbf0e8 100644
|
||||
--- a/ThirdParty/vtkm/vtk.module
|
||||
+++ b/ThirdParty/vtkm/vtk.module
|
||||
@@ -3,5 +3,7 @@ NAME
|
||||
PRIVATE_DEPENDS
|
||||
# While not needed to satisfy symbols, this is necessary to guarantee that
|
||||
# VTK_SMP_IMPLEMENTATION_TYPE is available when configuring vtk-m.
|
||||
- VTK::CommonCore
|
||||
+ # VTK::CommonCore
|
||||
+LIBRARY_NAME
|
||||
+ VTKm
|
||||
THIRD_PARTY
|
||||
Reference in New Issue
Block a user