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

Method spinOnce

visualization/src/pcl_plotter.cpp:412–431  ·  view source on GitHub ↗

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

Source from the content-addressed store, hash-verified

410
411//////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
412void
413pcl::visualization::PCLPlotter::spinOnce (const int spin_time)
414{
415 //apply current states
416 view_->GetRenderer ()->SetBackground (bkg_color_[0], bkg_color_[1], bkg_color_[2]);
417 view_->GetRenderWindow ()->SetSize (win_width_, win_height_);
418
419 //start timer to spin
420 if (!view_->GetInteractor ()->GetEnabled ())
421 {
422 view_->GetInteractor ()->Initialize ();
423 view_->GetInteractor ()->AddObserver (vtkCommand::TimerEvent, exit_loop_timer_);
424 view_->GetInteractor ()->AddObserver (vtkCommand::ExitEvent, exit_callback_);
425 }
426 exit_loop_timer_->right_timer_id = view_->GetInteractor()->CreateOneShotTimer (spin_time);
427
428 // Start spinning
429 view_->GetRenderWindow ()->Render ();
430 view_->GetInteractor()->Start();
431}
432
433//////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
434void

Callers

nothing calls this directly

Calls 1

InitializeMethod · 0.45

Tested by

no test coverage detected