Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use nullptr in module examples #3007

Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion examples/outofcore/example_outofcore.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,7 @@ int main (int, char** argv)
OutofcoreDepthFirstIterator<pcl::PointXYZ, pcl::outofcore::OutofcoreOctreeDiskContainer<pcl::PointXYZ> > it (*octree);
OctreeDisk::Iterator myit (*octree);

while ( *myit !=0 )
while ( *myit !=nullptr )
{
octree->printBoundingBox (**myit);
myit++;
Expand Down
4 changes: 2 additions & 2 deletions examples/segmentation/example_cpc_segmentation.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -459,7 +459,7 @@ CPCSegmentation Parameters: \n\
const unsigned char concave_color [3] = {255, 0, 0};
const unsigned char cut_color [3] = { 0,255, 0};
const unsigned char* convex_color = bg_white ? black_color : white_color;
const unsigned char* color = NULL;
const unsigned char* color = nullptr;

//The vertices in the supervoxel adjacency list are the supervoxel centroids
//This iterates through them, finding the edges
Expand Down Expand Up @@ -529,7 +529,7 @@ CPCSegmentation Parameters: \n\
pcl::visualization::PCLVisualizer::Ptr viewer (new pcl::visualization::PCLVisualizer ("3D Viewer"));
float bg_color = bg_white?1:0;
viewer->setBackgroundColor (bg_color, bg_color, bg_color);
viewer->registerKeyboardCallback (keyboardEventOccurred, 0);
viewer->registerKeyboardCallback (keyboardEventOccurred, nullptr);
viewer->addPointCloud (cpc_labeled_cloud, "cpc_cloud");
/// Visualization Loop
PCL_INFO ("Loading viewer\n");
Expand Down
2 changes: 1 addition & 1 deletion examples/segmentation/example_lccp_segmentation.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -450,7 +450,7 @@ LCCPSegmentation Parameters: \n\
/// Configure Visualizer
pcl::visualization::PCLVisualizer::Ptr viewer (new pcl::visualization::PCLVisualizer ("3D Viewer"));
viewer->setBackgroundColor (0, 0, 0);
viewer->registerKeyboardCallback (keyboardEventOccurred, 0);
viewer->registerKeyboardCallback (keyboardEventOccurred, nullptr);
viewer->addPointCloud (lccp_labeled_cloud, "maincloud");

/// Visualization Loop
Expand Down
2 changes: 1 addition & 1 deletion examples/segmentation/example_supervoxels.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -343,7 +343,7 @@ main (int argc, char ** argv)
std::cout << "Loading visualization...\n";
pcl::visualization::PCLVisualizer::Ptr viewer (new pcl::visualization::PCLVisualizer ("3D Viewer"));
viewer->setBackgroundColor (0, 0, 0);
viewer->registerKeyboardCallback(keyboard_callback, 0);
viewer->registerKeyboardCallback(keyboard_callback, nullptr);


bool refined_normal_shown = show_refined;
Expand Down
4 changes: 2 additions & 2 deletions examples/surface/example_nurbs_viewer_surface.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ main (int argc, char *argv[])
}

const ON_Object* on_object = on_model.m_object_table[0].m_object;
if(on_object==NULL)
if(on_object==nullptr)
{
std::cout << "object[0] not valid." << std::endl;
return -1;
Expand All @@ -68,7 +68,7 @@ main (int argc, char *argv[])
else
{
on_object = on_model.m_object_table[1].m_object;
if(on_object==NULL)
if(on_object==nullptr)
{
std::cout << "object[1] not valid." << std::endl;
return -1;
Expand Down