I added directional light like this (OpenGL driver):
Code: Select all
irr::scene::ILightSceneNode* pLight = sceneManager->addLightSceneNode();
irr::video::SLight & l = pLight->getLightData();
l.Type = irr::video::ELT_DIRECTIONAL;
l.AmbientColor = {0.3f, 0.3f, 0.3f};
And this is how it looks from another (sharp edge):
In Blender model looks good from all sides. There are no sharp edges anywhere.
1) What causes this? (I tried normalizing normals and recalculating them)
2) Is it better nowadays to write custom forward-rendering shader with directional and point lights support? (or maybe even deferred rendering?)
3) Would it be noticeably slower than using regular rendering without custom shaders?
Thanks