XEffects - Reloaded - New Release (V 1.4)

Announce new projects or updates of Irrlicht Engine related tools, games, and applications.
Also check the Wiki
Skomakarn
Posts: 18
Joined: Mon Aug 03, 2009 1:03 pm

Post by Skomakarn »

Yeah, I think this looks a lot better to me. The shadows are working. On my statue, the shadow of the stick it is holding is casted very strangely onto the body.

Yes, I am still using the computer with that video card.
BlindSide
Admin
Posts: 2821
Joined: Thu Dec 08, 2005 9:09 am
Location: NZ!

Post by BlindSide »

That may have to do with your far value and frustum. It can be tricky to get looking correct.

If you want you can check this out: http://www.ambiera.com/forum.php?t=484

You can copy the values from IrrEdit into your application (The fov, etc is stored in the scale values), and you should get the result you desire from that.

(Note that you have to use irrEdit 1.4.2 but it's not a big deal, the frustum values are what you're looking for.)

I may add proper irrEdit scene loading at a later stage.

Still that's not the main problem here, we should fix the aliasing first, do you get ok results if you just compile the example code yourself and run that?
ShadowMapping for Irrlicht!: Get it here
Need help? Come on the IRC!: #irrlicht on irc://irc.freenode.net
Skomakarn
Posts: 18
Joined: Mon Aug 03, 2009 1:03 pm

Post by Skomakarn »

I compiled this myself:

Image

Looks good to me, so I guess it must be something wrong with my setup.
I will try using your plugin to get the right values, and see if it helps. Thanks.

EDIT: ... In your video tutorial, the cube is affected by the lighting of your node as soon as you add it, but I can't seem to make the cube, or anything else, get affected.

I am using the right version of irrEdit. Is the shaders folder supposed to be in the same directory as irrEdit.exe? Otherwise I don't know what might be causing the problem.
kovacevic
Posts: 8
Joined: Sun Aug 02, 2009 4:40 pm

Post by kovacevic »

I am using XEffects and trying to get weapon flash working.
For weapon mesh, which is made up of weapon itself and quad for flash
I use material EMT_TRANSPARENT_ADD_COLOR.

When I use addShadowToNode for the weapon node, I get this:
(tried all these: ESM_CAST, ESM_RECEIVE, ESM_BOTH)

Image

When I don't use addShadowToNode for the weapon node, I get
part of flash lightened and part of flash darkened, because it is covered by shadows:

Image
BlindSide
Admin
Posts: 2821
Joined: Thu Dec 08, 2005 9:09 am
Location: NZ!

Post by BlindSide »

Hi kovacevic. Actually I think I fixed this in a recent update, which I haven't put on the first page yet (The precompiled examples exes haven't been compiled with the new dll so they won't work, don't bother running them).

This update allows the use of transparent materials. With this you have to use "excludeNodeFromLightingCalculations()" on any transparent nodes that you don't want conflicting with the lighting calculations.

You can get it here: http://irrlichtirc.g0dsoft.com/BlindSid ... _1_2_1.zip

Tell me if it fixes your problem.

Cheers
ShadowMapping for Irrlicht!: Get it here
Need help? Come on the IRC!: #irrlicht on irc://irc.freenode.net
kovacevic
Posts: 8
Joined: Sun Aug 02, 2009 4:40 pm

Post by kovacevic »

I found this thing working only if I use billboard node like this:

IBillboardSceneNode *bsn = smgr->addBillboardSceneNode(0, core::dimension2d<f32>(20, 20));
bsn->setMaterialFlag(video::EMF_LIGHTING, false);
bsn->setMaterialFlag(video::EMF_ZWRITE_ENABLE, false);
bsn->setMaterialType(::EMT_TRANSPARENT_ALPHA_CHANNEL);
bsn->setMaterialTexture(0,driver->getTexture("weap/gun_flash.png"));
bsn->setVisible(true);
camera->addChild(bsn);


But if I use AnimatedMeshSceneNode, result is like on second picture of previous post.
BlindSide
Admin
Posts: 2821
Joined: Thu Dec 08, 2005 9:09 am
Location: NZ!

Post by BlindSide »

So is the billboard method ok or do you have to use an AnimatedMeshSceneNode for the flash?

Are you combining the flash and the gun in one scene node? That might be the issue.
ShadowMapping for Irrlicht!: Get it here
Need help? Come on the IRC!: #irrlicht on irc://irc.freenode.net
kovacevic
Posts: 8
Joined: Sun Aug 02, 2009 4:40 pm

Post by kovacevic »

With IAnimatedMeshSceneNode I have tried node with flash quad only
and also node with weapon mesh+flash quad.


Otherwise, billboard method is ok.
wildrj
Posts: 301
Joined: Thu Mar 23, 2006 12:49 am
Location: Texas/ Cyberspace
Contact:

Post by wildrj »

Hmm is it possible to disable a shadow light? Other then completely removing it?
http://wild.deathtouchstudios.com << My gamedev blog
<Programming is a way of life>
If at first you don't succeed press the delete key till you do :)
BlindSide
Admin
Posts: 2821
Joined: Thu Dec 08, 2005 9:09 am
Location: NZ!

Post by BlindSide »

Hmm you'd think that would've been an obvious feature. :P

I'll add it.

Maybe I should make SShadowLight into a scene node of some kind? But then you get dependent on one scene manager... hmm.
ShadowMapping for Irrlicht!: Get it here
Need help? Come on the IRC!: #irrlicht on irc://irc.freenode.net
wildrj
Posts: 301
Joined: Thu Mar 23, 2006 12:49 am
Location: Texas/ Cyberspace
Contact:

Post by wildrj »

Hey blindside i made a temporary fix to get the desired "activate/deactive" fix.

New parameter on SShadowLight bool value "active"

Two new functions:
void setActive(bool) sets shadow light on and off
bool isActive() returns if shadow light is on or off

EffectHandler.h patch: http://dl.deathtouchstudios.com/patches ... lerh.patch
EffectHandler.cpp patch: http://dl.deathtouchstudios.com/patches ... rcpp.patch

P.S: this is my first attempt at releasing patches so..hope its right.
http://wild.deathtouchstudios.com << My gamedev blog
<Programming is a way of life>
If at first you don't succeed press the delete key till you do :)
Geomaster
Posts: 71
Joined: Tue Oct 21, 2008 3:39 pm

Post by Geomaster »

It looks like this:
http://img38.imageshack.us/img38/9416/badglitch.jpg
It should look like this:
http://img268.imageshack.us/img268/2296/goodpic.jpg

I'm using a red light from example.cpp (I was too lazy to move it and change the color :P) but you can see something is terribly wrong here.

I just use EffectHandler::addShadowToNode() on each mesh scene node with ESM_CAST.

Any ideas?
BlindSide
Admin
Posts: 2821
Joined: Thu Dec 08, 2005 9:09 am
Location: NZ!

Post by BlindSide »

No idea, need more information. Best advice is to get a very simple scene working first.
ShadowMapping for Irrlicht!: Get it here
Need help? Come on the IRC!: #irrlicht on irc://irc.freenode.net
Antaka
Posts: 7
Joined: Tue Jul 28, 2009 4:37 pm

Post by Antaka »

wildrj wrote:Hey blindside i made a temporary fix to get the desired "activate/deactive" fix.

New parameter on SShadowLight bool value "active"

Two new functions:
void setActive(bool) sets shadow light on and off
bool isActive() returns if shadow light is on or off

EffectHandler.h patch: http://dl.deathtouchstudios.com/patches ... lerh.patch
EffectHandler.cpp patch: http://dl.deathtouchstudios.com/patches ... rcpp.patch

P.S: this is my first attempt at releasing patches so..hope its right.
I've been looking your patch, and I have doubt,
Does this deactivate the all the processesing of the shadow or just the visual effect of the light?
this is my first attempt at using a patch for these kind of files, so maybe I missunderstand what you wrote :(
Thanks.

I had really a lot of problems to get XEffect running on Irr 1.5 and 1.5.1, I just could did it with and old version, 1.1 I think... I'm the only one with troubles, wich Irrlicht version does the rest of you use?
Another thing giving troubles is trying to add new post processing effects :(
any help will be really appreciated :D Thanks to all.
BlindSide
Admin
Posts: 2821
Joined: Thu Dec 08, 2005 9:09 am
Location: NZ!

Post by BlindSide »

It's best to use a new SVN version of Irrlicht.

1.6 will be out soon and I will release a fully compatible version of XEffects with the stable version.
ShadowMapping for Irrlicht!: Get it here
Need help? Come on the IRC!: #irrlicht on irc://irc.freenode.net
Post Reply