My Account


RSS
oZone3D.Net RSS Feeds»RSS 2.0 Feeds

Blogs
»The Geeks Of 3D
»Demoniak3D Blog
»JeGX's Infamous Lab

Sponsors

Modul8: real time video mixing and compositing


Link to Us

oZone3D.Net 100% Realtime 3D

»All Links

Search
Google
Web
oZone3D.Net

Web Partners

www.benchmarkhq.ru
www.tdt3d.com
www.steph3d.net
www.g-truc.net
www.worldpcspecs.com


Banners Exchange

cgindia.blogspot.com
grapejuice.c.la
www.game-lab.com
www.cooki3d.org


Links Exchange

»CYGAD's 3DXtra
 
Vertex Displacement Mapping using GLSL

By Jerome Guinot aka 'JeGX' - jegx [at] ozone3d (dot) net

Initial draft: March 26, 2006
Update: November 5, 2006
Update: November 22, 2006


[ Index ]

Introduction | Page 2 | Page 3 | Page 4 | Conclusion

»Next Page



4 - The Problem of Normals

One of the biggest drawbacks of vertex displacement mapping is that faces normals and then those of vertices are damaged since they are valid for the un-deformed mesh. As we are inside a vertex shader, we can not access to the two other vertices that form the current processed face and then we can not recalculate the normal...

But there are two manners to come out of this tricky problem. The first one is simply to not use... the normals! With static lighting (like the lightmapping), the normal is useless since the lighting comes from the light-map.

The second manner is to provide the normal to the pixel shader. A simple method is to create a normal-map from the displacement map. The normal-map holds normal vectors that are orientated to simulate the displacement map relief. This technique works quite well if we forget some little imperfections like some areas that should not be lit...

The following picture shows the result of a BumpDisplacementMapping shader. Both displacement and normal maps have been created from the base map (texture of stone). This project is available in the downloadable archive.



Fig. 5 - DEMO_bump_displacement_mapping.xml





[ Index ]

Introduction | Page 2 | Page 3 | Page 4 | Conclusion

»Next Page







Language:


Demoniak3D
Current Version: 1.23.0
»Demoniak3D
»Download
»Libraries and Plugins
»Demos
»Online Help - Reference Guide
»Codes Samples


GPU Caps Viewer
Current Version: 1.4.2
»GPU Caps Viewer
»GPU DB Submissions


FurMark
Current Version: 1.3.0
»FurMark
»Benchmark Submissions
Page generated in 0.21290588378906 seconds.