Render target water
This commit is contained in:
@@ -20,7 +20,7 @@ fragment_program Examples/FresnelRefractReflectFP glsl glsles glslang hlsl
|
||||
|
||||
*/
|
||||
|
||||
material Water
|
||||
material Water/Above
|
||||
{
|
||||
technique
|
||||
{
|
||||
@@ -51,12 +51,13 @@ material Water
|
||||
param_named noiseScale float 0.05
|
||||
}
|
||||
*/
|
||||
vertex_program_ref water_vp
|
||||
vertex_program_ref Water/water_vp
|
||||
{
|
||||
}
|
||||
fragment_program_ref water_fp
|
||||
fragment_program_ref Water/water_fp
|
||||
{
|
||||
}
|
||||
/*
|
||||
// Noise
|
||||
texture_unit
|
||||
{
|
||||
@@ -90,8 +91,96 @@ material Water
|
||||
}
|
||||
tex_address_mode mirror
|
||||
}
|
||||
*/
|
||||
texture_unit
|
||||
{
|
||||
texture ReflectionTexture
|
||||
tex_address_mode mirror
|
||||
}
|
||||
texture_unit
|
||||
{
|
||||
texture RefractionTexture
|
||||
tex_address_mode mirror
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
material Water/Below
|
||||
{
|
||||
technique
|
||||
{
|
||||
pass
|
||||
{
|
||||
ambient 1.0 1.0 1.0 1.0
|
||||
diffuse 0.0 0.2 0.5 1.0
|
||||
cull_hardware none
|
||||
cull_software none
|
||||
vertex_program_ref Water/water_vp
|
||||
{
|
||||
}
|
||||
fragment_program_ref Water/water_fp
|
||||
{
|
||||
}
|
||||
/*
|
||||
// Noise
|
||||
texture_unit
|
||||
{
|
||||
// Perlin noise volume
|
||||
texture waves2.png
|
||||
// min / mag filtering, no mip
|
||||
filtering linear linear none
|
||||
tex_address_mode mirror
|
||||
}
|
||||
// Reflection
|
||||
texture_unit
|
||||
{
|
||||
content_type compositor Fresnel reflection
|
||||
tex_address_mode mirror
|
||||
}
|
||||
// Refraction
|
||||
texture_unit
|
||||
{
|
||||
content_type compositor Fresnel refraction
|
||||
tex_address_mode mirror
|
||||
}
|
||||
*/
|
||||
texture_unit
|
||||
{
|
||||
texture ReflectionTexture
|
||||
tex_address_mode mirror
|
||||
}
|
||||
texture_unit
|
||||
{
|
||||
texture RefractionTexture
|
||||
tex_address_mode mirror
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/*
|
||||
|
||||
material Water/Depth
|
||||
{
|
||||
technique
|
||||
{
|
||||
pass
|
||||
{
|
||||
cull_hardware none
|
||||
alpha_rejection greater_equal 0.5
|
||||
vertex_program_ref Water/depth_vp
|
||||
{
|
||||
param_named_auto world world_matrix
|
||||
param_named_auto worldViewProj worldviewproj_matrix
|
||||
}
|
||||
fragment_program_ref Water/depth_fp
|
||||
{
|
||||
param_named_auto cameraPosition camera_position
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
*/
|
||||
|
||||
|
||||
Reference in New Issue
Block a user