Main MRPT website > C++ reference for MRPT 1.5.6
Functions
Round functions (in #include <mrpt/utils/round.h>)

Detailed Description

Collaboration diagram for Round functions (in #include <mrpt/utils/round.h>):

Functions

template<typename T >
int mrpt::utils::round (const T value)
 Returns the closer integer (int) to x. More...
 
template<typename T >
long mrpt::utils::round_long (const T value)
 Returns the closer integer (long) to x. More...
 
template<class T >
mrpt::utils::round_10power (T val, int power10)
 Round a decimal number up to the given 10'th power (eg, to 1000,100,10, and also fractions) power10 means round up to: 1 -> 10, 2 -> 100, 3 -> 1000, ... More...
 

Function Documentation

template<typename T >
int mrpt::utils::round ( const T  value)
inline

Returns the closer integer (int) to x.

Definition at line 26 of file round.h.

Referenced by mrpt::slam::CGridMapAligner::AlignPDF_robustMatch(), mrpt::nav::CParameterizedTrajectoryGenerator::alpha2index(), mrpt::maps::CGasConcentrationGridMap2D::build_Gaussian_Wind_Grid(), mrpt::vision::CDifodo::buildCoordinatesPyramid(), mrpt::vision::CDifodo::buildCoordinatesPyramidFast(), mrpt::maps::COccupancyGridMap2D::buildVoronoiDiagram(), mrpt::nav::CAbstractPTGBasedReactive::calc_move_candidate_scores(), mrpt::nav::CHolonomicND::calcRepresentativeSectorForGap(), mrpt::vision::CDifodo::CDifodo(), mrpt::maps::CLogOddsGridMapLUT< cellType >::CLogOddsGridMapLUT(), mrpt::maps::COccupancyGridMap2D::computeClearance(), mrpt::vision::computeHistogramOfOrientations(), mrpt::maps::COccupancyGridMap2D::computeLikelihoodField_Thrun(), mrpt::vision::computeMoreDescriptors(), mrpt::vision::computeMultiOrientations(), mrpt::vision::computeMultiResolutionDescriptors(), mrpt::maps::COccupancyGridMap2D::computeObservationLikelihood_CellsDifference(), mrpt::maps::COccupancyGridMap2D::computePathCost(), mrpt::utils::CImage::cross_correlation(), mrpt::nav::ClearanceDiagram::decimated_k_to_real_k(), mrpt::system::decodeBase64(), mrpt::maps::COccupancyGridMap2D::determineMatching2D(), mrpt::nav::CHolonomicFullEval::direction2sector(), mrpt::nav::CHolonomicND::direction2sector(), mrpt::utils::CCanvas::drawCircle(), mrpt::slam::CMetricMapBuilderRBPF::drawCurrentEstimationToImage(), mrpt::utils::CCanvas::drawFeatures(), mrpt::utils::CCanvas::drawFeaturesSimple(), mrpt::utils::CEnhancedMetaFile::ellipseGaussian(), mrpt::utils::CCanvas::ellipseGaussian(), mrpt::system::encodeBase64(), mrpt::nav::CParameterizedTrajectoryGenerator::evalClearanceSingleObstacle(), mrpt::nav::CHolonomicFullEval::evalSingleTarget(), mrpt::vision::CFeatureExtraction::extractFeaturesFAST(), mrpt::vision::CFeatureExtraction::extractFeaturesFASTER_N(), mrpt::vision::CFeatureExtraction::extractFeaturesKLT(), mrpt::vision::CFeatureExtraction::extractFeaturesORB(), mrpt::vision::CFeatureExtraction::extractFeaturesSIFT(), mrpt::vision::CFeatureExtraction::extractFeaturesSURF(), mrpt::vision::TSimpleFeatureTraits< TSimpleFeature >::f2coord(), mrpt::maps::COccupancyGridMap2D::findCriticalPoints(), mrpt::obs::CObservationVelodyneScan::generatePointCloud(), mrpt::maps::COccupancyGridMap2D::getAsImageFiltered(), mrpt::nav::CPTG_Holo_Blend::getPathStepForDist(), mrpt::utils::CMappedImage::getPixel(), mrpt::nav::CParameterizedTrajectoryGenerator::initClearanceDiagram(), mrpt::maps::CRandomFieldGridMap2D::insertObservation_KernelDM_DMV(), mrpt::vision::CFeatureExtraction::internal_computeSpinImageDescriptors(), mrpt::maps::CBeaconMap::internal_insertObservation(), mrpt::maps::COccupancyGridMap2D::internal_insertObservation(), mrpt::maps::CPointsMap::internal_insertObservation(), mrpt::slam::KLF_loadBinFromParticle(), mrpt::hmtslam::CLSLAM_RBPF_2DLASER::loadTPathBinFromPath(), mrpt::vision::CDifodo::odometryCalculation(), mrpt::vision::openCV_cross_correlation(), mrpt::vision::CDifodo::performWarping(), mrpt::slam::PF_implementation< PARTICLE_TYPE, MYSELF >::PF_SLAM_implementation_pfAuxiliaryPFStandardAndOptimal(), mrpt::slam::PF_implementation< PARTICLE_TYPE, MYSELF >::PF_SLAM_implementation_pfStandardProposal(), mrpt::poses::CPose2DGridTemplate< double >::phi2idx(), mrpt::obs::detail::project3DPointsFromDepthImageInto(), mrpt::nav::ClearanceDiagram::real_k_to_decimated_k(), mrpt::opengl::CPointCloudColoured::render_subset(), mrpt::opengl::CPointCloud::render_subset(), mrpt::slam::CMonteCarloLocalization2D::resetUniformFreeSpace(), mrpt::utils::CDynamicGrid3D< TRandomFieldVoxel >::resize(), mrpt::utils::CDynamicGrid< TRandomFieldCell >::resize(), mrpt::maps::CRandomFieldGridMap2D::resize(), mrpt::maps::COccupancyGridMap2D::resizeGrid(), mrpt::tfest::se3_l2_robust(), mrpt::nav::CHolonomicND::searchBestGap(), mrpt::vision::TSimpleFeatureList_templ< TSimpleFeature >::setScale(), mrpt::utils::CDynamicGrid< TRandomFieldCell >::setSize(), mrpt::poses::CPose2DGridTemplate< double >::setSize(), mrpt::utils::CDynamicGrid3D< TRandomFieldVoxel >::setSize(), mrpt::maps::COccupancyGridMap2D::setSize(), mrpt::gui::CDisplayWindow::showImageAndPoints(), mrpt::gui::CDisplayWindow::showImagesAndMatchedPoints(), mrpt::maps::CGasConcentrationGridMap2D::simulateAdvection(), mrpt::maps::COccupancyGridMap2D::simulateScanRay(), mrpt::maps::COccupancyGridMap2D::sonarSimulator(), mrpt::maps::COccupancyGridMap2D::subSample(), mrpt::maps::detail::loadFromRangeImpl< Derived >::templ_loadFromRangeScan(), mrpt::vision::detail::trackFeatures_addNewFeats< CFeatureList >(), mrpt::vision::detail::trackFeatures_addNewFeats_simple_list(), mrpt::vision::detail::trackFeatures_updatePatch< CFeatureList >(), mrpt::utils::CCanvas::triangle(), velodyne_scan_to_pointcloud(), mrpt::math::weightedHistogram(), mrpt::math::weightedHistogramLog(), mrpt::poses::CPose2DGridTemplate< double >::x2idx(), and mrpt::poses::CPose2DGridTemplate< double >::y2idx().

template<class T >
T mrpt::utils::round_10power ( val,
int  power10 
)

Round a decimal number up to the given 10'th power (eg, to 1000,100,10, and also fractions) power10 means round up to: 1 -> 10, 2 -> 100, 3 -> 1000, ...

-1 -> 0.1, -2 -> 0.01, ...

Definition at line 72 of file round.h.

References mrpt::utils::round_long().

template<typename T >
long mrpt::utils::round_long ( const T  value)
inline

Returns the closer integer (long) to x.

Definition at line 48 of file round.h.

Referenced by mrpt::utils::round_10power(), and mrpt::maps::CLandmarksMap::simulateRangeBearingReadings().




Page generated by Doxygen 1.8.6 for MRPT 1.5.6 Git: 4c65e84 Tue Apr 24 08:18:17 2018 +0200 at mar abr 24 08:26:17 CEST 2018