Search found 42 matches

by ison
Sun Apr 05, 2015 2:40 pm
Forum: Advanced Help
Topic: Terrain part disappears when moving backwards
Replies: 4
Views: 1011

Re: Terrain part disappears when moving backwards

Found the problem!
It was caused by too big, default camera movement delta.

Code: Select all

irr::scene::ITerrainSceneNode::setCameraMovementDelta
I guess there should be some kind of a formula which would give the maximum possible value for camera movement delta based on terrain scale.
by ison
Sun Apr 05, 2015 1:32 pm
Forum: Advanced Help
Topic: Terrain part disappears when moving backwards
Replies: 4
Views: 1011

Re: Terrain part disappears when moving backwards

Thanks for the reply, but unfortunately it's not the problem. My znear is very small (like 5 cm), and here the distance from camera to terrain is like 2 meters. Usually if I move forward everything is fine, but when I move backwards sometimes a big part of terrain is not rendered.
by ison
Sun Apr 05, 2015 12:27 pm
Forum: Advanced Help
Topic: Terrain part disappears when moving backwards
Replies: 4
Views: 1011

Terrain part disappears when moving backwards

Hello. I'm using Irrlicht FPP camera, but I set camera position manually (because Bullet controlls player's position) via camera->setPosition(). When I move forward everything is fine, but when I move backwards, a part of terrain seems to be not updated properly and is just not rendered (probably so...
by ison
Wed Dec 10, 2014 12:42 pm
Forum: Advanced Help
Topic: Directional lighting gives sharp edges
Replies: 9
Views: 2020

Re: Directional lighting gives sharp edges

Thanks for your answer. So I disabled shadow volumes, but unfortunately the problem is still there. I set GouraudShading to true for all model's materials. I replaced directional light with point light, to make sure it's not caused by bugged OpenGL directional light. I tried recalculating normals us...
by ison
Tue Dec 09, 2014 7:14 pm
Forum: Advanced Help
Topic: .x animation feet artifacts
Replies: 10
Views: 1718

Re: .x animation feet artifacts

@Foaly
Wow! It worked!
Thank you very much, you're awesome :)
by ison
Tue Dec 09, 2014 2:36 pm
Forum: Advanced Help
Topic: .x animation feet artifacts
Replies: 10
Views: 1718

Re: .x animation feet artifacts

Thanks CuteAlien. I opened it in mview.exe and it indeed had the same artifacts as in Irrlicht, so from now on I guess I'll have to ask on Blender forum. Without animation I get a correct model, with animation I get currently nothing (meaning no model shows up in Irrlicht althought it seems to load ...
by ison
Tue Dec 09, 2014 11:21 am
Forum: Advanced Help
Topic: .x animation feet artifacts
Replies: 10
Views: 1718

Re: .x animation feet artifacts

But how? In Blender everything looks fine. In Irrlicht I used setPosition() on whole node, and new position is set correctly, except feet have some offset relative to the body position.
by ison
Tue Dec 09, 2014 10:23 am
Forum: Advanced Help
Topic: .x animation feet artifacts
Replies: 10
Views: 1718

Re: .x animation feet artifacts

I see the bug, but don't seem to have an .X exporter in Blender. Where did you get yours from? Blender does have a .x exporter but it's not enabled by default. You have to enable it in File->User Preferences->Addons->Search for "directx" edit: If you still have a dxviewer from old Microso...
by ison
Mon Dec 08, 2014 10:57 pm
Forum: Advanced Help
Topic: .x animation feet artifacts
Replies: 10
Views: 1718

.x animation feet artifacts

Hello. I exported this model using Blender to .x file: blend: https://dl.dropboxusercontent.com/u/12301540/misc/zombie.blend x: https://dl.dropboxusercontent.com/u/12301540/misc/zombie.x With the following export options: http://img713.imageshack.us/img713/3366/7gj9.png But I'm getting this result (...
by ison
Sun Dec 07, 2014 1:13 pm
Forum: Advanced Help
Topic: Directional lighting gives sharp edges
Replies: 9
Views: 2020

Re: Directional lighting gives sharp edges

Thanks. I tried setting lower 'infinite' value passed to createShadowVolumeSceneNode() and it fixed the problem. These shadow volumes are extremely slow though, I use 16 vertices shadow mesh and for like 10 meshes the framerate drops significantly, so I guess shadow volumes aren't very useful unless...
by ison
Sat Dec 06, 2014 3:54 pm
Forum: Advanced Help
Topic: Directional lighting gives sharp edges
Replies: 9
Views: 2020

Re: Directional lighting gives sharp edges

Nice, thanks alot. I have another problem but I'm not sure if I should start a new thread. I'm using shadow volumes, and I add volume nodes like this: node->addShadowVolumeSceneNode(mesh); Usually everything looks OK: http://i61.tinypic.com/ip33ww.png But at some camera angles, if I move camera a li...
by ison
Sat Dec 06, 2014 3:07 pm
Forum: Advanced Help
Topic: Directional lighting gives sharp edges
Replies: 9
Views: 2020

Re: Directional lighting gives sharp edges

Thanks. Changing light direction indeed solved the problem. But it's still worying that there are some angles at which sharp edges occur - I'm not using flat shading so it should never occur, should it?

Is it better (or faster) to write custom per-pixel shader for directional lighting?
by ison
Sat Dec 06, 2014 1:49 pm
Forum: Advanced Help
Topic: Directional lighting gives sharp edges
Replies: 9
Views: 2020

Directional lighting gives sharp edges

Hello. I added directional light like this (OpenGL driver): 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}; This is how my model looks from 1 side...
by ison
Thu Nov 13, 2014 1:56 pm
Forum: Advanced Help
Topic: Terrain scene node has incorrect size
Replies: 6
Views: 1254

Re: Terrain scene node has incorrect size

Ok. Thanks for answers. I'd really like to keep the smoothing factor, since I need this in my project too. Otherwise terrain is too bumpy. @ralian I'd also be very happy if you could fix this bug. The problem seems trivial, but in my case it's very problematic. As I said before, I can't scale the te...
by ison
Wed Nov 12, 2014 7:03 pm
Forum: Advanced Help
Topic: Terrain scene node has incorrect size
Replies: 6
Views: 1254

Terrain scene node has incorrect size

Hello. I read somewhere that Irrlicht terrain scene node has exactly the same size in units as height map texture used to generate the terrain. However, it's not true in my case. I'm using code from this example: http://irrlicht.sourceforge.net/docu/example012.html And I changed terrain scale to 1,1...