I have one directional light that is working, but when i try adding one point light, the point light is not showing.
code:
Code: Select all
Light* directionalLight = this->sceneManager->createLight();
directionalLight->setType(Light::LT_DIRECTIONAL);
directionalLight->setDiffuseColour(ColourValue(0.4, 0.4, 0.4));
directionalLight->setSpecularColour(ColourValue(0.4, 0.1, 0.1));
directionalLight->setPowerScale(5);
SceneNode* directionalLightNode = this->sceneManager->getRootSceneNode()->createChildSceneNode();
directionalLightNode->attachObject(directionalLight);
directionalLightNode->setDirection(Vector3(1, -1, 0));
Light* pointLight = this->sceneManager->createLight();
pointLight->setType(Light::LT_POINT);
pointLight->setDiffuseColour(ColourValue(0.4, 0.4, 0.4));
pointLight->setSpecularColour(ColourValue(0.4, 0.1, 0.1));
pointLight->setPowerScale(500);
SceneNode* pointLightNode = this->sceneManager->getRootSceneNode()->createChildSceneNode();
pointLightNode->attachObject(pointLight);
pointLightNode->setPosition(0,200,0);
the floor is at position (0,0,0) but the point light is not affecting the render.
what could be happening?