
but now light seems to be always the same



There are a large number of settings for lighting. Caelum will try to autoConfigure some reasonable defaults but those don't seem to work here. Looks like ambient is always maxed out; are you sure CaelumSystem::setManageAmbientLight is set to true? If so; check out the light multipliers for the sun and moon (check out the BaseSkyLight reference).netskate wrote:but now light seems to be always the same
Code: Select all
mHydrax->setSunPosition(mCaelumSystem->getSun()->getMainLight()->getPosition());
Vector3 colore_sole;
colore_sole.x=mCaelumSystem->getSun()->getLightColour().r;
colore_sole.y=mCaelumSystem->getSun()->getLightColour().g;
colore_sole.z=mCaelumSystem->getSun()->getLightColour().b;
mHydrax->setSunColor(colore_sole);
Code: Select all
Root::getSingletonPtr()->addFrameListener (mCaelumSystem);
mCaelumSystem->setPrecipitationController (new PrecipitationController (sceneMgr));
mCaelumSystem->getPrecipitationController()->setPresetType(Caelum::PRECTYPE_RAIN);
mCaelumSystem->getPrecipitationController()->setSpeed(100);
mCaelumSystem->getPrecipitationController()->setIntensity(100);
I don't know why that would happen. Could you paste the last few lines of the log? Maybe goes wrong on attaching the compositor?netskate wrote:I resolve with terrain
now, I'm looking precipitation on caelum lab but when I move the slider seems to crash.
The image is always stopped, but I can use the gui
Oh yes...that was the other part of the assert. It said, "Cannot find the center of an infinite or null AAB." I think I now have some direction. I'll try to get a call stack posted tonight.cdleonard wrote:@Fish: The PointStarfield class always wants to be visible so I made it report an infinite bounding box. The other components don't do that. It could be that PCZSceneMananager doesn't properly deal with an infinite bounding box. The bounding box could also be null by mistake at some point. Maybe you could post a callstack?
Here is the stack trace:cdleonard wrote:@Fish: Maybe you could post a callstack?
Code: Select all
assert: "Can't get center of a null or infinite AAB" Line 691
OgreMain_d.dll!Ogre::AxisAlignedBox::getCenter() Line 691
Plugin_PCZSceneManager_d.dll!Ogre::PCZFrustum::isVisible(const Ogre::AxisAlignedBox & bound={...}) Line 83 + 0xf bytes
Plugin_PCZSceneManager_d.dll!Ogre::PCZCamera::isVisible(const Ogre::AxisAlignedBox & bound={...}, Ogre::FrustumPlane * culledBy=0x00000000) Line 73 + 0x12 bytes
Plugin_PCZSceneManager_d.dll!Ogre::DefaultZone::findVisibleNodes(Ogre::PCZCamera * camera=0x0161d1f8, std::list<Ogre::SceneNode *,std::allocator<Ogre::SceneNode *> > & visibleNodeList=[1](0x06054cb0 {mNewPosition={...} mHomeZone=0x0161cf50 mAnchored=false ...}), Ogre::RenderQueue * queue=0x01674df0, Ogre::VisibleObjectsBoundsInfo * visibleBounds=0x0161dab8, bool onlyShadowCasters=false, bool displayNodes=false, bool showBoundingBoxes=false) Line 483 + 0x2e bytes
Plugin_PCZSceneManager_d.dll!Ogre::PCZSceneManager::_findVisibleObjects(Ogre::Camera * cam=0x0161d1f8, Ogre::VisibleObjectsBoundsInfo * visibleBounds=0x0161dab8, bool onlyShadowCasters=false) Line 1131 + 0x53 bytes
OgreMain_d.dll!Ogre::SceneManager::_renderScene(Ogre::Camera * camera=0x0161d1f8, Ogre::Viewport * vp=0x0161e2f0, bool includeOverlays=true) Line 1298 + 0x30 bytes
Plugin_PCZSceneManager_d.dll!Ogre::PCZSceneManager::_renderScene(Ogre::Camera * cam=0x0161d1f8, Ogre::Viewport * vp=0x0161e2f0, bool includeOverlays=true) Line 409 + 0x17 bytes
OgreMain_d.dll!Ogre::Camera::_renderScene(Ogre::Viewport * vp=0x0161e2f0, bool includeOverlays=true) Line 398 + 0x2c bytes
OgreMain_d.dll!Ogre::Viewport::update() Line 193
OgreMain_d.dll!Ogre::RenderTarget::updateImpl() Line 114
OgreMain_d.dll!Ogre::RenderTarget::update(bool swap=false) Line 501 + 0x12 bytes
OgreMain_d.dll!Ogre::RenderSystem::_updateAllRenderTargets(bool swapBuffers=false) Line 112 + 0x2a bytes
OgreMain_d.dll!Ogre::Root::_updateAllRenderTargets() Line 1130 + 0x1c bytes
OgreMain_d.dll!Ogre::Root::renderOneFrame() Line 839 + 0x8 bytes
OgreMain_d.dll!Ogre::Root::startRendering() Line 829 + 0x8 bytes
Because the movement is done in a plane. The parameter is a speed vector in the plane.netskate wrote:why setCloudSpeed take a Vector2?
You have to do your own fading here.netskate wrote:Also, when setting a cloud coverage setting it update from precedent value to final value with no transition.
there is a function to do it, or I need to code a sort of fading function?
thank you!Kencho wrote:I bet you aren't overriding the fog settings in your particle materials. So, when the fog is not-black, particles are brighter, and give a strange behavior with additive blending. The same happens with modulative blending when the fog is non-white. Alpha blending is fog-safe though.
Code: Select all
Caelum::CaelumSystem::CaelumComponent componentMask;
componentMask = CaelumSystem::CAELUM_COMPONENTS_DEFAULT;
m_Caelum = new Caelum::CaelumSystem (Root::getSingletonPtr(), m_SceneManager, componentMask);
m_Caelum->getUniversalClock()->setTimeScale(512);
m_Window->addListener(m_Caelum);
Root::getSingletonPtr()->addFrameListener(m_Caelum);