Game Development Community

how can i use relief map ?

by A.P.W Studio · in General Discussion · 02/01/2009 (10:02 am) · 1 replies

hi ,
how can i use of reliefshape shader ?
i use two map first is color and second is normal map like this :

new CustomMaterial(relif_mat)
{
mapTo = "wall.jpg";
Texture[0] = "wall.jpg";
Texture[1] = "wall_NM_height.png";
shader = reliefshader;
};
and load these shader with this :

new ShaderData( reliefshader )
{
DXVertexShaderFile = "shaders/reliefShapeV.hlsl";
DXPixelShaderFile = "shaders/reliefShapeP.hlsl";
pixVersion = 3.0;
};

but the result is not that i was thinking ?

#1
02/02/2009 (2:45 am)
If you are using the shaders found in this site, then I can assume that you are missing the heightmap that is supposed to be in the alpha channel of the normal map. The relief shader found here is setup this way.

P.S. not sure if you need to use extensions in the material file.