Glass Pane and Rain Drop refraction demo - Source Included

Announce new projects or updates of Irrlicht Engine related tools, games, and applications.
Also check the Wiki

What do you like better?

The glass pane.
73
88%
The rain drops.
10
12%
 
Total votes: 83

wITTus
Posts: 167
Joined: Tue Jun 24, 2008 7:41 pm
Location: Germany

Post by wITTus »

@Cr33: I know exactly how you feel. I once had a Radeon 9600XT and watched too much demos - guess what happened. But, you should use your card. The more, the better. Because that's power testing for your new hardware. If it fails, bring it back and use your warranty.
Generated Documentation for BlindSide's irrNetLite.
"When I heard birds chirping, I knew I didn't have much time left before my mind would go." - clinko
cr33
Posts: 22
Joined: Fri Mar 27, 2009 3:37 pm

Post by cr33 »

phew.... i've tried compile-running it, and nothing exploded! :D

@BlindSide: it's weird to reply to year old post, but anyway- i'd like to point out that you forgot to include the dwarf in source code :P
Siebenschläfer
Posts: 34
Joined: Thu Feb 05, 2009 11:37 am
Location: Koblenz, Germany

Post by Siebenschläfer »

the glass is wonderful!

how did you give your own mesh the texture? If I include the dwarf and do

Code: Select all

node->setMaterialType(E_MATERIAL_TYPE(GlassMat));
my result looks pretty like this:

Image
Think Tannenzäpfle!
devsh
Competition winner
Posts: 2057
Joined: Tue Dec 09, 2008 6:00 pm
Location: UK
Contact:

Post by devsh »

the result is correct because the shader is made for a plane not a whole 3d mesh
FuzzYspo0N
Posts: 914
Joined: Fri Aug 03, 2007 12:43 pm
Location: South Africa
Contact:

Post by FuzzYspo0N »

The demo included applies it to a mesh , a plane, and a set of water drops. Its something else
Siebenschläfer
Posts: 34
Joined: Thu Feb 05, 2009 11:37 am
Location: Koblenz, Germany

Post by Siebenschläfer »

exactly, I wanted to have such a shiny dwarf like in the demo but unfortunately the dwarf was not included in the source code so I don't know what's wrong here :(
Think Tannenzäpfle!
BlindSide
Admin
Posts: 2821
Joined: Thu Dec 08, 2005 9:09 am
Location: NZ!

Post by BlindSide »

* Digs up very old demo code *

Code: Select all

ISceneNode* GlassMesh = smgr->addAnimatedMeshSceneNode(smgr->getMesh("media/dwarf.x"));

GlassMesh->setPosition(core::vector3df(2400*2,1200,2000*2));

GlassMesh->setScale(core::vector3df(10,10,10));

GlassMesh->setMaterialTexture(0, RTTTex);

GlassMesh->setMaterialTexture(1, NormMap);
and then

Code: Select all

GlassMesh->setMaterialType(E_MATERIAL_TYPE(GlassMat));
You probably forgot to set the normal map texture.

Cheers
ShadowMapping for Irrlicht!: Get it here
Need help? Come on the IRC!: #irrlicht on irc://irc.freenode.net
Siebenschläfer
Posts: 34
Joined: Thu Feb 05, 2009 11:37 am
Location: Koblenz, Germany

Post by Siebenschläfer »

oh, I see...


I tried to implement it into another project but got strange effects:

this room: I did the same I did in your project and got this:

ImageImage






so right now you can hardly see but the glass effect works but the texture is straight over the shape of the room ignoring its geometry. With other shaders that I use to give it a material this effect does not take place
Think Tannenzäpfle!
BlindSide
Admin
Posts: 2821
Joined: Thu Dec 08, 2005 9:09 am
Location: NZ!

Post by BlindSide »

Yes I recommend only using this with planes, the mesh thing is not physically correct and so in certain cases it can look strange.
ShadowMapping for Irrlicht!: Get it here
Need help? Come on the IRC!: #irrlicht on irc://irc.freenode.net
Siebenschläfer
Posts: 34
Joined: Thu Feb 05, 2009 11:37 am
Location: Koblenz, Germany

Post by Siebenschläfer »

pity :(
Think Tannenzäpfle!
netpipe
Posts: 670
Joined: Fri Jun 06, 2008 12:50 pm
Location: Edmonton, Alberta, Canada
Contact:

Re: Glass Pane and Rain Drop refraction demo - Source Includ

Post by netpipe »

in irrlicht 1.8 and 1.9 this demo is not working as expected the glass pane is divided into 4 and the drops are square. whats going on with my shaders everythings broken and im going crazy (linux 64 bit) it works great in irr 1.7

Image
Live long and phosphor!
-- https://github.com/netpipe/Luna Game Engine Status 95%
netpipe
Posts: 670
Joined: Fri Jun 06, 2008 12:50 pm
Location: Edmonton, Alberta, Canada
Contact:

Re: Glass Pane and Rain Drop refraction demo - Source Includ

Post by netpipe »

Live long and phosphor!
-- https://github.com/netpipe/Luna Game Engine Status 95%
Post Reply