mirror of
https://gitlab.kitware.com/vtk/vtk-m
synced 2024-09-08 13:23:51 +00:00
Consistenly use nullptr in vtk-m.
This commit is contained in:
parent
83165f0cde
commit
fe8b75f7bf
@ -38,7 +38,7 @@ struct TestExecObject
|
||||
{
|
||||
VTKM_EXEC_CONT
|
||||
TestExecObject()
|
||||
: Value(NULL)
|
||||
: Value(nullptr)
|
||||
{
|
||||
}
|
||||
|
||||
|
@ -109,7 +109,7 @@ class FunctionInterfaceDynamicTransformContContinue;
|
||||
/// place. The \c FunctionInterface template class takes a function signature,
|
||||
/// which can have a variable number of arguments. The \c FunctionInterface
|
||||
/// will hold in its state a copy of all input parameters (regardless of number
|
||||
/// or type) and the return value if it exists (i.e. non-null) and the function
|
||||
/// or type) and the return value if it exists (i.e. non-nullptr) and the function
|
||||
/// has been invoked. This means that all arguments can be passed around in a
|
||||
/// single object so that objects and functions dealing with these variadic
|
||||
/// parameters can be templated on a single type (the type of \c
|
||||
|
@ -240,7 +240,7 @@ private:
|
||||
{
|
||||
FILE* fp = fopen(fName.c_str(), "rb");
|
||||
size_t readSize = static_cast<size_t>(sz);
|
||||
if (fp == NULL)
|
||||
if (fp == nullptr)
|
||||
throw vtkm::io::ErrorIO("Unable to open data file: " + fName);
|
||||
buff.resize(readSize);
|
||||
size_t nread = fread(&buff[0], sizeof(T), readSize, fp);
|
||||
|
@ -182,7 +182,7 @@ public:
|
||||
void Trace(const vtkm::rendering::Camera& camera, vtkm::rendering::CanvasRayTracer* canvas)
|
||||
{
|
||||
|
||||
if (canvas == NULL)
|
||||
if (canvas == nullptr)
|
||||
{
|
||||
std::cout << "Conn proxy: canvas is NULL\n";
|
||||
throw vtkm::cont::ErrorBadValue("Conn Proxy: null canvas");
|
||||
|
@ -37,7 +37,7 @@ namespace rendering
|
||||
VTKM_CONT
|
||||
MapperConnectivity::MapperConnectivity()
|
||||
{
|
||||
CanvasRT = NULL;
|
||||
CanvasRT = nullptr;
|
||||
SampleDistance = -1;
|
||||
}
|
||||
|
||||
@ -55,11 +55,11 @@ void MapperConnectivity::SetSampleDistance(const vtkm::Float32& distance)
|
||||
VTKM_CONT
|
||||
void MapperConnectivity::SetCanvas(Canvas* canvas)
|
||||
{
|
||||
if (canvas != NULL)
|
||||
if (canvas != nullptr)
|
||||
{
|
||||
|
||||
CanvasRT = dynamic_cast<CanvasRayTracer*>(canvas);
|
||||
if (CanvasRT == NULL)
|
||||
if (CanvasRT == nullptr)
|
||||
{
|
||||
throw vtkm::cont::ErrorBadValue("Volume Render: bad canvas type. Must be CanvasRayTracer");
|
||||
}
|
||||
|
@ -115,7 +115,7 @@ public:
|
||||
{
|
||||
throw vtkm::cont::ErrorBadValue("Connectivity tracer: cell set type unsupported");
|
||||
}
|
||||
return NULL;
|
||||
return nullptr;
|
||||
}
|
||||
};
|
||||
}
|
||||
|
@ -26,7 +26,7 @@ namespace rendering
|
||||
namespace raytracing
|
||||
{
|
||||
|
||||
Logger* Logger::Instance = NULL;
|
||||
Logger* Logger::Instance = nullptr;
|
||||
|
||||
Logger::Logger()
|
||||
{
|
||||
@ -39,7 +39,7 @@ Logger::~Logger()
|
||||
|
||||
Logger* Logger::GetInstance()
|
||||
{
|
||||
if (Instance == NULL)
|
||||
if (Instance == nullptr)
|
||||
{
|
||||
Instance = new Logger();
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user