Terrific shaders

Discuss about anything related to the Irrlicht Engine, or read announcements about any significant features or usage changes.
Post Reply
IPv6
Posts: 188
Joined: Tue Aug 08, 2006 11:58 am

Terrific shaders

Post by IPv6 »

Hello!
Look at this examples of shaders
i really wish to know HOW it is implemented, principles at least
videos:
http://www.youtube.com/watch?v=yLYncSXO2U0
http://www.youtube.com/watch?v=Z3fdrvFsYnQ
http://www.youtube.com/watch?v=W1FDxRVt2Aw
http://www.youtube.com/watch?v=AcEo0D-RVls
AlexL
Posts: 184
Joined: Tue Mar 02, 2004 6:06 pm
Location: Washington State

Post by AlexL »

If your interested in that, you can find the demo for the first shader here. Which includes full shader and application source. The page I found this on, also has nVidia FX Composer demos and the like related to relief mapping; page is here. Hope this helps :)
bitplane
Admin
Posts: 3204
Joined: Mon Mar 28, 2005 3:45 am
Location: England
Contact:

Post by bitplane »

i love the imposter video.. shame the demo doesn't come with any license info or any information on how the normal maps were generated.
like i said in the comment on video 2, this would be amazing if it was possible to render it from 6 viewpoints in realtime, then use a plane instead of a complex mesh at a set distance.
Submit bugs/patches to the tracker!
Need help right now? Visit the chat room
IPv6
Posts: 188
Joined: Tue Aug 08, 2006 11:58 am

Post by IPv6 »

Thanks, AlexL! Begin to study... i wonder is it NVidia only stuff... sad if so :)
Yes, this shaders would be great to use. Mush less pain with low poly, pcie bus bandwidth and other stuff, nice visuals in the flash!!!
sio2
Competition winner
Posts: 1003
Joined: Thu Sep 21, 2006 5:33 pm
Location: UK

Post by sio2 »

Very nice. Should be simple to implement in Irrlicht, from a quick look at the source. Pixel-shader intensive, though, so I doubt it'll fit in PS1.1.
:wink:
andrei25ni
Posts: 326
Joined: Wed Dec 14, 2005 10:08 pm

Post by andrei25ni »

wow I want them in my game ! :P
vectorcorpse
Posts: 86
Joined: Thu Feb 14, 2008 7:30 pm
Location: Portugal

Post by vectorcorpse »

not the best example I've seen, but it really is interesting
i'v already posted here
http://irrlicht.sourceforge.net/phpBB2/ ... ef+mapping
an example of relief mapping, looks really cool, it is heavier than irrlicht parallax but lighter than devsh geometry shader.
maybe it can get someone's attention and get implemented has a compromise between the other 2 or has a advanced impostor system :P
devsh
Competition winner
Posts: 2057
Joined: Tue Dec 09, 2008 6:00 pm
Location: UK
Contact:

Post by devsh »

the first video shows "non-height field" this tells you straight away that you have NOT got a heightmap, the chains are simply equations of a 3d curve

you need to formulate an equation for a similar line, if you look in the video you see that its only one continuous strand that goes from left to right and it is duplicated up and down. You need an equation for that squiggly line in terms of UV coords of a texture (so its all nice and even on a flat plane), then define the thickness of the graph/line and then do standard transform camera into tangent space and raytrace/intersect using an equation for line intersection in 3d. Then if you got a hit, get a ray from tangent light position to that pixel and raytrace again if there is a shadow.

Thats it for the first video, because the graph is defined according to UV coords then you can apply the chain effect on teapots etc.
devsh
Competition winner
Posts: 2057
Joined: Tue Dec 09, 2008 6:00 pm
Location: UK
Contact:

Post by devsh »

The second one is more tricky, its the REAL impostors which are descirbed in a GPU gems 3 paper. its basically Parallax Occlusion Mapping but using more than one texture (3d texture) when stuff overlaps you need another layer of textures. For example I think the dog is 4-8 textures
First from the side, then after the leg starts occluding itself, another texture and so on
Then repeat the process from the other side

The worst case EVER is if you have a wavy surface perpendicular to the height map
Beware the video was of low quality, the true impostor technique provides perfect relief mapping replacing models, BUT FAR AWAY, it is pixelated as gently caress.

3rd demo is normal PoM

Oh and btw the 4th demo only works on spheres :)
Post Reply