本文整理汇总了C++中Viewport::getBottom方法的典型用法代码示例。如果您正苦于以下问题:C++ Viewport::getBottom方法的具体用法?C++ Viewport::getBottom怎么用?C++ Viewport::getBottom使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Viewport
的用法示例。
在下文中一共展示了Viewport::getBottom方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: renderEnter
ActionBase::ResultE HDRStage::renderEnter(Action *action)
{
RenderAction *a = dynamic_cast<RenderAction *>(action);
a->disableDefaultPartition();
this->beginPartitionGroup(a);
{
this->pushPartition(a);
{
RenderPartition *pPart = a->getActivePartition();
FrameBufferObject *pTarget = this->getRenderTarget();
Viewport *pPort = a->getViewport();
Camera *pCam = a->getCamera ();
Background *pBack = a->getBackground();
if(pTarget == NULL)
{
this->initData(pPort, a);
pTarget = this->getRenderTarget();
}
pPart->setRenderTarget(pTarget);
#ifdef OSG_DEBUGX
std::string szMessage("RenderPartition\n");
pPart->setDebugString(szMessage );
#endif
if(pPort != NULL)
{
// pPart->setViewport(pPort );
pPart->setWindow (a->getWindow());
if(pTarget != NULL)
{
pPart->calcViewportDimension(pPort->getLeft (),
pPort->getBottom(),
pPort->getRight (),
pPort->getTop (),
pTarget->getWidth (),
pTarget->getHeight ());
}
else
{
pPart->calcViewportDimension(pPort->getLeft (),
pPort->getBottom(),
pPort->getRight (),
pPort->getTop (),
a->getWindow()->getWidth (),
a->getWindow()->getHeight());
}
if(pCam != NULL)
{
Matrix m, t;
// set the projection
pCam->getProjection (m,
pPart->getViewportWidth (),
pPart->getViewportHeight());
pCam->getProjectionTranslation(t,
pPart->getViewportWidth (),
pPart->getViewportHeight());
pPart->setupProjection(m, t);
pCam->getViewing(m,
pPart->getViewportWidth (),
pPart->getViewportHeight());
pPart->setupViewing(m);
pPart->setNear (pCam->getNear());
pPart->setFar (pCam->getFar ());
pPart->calcFrustum();
}
pPart->setBackground(pBack);
}
this->recurseFromThis(a);
}
this->popPartition(a);
this->pushPartition(a,
(RenderPartition::CopyWindow |
RenderPartition::CopyViewportSize),
RenderPartition::SimpleCallback );
{
RenderPartition *pPart = a->getActivePartition();
#ifdef OSG_DEBUGX
std::string szMessage("PostProcessPartition\n");
//.........这里部分代码省略.........