Check this out.
It is a thing i've noticed, probably in the B3D loader, that is the type of file in which the meshes are stored. It is the same scene (an IRR scene) rendered with the 1.6 version of Irr, and the V 1.7.1 downloaded from the web.
in the begining i thought it was a texture that wouldn't load, but then, when i checked the 1.6 version i noticed it was there, and that in 1.7.1 it wasn't.
The logs didn't show anything diferent, the texture was loaded, so i concluded it had to see with the way B3D are loaded, or with the way spherical reflections are processed, but the demo/examples. ran correctly, so i thought it should be the B3D
Any idea why would this happen?
Posible bug in V-1.7.1
Posible bug in V-1.7.1
"There is nothing truly useless, it always serves as a bad example". Arthur A. Schmitt
-
- Admin
- Posts: 14143
- Joined: Wed Apr 19, 2006 9:20 pm
- Location: Oldenburg(Oldb), Germany
- Contact:
Yeah, looks like something has changed n the material setup. However, I cannot tell which version is the correct one.Where does this reflection thing belong to? Can you provide us with the source files? Is there something like a blender render screenshot or something? Do you know what material type (either Irrlicht or b3d) was used for the problematic mesh parts?
The Source is pretty straight, it just loads an irr file, and the meshes
The material is a reflection_2_layer, and is affecting the same to 4 diferent meshes. That is why i really can't point a posible source of the trouble, because there are other meshes which have also a reflection_2_layer material, and render fine. It iseems as if the textures weren't passed to the material or the like, it must be something that has changed since the v 1.6
It is compiled with Code::blocks and the Nov2008 DXSDK.
Code: Select all
#include <iostream>
#include <irrlicht.h>
using namespace std;
using namespace irr;
int main(int argc, char* argv[]){
IrrlichtDevice *device;
SIrrlichtCreationParameters prm;
core::array< SJoystickInfo > joysticks;
scene::ISceneManager* smgr;
video::IVideoDriver* drv;
scene::IMeshSceneNode* level;
scene::ICameraSceneNode* camera;
scene::ILightSceneNode* luz1;
gui::IGUIEnvironment* gui;
prm.Bits = 32;
prm.DriverType = video::EDT_DIRECT3D9;
prm.Fullscreen = true;
prm.Stencilbuffer = true;
prm.Vsync = false;
prm.AntiAlias=4;
prm.WindowSize = core::dimension2d<u32>(1440,900);
device = createDeviceEx(prm);
if(device){
device->activateJoysticks(joysticks);
smgr=device->getSceneManager();
drv=device->getVideoDriver();
gui=device->getGUIEnvironment();
drv->setTextureCreationFlag(video::ETCF_OPTIMIZED_FOR_SPEED ,true);
smgr->loadScene("./data/scenes/Scene2.irr");
camera=smgr->addCameraSceneNodeFPS(
0,
50,
0.075
);
camera->setPosition(core::vector3df(-2000,0,0));
camera->setFarValue(5000);
camera->setFOV(core::PI/3);
/*luz1=smgr->addLightSceneNode(0,core::vector3df(-2000,2000,2000));
luz1->getLightData().Falloff=0;
luz1->getLightData().DiffuseColor=video::SColor(255,255,243,197);
luz1->setRadius(5000);*/
drv->setFog( video::SColor(0, 255, 255, 255),
video::EFT_FOG_LINEAR,
20.0f,
3000.0f,
0.001f) ;
//level=(scene::IMeshSceneNode*)smgr->getSceneNodeFromName("LevelRenderMesh0");
//level->getMesh()->setHardwareMappingHint(scene::EHM_STATIC,scene::EBT_NONE);
/*for(u32 i=0;i<level->getMaterialCount();i++){
level->getMaterial(i).AmbientColor=video::SColor(0,64,64,64);
level->getMaterial(i).DiffuseColor=video::SColor(0,128,128,128);
level->getMaterial(i).SpecularColor=video::SColor(0,250,250,250);
level->getMaterial(i).NormalizeNormals=true;
level->getMaterial(i).AntiAliasing=true;
}*/
int lastFPS = -1;
device->getCursorControl()->setVisible(false);
while(device->run()){
drv->beginScene(true, true, video::SColor(0,128,160,255));
smgr->drawAll();
drv->endScene();
int fps = drv->getFPS();
if (lastFPS != fps)
{
core::stringw str = L"Olimpus Asteroid Tech Demo [";
str += drv->getName();
str += "] FPS:";
str += fps;
str += "-Triangles :";
str += drv->getPrimitiveCountDrawn();
device->setWindowCaption(str.c_str());
lastFPS = fps;
}
}
}
return 0;
}
It is compiled with Code::blocks and the Nov2008 DXSDK.
"There is nothing truly useless, it always serves as a bad example". Arthur A. Schmitt