BlindSide's HLSL Shader Pack
Woops, this is a small mistake. Simply change the "shadowWrapper.h" to "effectWrapper.h" in the file, as I changed the name halfway through but forgot to change it in the source!
(It should be fixed in the new one but maybe I forgot to change something in the example code.)
PS: You say you got an error running the binary? Please tell me what kind of error and also your graphics card/operating system.
Cheers
(It should be fixed in the new one but maybe I forgot to change something in the example code.)
PS: You say you got an error running the binary? Please tell me what kind of error and also your graphics card/operating system.
Cheers
Thanks for replying!
I'll rename it and see what happens, but I'll also redownload the latest version. Thanks a bunch.
I got the error trying to run on an Nvidia Geforce FX5900 ultra 256 mb, so perhaps it doesn't support your shader version. Will try on the other PC with a 6800 GT 256 Mb. They say it's the minimum to run this sort of apps
cheers!
I'll rename it and see what happens, but I'll also redownload the latest version. Thanks a bunch.
I got the error trying to run on an Nvidia Geforce FX5900 ultra 256 mb, so perhaps it doesn't support your shader version. Will try on the other PC with a 6800 GT 256 Mb. They say it's the minimum to run this sort of apps
cheers!
To fix the 16 bit issue, open up the desirted shader and change
to
This will increase the offset to subtract from the depth buffer in order to reduce artifacts due to depth inaccuracy.
Also you can change all the "tex2D( ShadowMapSampler,ShadowMapSamplingPos ).x" to "tex2D( ShadowMapSampler,ShadowMapSamplingPos ).y" so that it reads from the Green component, which should give you 6 bits instead of 5 in 16 bit mode.
Subtracting from the depth buffer causes more of the shadow to get cut off under sydney's feet, so maybe setting it up so it only loads the 16 bit one under 16 bit mode is best. (Shouldn't be hard to modify the wrapper to do this).
Code: Select all
OUT.RealDistance[0] = (SMPos.z/MaxD) - 0.01f;
Code: Select all
OUT.RealDistance[0] = (SMPos.z/MaxD) - 0.03f;
Also you can change all the "tex2D( ShadowMapSampler,ShadowMapSamplingPos ).x" to "tex2D( ShadowMapSampler,ShadowMapSamplingPos ).y" so that it reads from the Green component, which should give you 6 bits instead of 5 in 16 bit mode.
Subtracting from the depth buffer causes more of the shadow to get cut off under sydney's feet, so maybe setting it up so it only loads the 16 bit one under 16 bit mode is best. (Shouldn't be hard to modify the wrapper to do this).
ShadowMapping for Irrlicht!: Get it here
Need help? Come on the IRC!: #irrlicht on irc://irc.freenode.net
Need help? Come on the IRC!: #irrlicht on irc://irc.freenode.net
I have already kind of converted it, but I need to convert all the filtering types and release the wrapper in a nice way. Unfortunately lately I have not had much time for this kind of stuff. I'll try to get it out sometime soon.
ShadowMapping for Irrlicht!: Get it here
Need help? Come on the IRC!: #irrlicht on irc://irc.freenode.net
Need help? Come on the IRC!: #irrlicht on irc://irc.freenode.net
this is my code
the effect is so good,
but when the node moved is error,
why? please help me.
///////////////////////////////////////////////////////////////////////////////////
IAnimatedMesh* mesh = smgr->getMesh("body.b3d");
IAnimatedMeshSceneNode* snode = smgr->addAnimatedMeshSceneNode( mesh );
effect->addEffectToNode(snode,EET_PHONG);
while(device->run())
{
driver->beginScene(true,true,SColor(0,0,0,0));
effect->getLightCamera()->setPosition(snode->getAbsolutePosition());
effect->setLightTarget(snode->getAbsolutePosition());
effect->update();
smgr->drawAll();
driver->endScene();
}
///////////////////////////////////////////////////////////////////////////////////
snode moved
snode not moved,postion is 0,0,0
[/img]
the effect is so good,
but when the node moved is error,
why? please help me.
///////////////////////////////////////////////////////////////////////////////////
IAnimatedMesh* mesh = smgr->getMesh("body.b3d");
IAnimatedMeshSceneNode* snode = smgr->addAnimatedMeshSceneNode( mesh );
effect->addEffectToNode(snode,EET_PHONG);
while(device->run())
{
driver->beginScene(true,true,SColor(0,0,0,0));
effect->getLightCamera()->setPosition(snode->getAbsolutePosition());
effect->setLightTarget(snode->getAbsolutePosition());
effect->update();
smgr->drawAll();
driver->endScene();
}
///////////////////////////////////////////////////////////////////////////////////
snode moved
snode not moved,postion is 0,0,0
[/img]