Page 3 of 5

Posted: Wed May 21, 2008 1:37 pm
by BlindSide
JDHunter wrote:Hey BlindSide,

thx for nice tutorial, very nice work...
very helpful... big thx for release the source :D

currently successful tested on laptop with a Radeon XPRESS200 SERIES :wink: 8FPS, all shader run correctly

later i will test it on 8800gts
Believe it or not, this demo was programmed on a laptop with a Radeon 200M series ;) (So was the metaballs one.)

Posted: Wed May 21, 2008 4:12 pm
by JDHunter
:shock: ...wow develop on a Radeon200M

ok her the result of Geforce8800GTS(640)
230FPS and all run correctly... very... nice... i will ported next time to irrlichtNetCP, if you don't object
nice nice... go on with your'e work ;)

Posted: Wed Jun 04, 2008 12:00 pm
by Blue Hampster
Heya, when I try to use it, all it returns is a solid texture on all the models which is made from the terrain, and when the camera is tilted upwards, then the textures become just the same as the sky box. Does anyone know whats happened?

Posted: Wed Jun 04, 2008 2:30 pm
by FlyingIsFun1217
Blue Hampster wrote:Heya, when I try to use it, all it returns is a solid texture on all the models which is made from the terrain, and when the camera is tilted upwards, then the textures become just the same as the sky box. Does anyone know whats happened?
Sounds like what I used to get on an intel GPU with linux. Any similarities?

Make sure your GPU supports the shader model.

FlyingIsFun1217

Posted: Wed Jun 04, 2008 2:39 pm
by hybrid
Yes, broken shaders sometimes bring strange render states. I have fixed some things in SVN, not sure if this already fixes all problems for failed shaders, though, especially when only one of the shaders works correctly.

Posted: Wed Jun 04, 2008 10:51 pm
by BlindSide
This requires atleast Shader Model 2.0 in OpenGL. It may work on Intel cards if converted to DX...

Posted: Mon Jun 23, 2008 3:23 am
by christianclavet
Hi, Blindside.

Tested this on my card (GeForce 9800GX2) on Vista64 and work very well.
Here's a screen:
Image

Posted: Mon Jul 07, 2008 7:12 am
by dlangdev
u da man!

thanks for the tutorial, i'll test the code in one of my test programs.

Image

Posted: Mon Jul 07, 2008 7:19 am
by Mirror
cool work BlindSide!
one question, i was playing around with some values in the shaders and it seems ( though it's not very obvious with the default values ) that when the glasspane intersects with the lower part of the camera viewport and with the left part of it, a weird effect is being produced like having 1 cm line down and left which doesn't look very good

Posted: Mon Jul 07, 2008 7:23 am
by dlangdev
u know, i've seen this somewhere not sure if it was on irrlicht forum.

there's the same demo of a stained glass version. i'm hoping it was blindside who wrote that, tho.

anyway, i think it is possible to modulate the basemap texture to the normal map to create that effect.

would appreciate if someone could confirm about the stained glass demo.

Posted: Mon Jul 07, 2008 7:29 am
by dlangdev
nope, it was sio who made the stained glass demo.

http://irrlicht.sourceforge.net/phpBB2/ ... ined+glass

Posted: Mon Jul 07, 2008 12:41 pm
by Mirror
Hi, sorry for "Hijacking" this thread, i was playing around with BlindSide's code, so here is some modded code ( not in the shaders, just in the .cpp, in the shaders i just changed a constant value and made it a variable )

actually made it a EMT_TRANSPARENT_REFLECTION_2_LAYER and removed the 0 layer texture ( RTTTex ). added also an RTTTex->drop()

http://irrlichtirc.g0dsoft.com/Ogami_It ... s2-0.1.rar

this results in some kind of fake reflection ( doesn't come out of the shader ). feel free to use it :D

here is an image :
http://img352.imageshack.us/img352/9156/glass3jl5.jpg

there is one issue with this shader ( and also elvman's one about realistic water ) : if you play with Harshness values ( look at the shader ) and have a relatively small value ( close to 0 ) you will notice this problem :

http://img150.imageshack.us/img150/4353/glass2us6.jpg

( it is also present with HarshNess = 2.0 ) but not very visible

there is one more issue, if you move the camera up, the change of the glass reflection from terrain to sky, doesn't take place smoothly

Posted: Mon Jul 07, 2008 1:08 pm
by JP
That error looks like you're reading over the edge of the texture or you're clamping the texture coords to within the 0-1 range. Not much you can do about that really i suppose as effectively you're wanting to read off the edge of the RTT due to large refraction so i guess the only way to fix it would be to create a larger RTT.

Posted: Mon Jul 07, 2008 8:22 pm
by dlangdev
i will not say any word.

this one is worth a thousand words.

for your eyes only.

Image

Posted: Tue Jul 08, 2008 5:11 am
by dlangdev
here's another one, fireball added into the scene. notice FPS went down by 20.

Image