mirror of
https://github.com/OPM/ResInsight.git
synced 2025-02-25 18:55:39 -06:00
Integrated visualization modules to changelist 20202
p4#: 20204
This commit is contained in:
@@ -324,8 +324,10 @@ bool caf::Viewer::rayPick(int winPosX, int winPosY, cvf::HitItemCollection* pick
|
||||
{
|
||||
CVF_ASSERT(m_mainRendering.notNull());
|
||||
|
||||
int translatedMousePosX = winPosX;
|
||||
int translatedMousePosY = height() - winPosY;
|
||||
|
||||
cvf::ref<cvf::RayIntersectSpec> ris = m_mainRendering->createRayIntersectSpec(winPosX, winPosY);
|
||||
cvf::ref<cvf::RayIntersectSpec> ris = m_mainRendering->rayIntersectSpecFromWindowCoordinates(translatedMousePosX, translatedMousePosY);
|
||||
if (ris.notNull())
|
||||
{
|
||||
bool retVal = m_mainRendering->rayIntersect(*ris, pickedPoints);
|
||||
@@ -545,9 +547,8 @@ void caf::Viewer::releaseOGlResourcesForCurrentFrame()
|
||||
{
|
||||
cvf::Scene* currentScene = m_renderingSequence->firstRendering()->scene();
|
||||
makeCurrent();
|
||||
size_t modelCount = currentScene->modelCount();
|
||||
size_t i;
|
||||
for (i = 0; i < modelCount; ++i)
|
||||
cvf::uint modelCount = currentScene->modelCount();
|
||||
for (cvf::uint i = 0; i < modelCount; ++i)
|
||||
{
|
||||
cvf::Collection<cvf::Part> partCollection;
|
||||
currentScene->model(i)->allParts(&partCollection);
|
||||
|
||||
Reference in New Issue
Block a user