本文整理汇总了C++中Quad::getAverageHeight方法的典型用法代码示例。如果您正苦于以下问题:C++ Quad::getAverageHeight方法的具体用法?C++ Quad::getAverageHeight怎么用?C++ Quad::getAverageHeight使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Quad
的用法示例。
在下文中一共展示了Quad::getAverageHeight方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: calculatePositions
Goal::Goal(VFO_ID id, const Quad &corners)
{
m_id = id;
m_corners = corners;
m_location.screen = corners.getBottomCentre();
m_size_on_screen = Vector2<double>(corners.getAverageWidth(), corners.getAverageHeight());
// if(VisionConstants::DO_RADIAL_CORRECTION) {
// VisionBlackboard* vbb = VisionBlackboard::getInstance();
// Vector2<float> corr_bottom_centre = vbb->correctDistortion(Vector2<float>(m_bottom_centre.x, m_bottom_centre.y));
// m_bottom_centre.x = mathGeneral::roundNumberToInt(corr_bottom_centre.x);
// m_bottom_centre.y = mathGeneral::roundNumberToInt(corr_bottom_centre.y);
// }
//CALCULATE DISTANCE AND BEARING VALS
valid = calculatePositions();
//valid = valid && check();
valid = check();
}
示例2: getBoundingBox
arma::vec2 Quad::getSize() const {
Quad boundingBox = getBoundingBox(getVertices());
return {boundingBox.getAverageWidth(), boundingBox.getAverageHeight()};
}