本文整理汇总了C++中NodeRefPtr::getWorldVolume方法的典型用法代码示例。如果您正苦于以下问题:C++ NodeRefPtr::getWorldVolume方法的具体用法?C++ NodeRefPtr::getWorldVolume怎么用?C++ NodeRefPtr::getWorldVolume使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类NodeRefPtr
的用法示例。
在下文中一共展示了NodeRefPtr::getWorldVolume方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: selectedNodeChanged
void selectedNodeChanged(void)
{
mgr->setHighlight(SelectedNode);
//Update Details Panel
if(SelectedNode == NULL)
{
NodeNameValueLabel->setText("");
NodeCoreTypeValueLabel->setText("");
NodeMinValueLabel->setText("");
NodeMaxValueLabel->setText("");
NodeCenterValueLabel->setText("");
NodeTriCountValueLabel->setText("");
NodeTravMaskValueLabel->setText("");
NodeOcclusionMaskValueLabel->setText("");
NodeActiveValueLabel->setText("");
}
else
{
const Char8 *NodeName = getName(SelectedNode);
if(NodeName == NULL)
{
NodeNameValueLabel->setText("Unnamed Node");
}
else
{
NodeNameValueLabel->setText(NodeName);
}
NodeCoreTypeValueLabel->setText(SelectedNode->getCore()->getType().getCName());
BoxVolume DyVol;
SelectedNode->getWorldVolume(DyVol);
Pnt3f Min,Max,Center;
DyVol.getBounds(Min,Max);
DyVol.getCenter(Center);
std::string TempText("");
TempText = boost::lexical_cast<std::string>(Min.x()) + ", " +boost::lexical_cast<std::string>(Min.x()) + ", " + boost::lexical_cast<std::string>(Min.x());
NodeMinValueLabel->setText(TempText);
TempText = boost::lexical_cast<std::string>(Max.x()) + ", " +boost::lexical_cast<std::string>(Max.x()) + ", " + boost::lexical_cast<std::string>(Max.x());
NodeMaxValueLabel->setText(TempText);
TempText = boost::lexical_cast<std::string>(Center.x()) + ", " +boost::lexical_cast<std::string>(Center.x()) + ", " + boost::lexical_cast<std::string>(Center.x());
NodeCenterValueLabel->setText(TempText);
//GeometryPrimitivesCounter PrimCounter;
//PrimCounter(SelectedNode);
//NodeTriCountValueLabel->setText(boost::lexical_cast<std::string>(PrimCounter.getTriCount()));
//NodeTravMaskValueLabel->setText(boost::lexical_cast<std::string>(SelectedNode->getTravMask()));
//NodeOcclusionMaskValueLabel->setText(boost::lexical_cast<std::string>(SelectedNode->getOcclusionMask()));
//NodeActiveValueLabel->setText(boost::lexical_cast<std::string>(SelectedNode->getActive()));
}
}