MCPcopy Create free account
hub / github.com/PointCloudLibrary/pcl / timeoutSlot

Method timeoutSlot

apps/src/openni_passthrough.cpp:118–138  ·  view source on GitHub ↗

////////////////////////////////////////////////////////////////////////////////////////////////////

Source from the content-addressed store, hash-verified

116
117/////////////////////////////////////////////////////////////////////////////////////////////////////////
118void
119OpenNIPassthrough::timeoutSlot()
120{
121 if (!cloud_pass_) {
122 std::this_thread::sleep_for(1ms);
123 return;
124 }
125
126 CloudPtr temp_cloud;
127 {
128 QMutexLocker locker(&mtx_);
129 temp_cloud.swap(cloud_pass_);
130 }
131 // Add to the 3D viewer
132 if (!vis_->updatePointCloud(temp_cloud, "cloud_pass")) {
133 vis_->addPointCloud(temp_cloud, "cloud_pass");
134 vis_->resetCameraViewpoint("cloud_pass");
135 }
136 FPS_CALC("visualization");
137 ui_->qvtk_widget->update();
138}
139
140void
141OpenNIPassthrough::refreshView()

Callers

nothing calls this directly

Calls 5

updatePointCloudMethod · 0.80
resetCameraViewpointMethod · 0.80
swapMethod · 0.45
addPointCloudMethod · 0.45
updateMethod · 0.45

Tested by

no test coverage detected