Revision: 2629
          http://rigsofrods.svn.sourceforge.net/rigsofrods/?rev=2629&view=rev
Author:   ulteq
Date:     2012-05-22 08:16:58 +0000 (Tue, 22 May 2012)
Log Message:
-----------
-Bugfix: Corrects the survey map rendering!

Modified Paths:
--------------
    trunk/source/main/gui/MapTextureCreator.cpp

Modified: trunk/source/main/gui/MapTextureCreator.cpp
===================================================================
--- trunk/source/main/gui/MapTextureCreator.cpp 2012-05-22 08:15:54 UTC (rev 
2628)
+++ trunk/source/main/gui/MapTextureCreator.cpp 2012-05-22 08:16:58 UTC (rev 
2629)
@@ -48,15 +48,15 @@
 
 bool MapTextureCreator::init()
 {
-       TexturePtr texture = 
TextureManager::getSingleton().createManual("MapRttTex" + TOSTRING(mCounter), 
ResourceGroupManager::DEFAULT_RESOURCE_GROUP_NAME, TEX_TYPE_2D, 1024, 1024, 0, 
PF_R8G8B8, TU_RENDERTARGET, new ResourceBuffer());
+       TexturePtr texture = 
TextureManager::getSingleton().createManual("MapRttTex" + TOSTRING(mCounter), 
ResourceGroupManager::DEFAULT_RESOURCE_GROUP_NAME, TEX_TYPE_2D, 2048, 2048, 
TU_RENDERTARGET, PF_R8G8B8, TU_RENDERTARGET, new ResourceBuffer());
        
        if ( texture.isNull() ) return false;;
 
        mRttTex = texture->getBuffer()->getRenderTarget();
 
-       if ( !mRttTex ) return false;;
+       if ( !mRttTex ) return false;
 
-       mRttTex->setAutoUpdated(true);
+       mRttTex->setAutoUpdated(false);
 
        mCamera = mSceneManager->createCamera("MapRenderCam" + 
TOSTRING(mCounter));
 
@@ -72,7 +72,7 @@
 
        mRttTex->addListener(this);
 
-       mCamera->setFarClipDistance(0.0f);
+       mCamera->setFarClipDistance(1000.0f);
        mCamera->setAspectRatio(1.0f);
        mCamera->setFixedYawAxis(false);
        mCamera->setProjectionType(PT_ORTHOGRAPHIC);
@@ -114,7 +114,7 @@
 
        float width = mEfl->mapsizex;
        float height = mEfl->mapsizez;
-       float zoomFactor = mCamZoom * ((width + height) / 2.0f) * 0.002f;
+       float zoomFactor = mCamZoom * ((width + height) / 2.0f) * 0.1f;
 
        mCamera->setNearClipDistance(mCamZoom);
        mCamera->setPosition(mCamLookAt + Vector3(0.0f, zoomFactor, 0.0f));
@@ -155,13 +155,6 @@
                }
        }
 
-       Water *w = mEfl->getWater();
-
-       if ( w )
-       {
-               w->setVisible(false);
-       }
-
        if ( mStatics )
        {
                mStatics->setRenderingDistance(0);
@@ -180,13 +173,6 @@
                }
        }
 
-       Water *w = mEfl->getWater();
-
-       if ( w )
-       {
-               w->setVisible(true);
-       }
-
        if ( mStatics )
        {
                mStatics->setRenderingDistance(1000);

This was sent by the SourceForge.net collaborative development platform, the 
world's largest Open Source development site.


------------------------------------------------------------------------------
Live Security Virtual Conference
Exclusive live event will cover all the ways today's security and 
threat landscape has changed and how IT managers can respond. Discussions 
will include endpoint security, mobile security and the latest in malware 
threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/
_______________________________________________
Rigsofrods-devel mailing list
Rigsofrods-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/rigsofrods-devel

Reply via email to