Revision: 781
http://python-ogre.svn.sourceforge.net/python-ogre/?rev=781&view=rev
Author: andy_miller
Date: 2008-10-30 03:03:17 +0000 (Thu, 30 Oct 2008)
Log Message:
-----------
Update media to latest ogre
Modified Paths:
--------------
trunk/python-ogre/demos/media/materials/scripts/ASCII.material
trunk/python-ogre/demos/media/materials/scripts/ASMSwizzle.material
trunk/python-ogre/demos/media/materials/scripts/BlackAndWhite.material
trunk/python-ogre/demos/media/materials/scripts/Bloom.material
trunk/python-ogre/demos/media/materials/scripts/Bloom2.material
trunk/python-ogre/demos/media/materials/scripts/CGSwizzle.material
trunk/python-ogre/demos/media/materials/scripts/DOF.material
trunk/python-ogre/demos/media/materials/scripts/DepthShadowmap.material
trunk/python-ogre/demos/media/materials/scripts/Dither.material
trunk/python-ogre/demos/media/materials/scripts/Embossed.material
trunk/python-ogre/demos/media/materials/scripts/Example-DynTex.material
trunk/python-ogre/demos/media/materials/scripts/Example-Water.material
trunk/python-ogre/demos/media/materials/scripts/Example.material
trunk/python-ogre/demos/media/materials/scripts/Examples-Advanced.material
trunk/python-ogre/demos/media/materials/scripts/Examples.compositor
trunk/python-ogre/demos/media/materials/scripts/Examples.program
trunk/python-ogre/demos/media/materials/scripts/GLSLSwizzle.material
trunk/python-ogre/demos/media/materials/scripts/Glass.material
trunk/python-ogre/demos/media/materials/scripts/Halftone.material
trunk/python-ogre/demos/media/materials/scripts/HeatVision.material
trunk/python-ogre/demos/media/materials/scripts/Hurt.material
trunk/python-ogre/demos/media/materials/scripts/Invert.material
trunk/python-ogre/demos/media/materials/scripts/IsoSurf.material
trunk/python-ogre/demos/media/materials/scripts/Laplace.material
trunk/python-ogre/demos/media/materials/scripts/MRTtest.material
trunk/python-ogre/demos/media/materials/scripts/MotionBlur.material
trunk/python-ogre/demos/media/materials/scripts/NightVision.material
trunk/python-ogre/demos/media/materials/scripts/Ocean.controls
trunk/python-ogre/demos/media/materials/scripts/Ocean.material
trunk/python-ogre/demos/media/materials/scripts/OffsetMapping.material
trunk/python-ogre/demos/media/materials/scripts/Ogre.material
trunk/python-ogre/demos/media/materials/scripts/OldMovie.material
trunk/python-ogre/demos/media/materials/scripts/OldTV.material
trunk/python-ogre/demos/media/materials/scripts/ParticleGS.material
trunk/python-ogre/demos/media/materials/scripts/Posterize.material
trunk/python-ogre/demos/media/materials/scripts/RZR-002.material
trunk/python-ogre/demos/media/materials/scripts/RadialBlur.material
trunk/python-ogre/demos/media/materials/scripts/SharpenEdges.material
trunk/python-ogre/demos/media/materials/scripts/StdQuad_vp.program
trunk/python-ogre/demos/media/materials/scripts/Tiling.material
trunk/python-ogre/demos/media/materials/scripts/VarianceShadowmap.material
trunk/python-ogre/demos/media/materials/scripts/facial.material
trunk/python-ogre/demos/media/materials/scripts/hdr.material
trunk/python-ogre/demos/media/materials/scripts/instancing.material
trunk/python-ogre/demos/media/materials/scripts/pssm.material
trunk/python-ogre/demos/media/materials/scripts/smoke.material
Modified: trunk/python-ogre/demos/media/materials/scripts/ASCII.material
===================================================================
--- trunk/python-ogre/demos/media/materials/scripts/ASCII.material 2008-10-28 14:16:13 UTC (rev 780)
+++ trunk/python-ogre/demos/media/materials/scripts/ASCII.material 2008-10-30 03:03:17 UTC (rev 781)
@@ -1,55 +1,55 @@
-fragment_program Ogre/Compositor/ASCIIFP cg
-{
- source ASCIIFP.cg
- entry_point ASCII_ps
- profiles ps_2_0 arbfp1
-
- default_params
- {
- param_named iNumTiles float2 0.010 0.02
- param_named iNumTiles2 float2 0.005 0.01
- param_named numTiles float2 100 50
- param_named lum float4 0.30 0.59 0.11 0.0
- param_named charBias float 0.734375
- }
-}
-
-material Ogre/Compositor/ASCII
-{
- technique
- {
-
- pass
- {
- cull_hardware none
- cull_software none
- depth_func always_pass
-
- vertex_program_ref Ogre/Compositor/StdQuad_Tex2a_vp
- {
- }
-
-
- fragment_program_ref Ogre/Compositor/ASCIIFP
- {
-
- }
-
- texture_unit RT
- {
- tex_coord_set 0
- tex_address_mode clamp
- filtering trilinear
- }
-
- texture_unit chars
- {
- texture ASCII.dds 3d
- filtering none
- tex_address_mode clamp
- }
-
- }
- }
-}
-
+fragment_program Ogre/Compositor/ASCIIFP cg
+{
+ source ASCIIFP.cg
+ entry_point ASCII_ps
+ profiles ps_2_0 arbfp1
+
+ default_params
+ {
+ param_named iNumTiles float2 0.010 0.02
+ param_named iNumTiles2 float2 0.005 0.01
+ param_named numTiles float2 100 50
+ param_named lum float4 0.30 0.59 0.11 0.0
+ param_named charBias float 0.734375
+ }
+}
+
+material Ogre/Compositor/ASCII
+{
+ technique
+ {
+
+ pass
+ {
+ cull_hardware none
+ cull_software none
+ depth_func always_pass
+
+ vertex_program_ref Ogre/Compositor/StdQuad_Tex2a_vp
+ {
+ }
+
+
+ fragment_program_ref Ogre/Compositor/ASCIIFP
+ {
+
+ }
+
+ texture_unit RT
+ {
+ tex_coord_set 0
+ tex_address_mode clamp
+ filtering trilinear
+ }
+
+ texture_unit chars
+ {
+ texture ASCII.dds 3d
+ filtering none
+ tex_address_mode clamp
+ }
+
+ }
+ }
+}
+
Modified: trunk/python-ogre/demos/media/materials/scripts/ASMSwizzle.material
===================================================================
--- trunk/python-ogre/demos/media/materials/scripts/ASMSwizzle.material 2008-10-28 14:16:13 UTC (rev 780)
+++ trunk/python-ogre/demos/media/materials/scripts/ASMSwizzle.material 2008-10-30 03:03:17 UTC (rev 781)
@@ -1,19 +1,19 @@
-geometry_program Ogre/GPTest/Swizzle_GP_ASM asm
-{
- source Swizzle.gp
- syntax nvgp4
-}
-
-material Ogre/GPTest/SwizzleASM
-{
- technique SwizzleTechnique
- {
- pass SwizzleASMPass
- {
- geometry_program_ref Ogre/GPTest/Swizzle_GP_ASM
- {
-
- }
- }
- }
-}
+geometry_program Ogre/GPTest/Swizzle_GP_ASM asm
+{
+ source Swizzle.gp
+ syntax nvgp4
+}
+
+material Ogre/GPTest/SwizzleASM
+{
+ technique SwizzleTechnique
+ {
+ pass SwizzleASMPass
+ {
+ geometry_program_ref Ogre/GPTest/Swizzle_GP_ASM
+ {
+
+ }
+ }
+ }
+}
Modified: trunk/python-ogre/demos/media/materials/scripts/BlackAndWhite.material
===================================================================
--- trunk/python-ogre/demos/media/materials/scripts/BlackAndWhite.material 2008-10-28 14:16:13 UTC (rev 780)
+++ trunk/python-ogre/demos/media/materials/scripts/BlackAndWhite.material 2008-10-30 03:03:17 UTC (rev 781)
@@ -1,34 +1,34 @@
-fragment_program Ogre/Compositor/B&W_FP cg
-{
- source GrayScale.cg
- entry_point GrayScale_ps
- profiles ps_2_0 arbfp1
-}
-
-material Ogre/Compositor/BlackAndWhite
-{
- technique
- {
-
- pass
- {
- depth_check off
-
- vertex_program_ref Ogre/Compositor/StdQuad_Cg_vp
- {
- }
-
- fragment_program_ref Ogre/Compositor/B&W_FP
- {
- }
-
- texture_unit
- {
- texture RT
- tex_coord_set 0
- tex_address_mode clamp
- filtering linear linear linear
- }
- }
- }
-}
+fragment_program Ogre/Compositor/B&W_FP cg
+{
+ source GrayScale.cg
+ entry_point GrayScale_ps
+ profiles ps_2_0 arbfp1
+}
+
+material Ogre/Compositor/BlackAndWhite
+{
+ technique
+ {
+
+ pass
+ {
+ depth_check off
+
+ vertex_program_ref Ogre/Compositor/StdQuad_Cg_vp
+ {
+ }
+
+ fragment_program_ref Ogre/Compositor/B&W_FP
+ {
+ }
+
+ texture_unit
+ {
+ texture RT
+ tex_coord_set 0
+ tex_address_mode clamp
+ filtering linear linear linear
+ }
+ }
+ }
+}
Modified: trunk/python-ogre/demos/media/materials/scripts/Bloom.material
===================================================================
--- trunk/python-ogre/demos/media/materials/scripts/Bloom.material 2008-10-28 14:16:13 UTC (rev 780)
+++ trunk/python-ogre/demos/media/materials/scripts/Bloom.material 2008-10-30 03:03:17 UTC (rev 781)
@@ -1,178 +1,178 @@
-//DirectX 9.0 HLSL Vertex Shader vs_1_1
-vertex_program Blur0_vs11 hlsl
-{
- source Blur0_vs11.hlsl
- target vs_1_1
- entry_point main
-}
-
-//DirectX 9.0 HLSL Pixel Shader ps_2_0
-fragment_program Blur0_ps20 hlsl
-{
- source Blur0_ps20.hlsl
- target ps_2_0
- entry_point main
-}
-
-//DirectX 9.0 HLSL Vertex Shader vs_1_1
-vertex_program Blur1_vs11 hlsl
-{
- source Blur1_vs11.hlsl
- target vs_1_1
- entry_point main
-}
-
-//DirectX 9.0 HLSL Pixel Shader ps_2_0
-fragment_program Blur1_ps20 hlsl
-{
- source Blur1_ps20.hlsl
- target ps_2_0
- entry_point main
-}
-
-vertex_program Blur0_vs_glsl glsl
-{
- source Blur0_vs.glsl
-}
-vertex_program Blur1_vs_glsl glsl
-{
- source Blur1_vs.glsl
-}
-fragment_program Blur_ps_glsl glsl
-{
- source Blur_ps.glsl
- default_params
- {
- param_named tex0 int 0
- }
-}
-
-//Effect: Bloom
-material Ogre/Compositor/Blur0
-{
- technique
- {
- //Rendering Pass: Blur0 (pass index: #1 )
- pass
- {
- //State: D3DRS_CULLMODE, Value : D3DCULL_NONE
- cull_hardware none
- cull_software none
- depth_check off
-
- fragment_program_ref Blur0_ps20
- {
- }
- vertex_program_ref Blur0_vs11
- {
- }
- texture_unit RT
- {
- tex_coord_set 0
- tex_address_mode clamp
- filtering linear linear linear
- }
- }
- }
- technique
- {
- //Rendering Pass: Blur0 (pass index: #1 )
- pass
- {
- cull_hardware none
- cull_software none
- depth_check off
-
- fragment_program_ref Blur_ps_glsl
- {
- }
- vertex_program_ref Blur0_vs_glsl
- {
- }
- texture_unit RT
- {
- tex_coord_set 0
- tex_address_mode clamp
- filtering linear linear linear
- }
- }
- }
-}
-
-material Ogre/Compositor/Blur1
-{
- technique
- {
-
- //Rendering Pass: Blur1 (pass index: #2 )
- pass
- {
- cull_hardware none
- cull_software none
- depth_check off
-
- fragment_program_ref Blur1_ps20
- {
- }
- vertex_program_ref Blur1_vs11
- {
- }
- texture_unit
- {
- tex_coord_set 0
- tex_address_mode clamp
- filtering linear linear linear
- }
- }
- }
- technique
- {
-
- //Rendering Pass: Blur1 (pass index: #2 )
- pass
- {
- cull_hardware none
- cull_software none
- depth_func always_pass
-
- fragment_program_ref Blur_ps_glsl
- {
- }
- vertex_program_ref Blur1_vs_glsl
- {
- }
- texture_unit
- {
- tex_coord_set 0
- tex_address_mode clamp
- filtering linear linear linear
- }
- }
- }
-}
-
-/// Overlay quad
-material Ogre/Compositor/BloomBlend
-{
- technique
- {
- pass
- {
- lighting on
- diffuse 0.0 0.0 0.0 0.6
- specular 0.0 0.0 0.0 0.0
- ambient 0.0 0.0 0.0
- emissive 1.0 1.0 1.0
- cull_hardware none
- depth_check off
- scene_blend alpha_blend
-
- texture_unit
- {
- tex_coord_set 0
- tex_address_mode clamp
- filtering linear linear linear
- }
- }
- }
-}
+//DirectX 9.0 HLSL Vertex Shader vs_1_1
+vertex_program Blur0_vs11 hlsl
+{
+ source Blur0_vs11.hlsl
+ target vs_1_1
+ entry_point main
+}
+
+//DirectX 9.0 HLSL Pixel Shader ps_2_0
+fragment_program Blur0_ps20 hlsl
+{
+ source Blur0_ps20.hlsl
+ target ps_2_0
+ entry_point main
+}
+
+//DirectX 9.0 HLSL Vertex Shader vs_1_1
+vertex_program Blur1_vs11 hlsl
+{
+ source Blur1_vs11.hlsl
+ target vs_1_1
+ entry_point main
+}
+
+//DirectX 9.0 HLSL Pixel Shader ps_2_0
+fragment_program Blur1_ps20 hlsl
+{
+ source Blur1_ps20.hlsl
+ target ps_2_0
+ entry_point main
+}
+
+vertex_program Blur0_vs_glsl glsl
+{
+ source Blur0_vs.glsl
+}
+vertex_program Blur1_vs_glsl glsl
+{
+ source Blur1_vs.glsl
+}
+fragment_program Blur_ps_glsl glsl
+{
+ source Blur_ps.glsl
+ default_params
+ {
+ param_named tex0 int 0
+ }
+}
+
+//Effect: Bloom
+material Ogre/Compositor/Blur0
+{
+ technique
+ {
+ //Rendering Pass: Blur0 (pass index: #1 )
+ pass
+ {
+ //State: D3DRS_CULLMODE, Value : D3DCULL_NONE
+ cull_hardware none
+ cull_software none
+ depth_check off
+
+ fragment_program_ref Blur0_ps20
+ {
+ }
+ vertex_program_ref Blur0_vs11
+ {
+ }
+ texture_unit RT
+ {
+ tex_coord_set 0
+ tex_address_mode clamp
+ filtering linear linear linear
+ }
+ }
+ }
+ technique
+ {
+ //Rendering Pass: Blur0 (pass index: #1 )
+ pass
+ {
+ cull_hardware none
+ cull_software none
+ depth_check off
+
+ fragment_program_ref Blur_ps_glsl
+ {
+ }
+ vertex_program_ref Blur0_vs_glsl
+ {
+ }
+ texture_unit RT
+ {
+ tex_coord_set 0
+ tex_address_mode clamp
+ filtering linear linear linear
+ }
+ }
+ }
+}
+
+material Ogre/Compositor/Blur1
+{
+ technique
+ {
+
+ //Rendering Pass: Blur1 (pass index: #2 )
+ pass
+ {
+ cull_hardware none
+ cull_software none
+ depth_check off
+
+ fragment_program_ref Blur1_ps20
+ {
+ }
+ vertex_program_ref Blur1_vs11
+ {
+ }
+ texture_unit
+ {
+ tex_coord_set 0
+ tex_address_mode clamp
+ filtering linear linear linear
+ }
+ }
+ }
+ technique
+ {
+
+ //Rendering Pass: Blur1 (pass index: #2 )
+ pass
+ {
+ cull_hardware none
+ cull_software none
+ depth_func always_pass
+
+ fragment_program_ref Blur_ps_glsl
+ {
+ }
+ vertex_program_ref Blur1_vs_glsl
+ {
+ }
+ texture_unit
+ {
+ tex_coord_set 0
+ tex_address_mode clamp
+ filtering linear linear linear
+ }
+ }
+ }
+}
+
+/// Overlay quad
+material Ogre/Compositor/BloomBlend
+{
+ technique
+ {
+ pass
+ {
+ lighting on
+ diffuse 0.0 0.0 0.0 0.6
+ specular 0.0 0.0 0.0 0.0
+ ambient 0.0 0.0 0.0
+ emissive 1.0 1.0 1.0
+ cull_hardware none
+ depth_check off
+ scene_blend alpha_blend
+
+ texture_unit
+ {
+ tex_coord_set 0
+ tex_address_mode clamp
+ filtering linear linear linear
+ }
+ }
+ }
+}
Modified: trunk/python-ogre/demos/media/materials/scripts/Bloom2.material
===================================================================
--- trunk/python-ogre/demos/media/materials/scripts/Bloom2.material 2008-10-28 14:16:13 UTC (rev 780)
+++ trunk/python-ogre/demos/media/materials/scripts/Bloom2.material 2008-10-30 03:03:17 UTC (rev 781)
@@ -1,276 +1,276 @@
-//---------------------------------------------------
-//Bloom2: Dark Sylinc's Bloom implementation
-// Ogre/Compositor/BloomBlend is the final material applied.
-// it has 2 parameters:
-// OriginalImageWeight float
-// BlurWeight float
-// Usually they range from 0.0 to 1.0; but it can be any number
-// higher numbers will result in a brighter scene. Increment BlurWeight
-// to obtain increase Bloom effect.
-// Works faster on my GeForce 6200 256 MB AGP 8x (Chip NV 43 Rev a1)
-// than Manuel's bloom. (And at my opinion, looks nicer ;)
-// Unlike Manuel's bloom, we apply a bright high-filter pass
-//Copyright (C) Dark Sylinc 2007-2008
-//---------------------------------------------------
-
-// NB not using GLSL versions since ATI GLSL compiler has a problem with
-// BlurV_ps20
-//------------------------
-//OpenGL GLSL Definitions
-//------------------------
-vertex_program Blur_vs_glsl glsl
-{
- source Blur_vs.glsl
-}
-fragment_program BlurV_ps20_glsl glsl
-{
- source BlurV_ps20.glsl
-}
-fragment_program BlurH_ps20_glsl glsl
-{
- source BlurH_ps20.glsl
-}
-fragment_program BrightBloom2_ps20_glsl glsl
-{
- source BrightBloom2_ps20.glsl
-}
-fragment_program Bloom2_ps20_glsl glsl
-{
- source Bloom2_ps20.glsl
- default_params
- {
- param_named RT int 0
- param_named Blur1 int 1
- }
-}
-
-//------------------------
-//DirectX 9.0 HLSL Definitions
-//------------------------
-//DirectX 9.0 HLSL Vertex Shader vs_1_1
-vertex_program Blur_vs11_hlsl hlsl
-{
- source Blur_vs11.hlsl
- target vs_1_1
- entry_point main
-}
-
-//DirectX 9.0 HLSL Pixel Shader ps_2_0
-fragment_program BlurV_ps20_hlsl hlsl
-{
- source BlurV_ps20.hlsl
- target ps_2_0
- entry_point main
-}
-fragment_program BlurH_ps20_hlsl hlsl
-{
- source BlurH_ps20.hlsl
- target ps_2_0
- entry_point main
-}
-
-//DirectX 9.0 HLSL Pixel Shader ps_2_0
-fragment_program Bloom2_ps20_hlsl hlsl
-{
- source Bloom2_ps20.hlsl
- target ps_2_0
- entry_point main
-}
-
-//DirectX 9.0 HLSL Pixel Shader ps_2_0
-fragment_program BrightBloom2_ps20_hlsl hlsl
-{
- source BrightBloom2_ps20.hlsl
- target ps_2_0
- entry_point main
-}
-
-//------------------------
-//NVIDIA Cg Definitions
-//------------------------
-//NV Cg Vertex Shader vs_1_1
-vertex_program Blur_vs11_cg cg
-{
- source Blur_vs11.hlsl
- profiles vs_1_1 arbvp1
- entry_point main
-}
-
-//NV Cg HLSL Pixel Shader ps_2_0
-fragment_program BlurV_ps20_cg cg
-{
- source BlurV_ps20.hlsl
- profiles ps_2_0 arbfp1
- entry_point main
-}
-fragment_program BlurH_ps20_cg cg
-{
- source BlurH_ps20.hlsl
- profiles ps_2_0 arbfp1
- entry_point main
-}
-
-//NV Cg Pixel Shader ps_2_0
-fragment_program Bloom2_ps20_cg cg
-{
- source Bloom2_ps20.hlsl
- profiles ps_2_0 arbfp1
- entry_point main
-}
-
-//NV Cg Pixel Shader ps_2_0
-fragment_program BrightBloom2_ps20_cg cg
-{
- source BrightBloom2_ps20.hlsl
- profiles ps_2_0 arbfp1
- entry_point main
-}
-
-//------------------------
-//Unified Definitions
-//------------------------
-vertex_program Blur_vs unified
-{
- delegate Blur_vs11_hlsl
- //delegate Blur_vs_glsl
- delegate Blur_vs11_cg
-}
-
-fragment_program Bloom2_ps unified
-{
- delegate Bloom2_ps20_hlsl
- //delegate Bloom2_ps20_glsl
- delegate Bloom2_ps20_cg
-}
-fragment_program BlurV_ps unified
-{
- delegate BlurV_ps20_hlsl
- //delegate BlurV_ps20_glsl
- delegate BlurV_ps20_cg
-}
-fragment_program BlurH_ps unified
-{
- delegate BlurH_ps20_hlsl
- //delegate BlurH_ps20_glsl
- delegate BlurH_ps20_cg
-}
-fragment_program BrightBloom2_ps unified
-{
- delegate BrightBloom2_ps20_hlsl
- //delegate BrightBloom2_ps20_glsl
- delegate BrightBloom2_ps20_cg
-}
-
-
-//Blur: Horizontal Gaussian pass
-material Ogre/Compositor/BlurH
-{
- technique
- {
- pass
- {
- cull_hardware none
- cull_software none
- depth_check off
-
- fragment_program_ref BlurH_ps
- {
- }
- vertex_program_ref Blur_vs
- {
- }
- texture_unit
- {
- tex_coord_set 0
- tex_address_mode clamp
- filtering trilinear
- }
- }
- }
-}
-
-//Blur: Vertical Gaussian pass
-material Ogre/Compositor/BlurV
-{
- technique
- {
- pass
- {
- cull_hardware none
- cull_software none
- depth_check off
-
- fragment_program_ref BlurV_ps
- {
- }
- vertex_program_ref Blur_vs
- {
- }
- texture_unit
- {
- tex_coord_set 0
- tex_address_mode clamp
- filtering trilinear
- }
- }
- }
-}
-
-//Final Bloom pass: Blends the blurred with the sharp image
-material Ogre/Compositor/BloomBlend2
-{
- technique
- {
- pass
- {
- cull_hardware none
- cull_software none
- depth_check off
-
- fragment_program_ref Bloom2_ps
- {
- param_named OriginalImageWeight float 1.0
- param_named BlurWeight float 0.65
- }
- //vertex_program_ref Blur_vs
- // {
- // }
- texture_unit
- {
- tex_coord_set 0
- tex_address_mode clamp
- filtering none
- }
- texture_unit
- {
- tex_coord_set 0
- tex_address_mode clamp
- filtering trilinear
- }
- }
- }
-}
-
-//High-pass Bright filter
-//First pass
-material Ogre/Compositor/BrightPass2
-{
- technique
- {
- pass
- {
- cull_hardware none
- cull_software none
- depth_check off
-
- fragment_program_ref BrightBloom2_ps
- {
- }
- texture_unit
- {
- tex_address_mode clamp
- filtering none
- }
- }
- }
-}
+//---------------------------------------------------
+//Bloom2: Dark Sylinc's Bloom implementation
+// Ogre/Compositor/BloomBlend is the final material applied.
+// it has 2 parameters:
+// OriginalImageWeight float
+// BlurWeight float
+// Usually they range from 0.0 to 1.0; but it can be any number
+// higher numbers will result in a brighter scene. Increment BlurWeight
+// to obtain increase Bloom effect.
+// Works faster on my GeForce 6200 256 MB AGP 8x (Chip NV 43 Rev a1)
+// than Manuel's bloom. (And at my opinion, looks nicer ;)
+// Unlike Manuel's bloom, we apply a bright high-filter pass
+//Copyright (C) Dark Sylinc 2007-2008
+//---------------------------------------------------
+
+// NB not using GLSL versions since ATI GLSL compiler has a problem with
+// BlurV_ps20
+//------------------------
+//OpenGL GLSL Definitions
+//------------------------
+vertex_program Blur_vs_glsl glsl
+{
+ source Blur_vs.glsl
+}
+fragment_program BlurV_ps20_glsl glsl
+{
+ source BlurV_ps20.glsl
+}
+fragment_program BlurH_ps20_glsl glsl
+{
+ source BlurH_ps20.glsl
+}
+fragment_program BrightBloom2_ps20_glsl glsl
+{
+ source BrightBloom2_ps20.glsl
+}
+fragment_program Bloom2_ps20_glsl glsl
+{
+ source Bloom2_ps20.glsl
+ default_params
+ {
+ param_named RT int 0
+ param_named Blur1 int 1
+ }
+}
+
+//------------------------
+//DirectX 9.0 HLSL Definitions
+//------------------------
+//DirectX 9.0 HLSL Vertex Shader vs_1_1
+vertex_program Blur_vs11_hlsl hlsl
+{
+ source Blur_vs11.hlsl
+ target vs_1_1
+ entry_point main
+}
+
+//DirectX 9.0 HLSL Pixel Shader ps_2_0
+fragment_program BlurV_ps20_hlsl hlsl
+{
+ source BlurV_ps20.hlsl
+ target ps_2_0
+ entry_point main
+}
+fragment_program BlurH_ps20_hlsl hlsl
+{
+ source BlurH_ps20.hlsl
+ target ps_2_0
+ entry_point main
+}
+
+//DirectX 9.0 HLSL Pixel Shader ps_2_0
+fragment_program Bloom2_ps20_hlsl hlsl
+{
+ source Bloom2_ps20.hlsl
+ target ps_2_0
+ entry_point main
+}
+
+//DirectX 9.0 HLSL Pixel Shader ps_2_0
+fragment_program BrightBloom2_ps20_hlsl hlsl
+{
+ source BrightBloom2_ps20.hlsl
+ target ps_2_0
+ entry_point main
+}
+
+//------------------------
+//NVIDIA Cg Definitions
+//------------------------
+//NV Cg Vertex Shader vs_1_1
+vertex_program Blur_vs11_cg cg
+{
+ source Blur_vs11.hlsl
+ profiles vs_1_1 arbvp1
+ entry_point main
+}
+
+//NV Cg HLSL Pixel Shader ps_2_0
+fragment_program BlurV_ps20_cg cg
+{
+ source BlurV_ps20.hlsl
+ profiles ps_2_0 arbfp1
+ entry_point main
+}
+fragment_program BlurH_ps20_cg cg
+{
+ source BlurH_ps20.hlsl
+ profiles ps_2_0 arbfp1
+ entry_point main
+}
+
+//NV Cg Pixel Shader ps_2_0
+fragment_program Bloom2_ps20_cg cg
+{
+ source Bloom2_ps20.hlsl
+ profiles ps_2_0 arbfp1
+ entry_point main
+}
+
+//NV Cg Pixel Shader ps_2_0
+fragment_program BrightBloom2_ps20_cg cg
+{
+ source BrightBloom2_ps20.hlsl
+ profiles ps_2_0 arbfp1
+ entry_point main
+}
+
+//------------------------
+//Unified Definitions
+//------------------------
+vertex_program Blur_vs unified
+{
+ delegate Blur_vs11_hlsl
+ //delegate Blur_vs_glsl
+ delegate Blur_vs11_cg
+}
+
+fragment_program Bloom2_ps unified
+{
+ delegate Bloom2_ps20_hlsl
+ //delegate Bloom2_ps20_glsl
+ delegate Bloom2_ps20_cg
+}
+fragment_program BlurV_ps unified
+{
+ delegate BlurV_ps20_hlsl
+ //delegate BlurV_ps20_glsl
+ delegate BlurV_ps20_cg
+}
+fragment_program BlurH_ps unified
+{
+ delegate BlurH_ps20_hlsl
+ //delegate BlurH_ps20_glsl
+ delegate BlurH_ps20_cg
+}
+fragment_program BrightBloom2_ps unified
+{
+ delegate BrightBloom2_ps20_hlsl
+ //delegate BrightBloom2_ps20_glsl
+ delegate BrightBloom2_ps20_cg
+}
+
+
+//Blur: Horizontal Gaussian pass
+material Ogre/Compositor/BlurH
+{
+ technique
+ {
+ pass
+ {
+ cull_hardware none
+ cull_software none
+ depth_check off
+
+ fragment_program_ref BlurH_ps
+ {
+ }
+ vertex_program_ref Blur_vs
+ {
+ }
+ texture_unit
+ {
+ tex_coord_set 0
+ tex_address_mode clamp
+ filtering trilinear
+ }
+ }
+ }
+}
+
+//Blur: Vertical Gaussian pass
+material Ogre/Compositor/BlurV
+{
+ technique
+ {
+ pass
+ {
+ cull_hardware none
+ cull_software none
+ depth_check off
+
+ fragment_program_ref BlurV_ps
+ {
+ }
+ vertex_program_ref Blur_vs
+ {
+ }
+ texture_unit
+ {
+ tex_coord_set 0
+ tex_address_mode clamp
+ filtering trilinear
+ }
+ }
+ }
+}
+
+//Final Bloom pass: Blends the blurred with the sharp image
+material Ogre/Compositor/BloomBlend2
+{
+ technique
+ {
+ pass
+ {
+ cull_hardware none
+ cull_software none
+ depth_check off
+
+ fragment_program_ref Bloom2_ps
+ {
+ param_named OriginalImageWeight float 1.0
+ param_named BlurWeight float 0.65
+ }
+ //vertex_program_ref Blur_vs
+ // {
+ // }
+ texture_unit
+ {
+ tex_coord_set 0
+ tex_address_mode clamp
+ filtering none
+ }
+ texture_unit
+ {
+ tex_coord_set 0
+ tex_address_mode clamp
+ filtering trilinear
+ }
+ }
+ }
+}
+
+//High-pass Bright filter
+//First pass
+material Ogre/Compositor/BrightPass2
+{
+ technique
+ {
+ pass
+ {
+ cull_hardware none
+ cull_software none
+ depth_check off
+
+ fragment_program_ref BrightBloom2_ps
+ {
+ }
+ texture_unit
+ {
+ tex_address_mode clamp
+ filtering none
+ }
+ }
+ }
+}
Modified: trunk/python-ogre/demos/media/materials/scripts/CGSwizzle.material
===================================================================
--- trunk/python-ogre/demos/media/materials/scripts/CGSwizzle.material 2008-10-28 14:16:13 UTC (rev 780)
+++ trunk/python-ogre/demos/media/materials/scripts/CGSwizzle.material 2008-10-30 03:03:17 UTC (rev 781)
@@ -1,20 +1,20 @@
-geometry_program Ogre/GPTest/Swizzle_GP_CG cg
-{
- source SwizzleGP.cg
- entry_point gs_swizzle
- profiles gp4gp gpu_gp
-}
-
-material Ogre/GPTest/SwizzleCG
-{
- technique
- {
- pass SwizzleCGPass
- {
- geometry_program_ref Ogre/GPTest/Swizzle_GP_CG
- {
-
- }
- }
- }
+geometry_program Ogre/GPTest/Swizzle_GP_CG cg
+{
+ source SwizzleGP.cg
+ entry_point gs_swizzle
+ profiles gp4gp gpu_gp
+}
+
+material Ogre/GPTest/SwizzleCG
+{
+ technique
+ {
+ pass SwizzleCGPass
+ {
+ geometry_program_ref Ogre/GPTest/Swizzle_GP_CG
+ {
+
+ }
+ }
+ }
}
\ No newline at end of file
Modified: trunk/python-ogre/demos/media/materials/scripts/DOF.material
===================================================================
--- trunk/python-ogre/demos/media/materials/scripts/DOF.material 2008-10-28 14:16:13 UTC (rev 780)
+++ trunk/python-ogre/demos/media/materials/scripts/DOF.material 2008-10-30 03:03:17 UTC (rev 781)
@@ -1,94 +1,94 @@
-fragment_program DOF_Blur_ps cg
-{
- source DOF_ps.cg
- entry_point blur
- profiles ps_2_0 arbfp1
-}
-
-fragment_program DOF_Blend_ps cg
-{
- source DOF_ps.cg
- entry_point blend
- profiles ps_2_0 arbfp1
-}
-
-//Effect: Depth of Field
-material Ogre/Compositor/DOF_Blur0
-{
- technique
- {
- //Rendering Pass: Blur0 (pass index: #1 )
- pass
- {
- //State: D3DRS_CULLMODE, Value : D3DCULL_NONE
- cull_hardware none
- cull_software none
- depth_check off
-
- fragment_program_ref DOF_Blur_ps
- {
- param_named sampleDistance float 0.1
- }
- vertex_program_ref Ogre/Compositor/StdQuad_Tex2a_vp
- {
- }
- texture_unit
- {
- // texture will get added at runtime
- tex_coord_set 0
- tex_address_mode wrap
- filtering trilinear
- }
- }
- }
-}
-
-// cheat here by copying from DOF_Blur0
-material Ogre/Compositor/DOF_Blur1 : Ogre/Compositor/DOF_Blur0
-{
- technique
- {
- //Rendering Pass: Blur0 (pass index: #1 )
- pass
- {
- // use the same pixel shader as DOF_Blur0
- //fragment_program_ref
- //{
- // override value from copied DOF_Blur0 material
- // param_named sampleDistance float 0.1
- //}
- }
- }
-}
-
-material Ogre/Compositor/DOF_Blend
-{
- technique
- {
- pass
- {
- fragment_program_ref DOF_Blend_ps
- {
- param_named focus float 0.66
- param_named range float 1.0
- }
- vertex_program_ref Ogre/Compositor/StdQuad_Tex2a_vp
- {
- }
- texture_unit Blur0
- {
- // texture will get added at runtime
- tex_coord_set 0
- tex_address_mode clamp
- filtering trilinear
- }
- texture_unit Blur1
- {
- // texture will get added at runtime
- tex_coord_set 0
- tex_address_mode clamp
- filtering trilinear
- }
- }
- }
-}
+fragment_program DOF_Blur_ps cg
+{
+ source DOF_ps.cg
+ entry_point blur
+ profiles ps_2_0 arbfp1
+}
+
+fragment_program DOF_Blend_ps cg
+{
+ source DOF_ps.cg
+ entry_point blend
+ profiles ps_2_0 arbfp1
+}
+
+//Effect: Depth of Field
+material Ogre/Compositor/DOF_Blur0
+{
+ technique
+ {
+ //Rendering Pass: Blur0 (pass index: #1 )
+ pass
+ {
+ //State: D3DRS_CULLMODE, Value : D3DCULL_NONE
+ cull_hardware none
+ cull_software none
+ depth_check off
+
+ fragment_program_ref DOF_Blur_ps
+ {
+ param_named sampleDistance float 0.1
+ }
+ vertex_program_ref Ogre/Compositor/StdQuad_Tex2a_vp
+ {
+ }
+ texture_unit
+ {
+ // texture will get added at runtime
+ tex_coord_set 0
+ tex_address_mode wrap
+ filtering trilinear
+ }
+ }
+ }
+}
+
+// cheat here by copying from DOF_Blur0
+material Ogre/Compositor/DOF_Blur1 : Ogre/Compositor/DOF_Blur0
+{
+ technique
+ {
+ //Rendering Pass: Blur0 (pass index: #1 )
+ pass
+ {
+ // use the same pixel shader as DOF_Blur0
+ //fragment_program_ref
+ //{
+ // override value from copied DOF_Blur0 material
+ // param_named sampleDistance float 0.1
+ //}
+ }
+ }
+}
+
+material Ogre/Compositor/DOF_Blend
+{
+ technique
+ {
+ pass
+ {
+ fragment_program_ref DOF_Blend_ps
+ {
+ param_named focus float 0.66
+ param_named range float 1.0
+ }
+ vertex_program_ref Ogre/Compositor/StdQuad_Tex2a_vp
+ {
+ }
+ texture_unit Blur0
+ {
+ // texture will get added at runtime
+ tex_coord_set 0
+ tex_address_mode clamp
+ filtering trilinear
+ }
+ texture_unit Blur1
+ {
+ // texture will get added at runtime
+ tex_coord_set 0
+ tex_address_mode clamp
+ filtering trilinear
+ }
+ }
+ }
+}
Modified: trunk/python-ogre/demos/media/materials/scripts/DepthShadowmap.material
===================================================================
--- trunk/python-ogre/demos/media/materials/scripts/DepthShadowmap.material 2008-10-28 14:16:13 UTC (rev 780)
+++ trunk/python-ogre/demos/media/materials/scripts/DepthShadowmap.material 2008-10-30 03:03:17 UTC (rev 781)
@@ -1,595 +1,595 @@
-
-// ***-- Begin HLSL section --**
-
-vertex_program Ogre/DepthShadowmap/CasterVP_HLSL hlsl
-{
- source DepthShadowmap.hlsl
- entry_point casterVP
- target vs_2_0
-
- preprocessor_defines LINEAR_RANGE=0
-
- default_params
- {
- param_named_auto worldViewProj worldviewproj_matrix
- param_named_auto texelOffsets texel_offsets
- //param_named_auto depthRange scene_depth_range
- }
-}
-
-
-fragment_program Ogre/DepthShadowmap/CasterFP_HLSL hlsl
-{
- source DepthShadowmap.hlsl
- entry_point casterFP
- target ps_2_0
-
- preprocessor_defines LINEAR_RANGE=0
-
- default_params
- {
- }
-}
-
-
-vertex_program Ogre/DepthShadowmap/ReceiverVP_HLSL hlsl
-{
- source DepthShadowmap.hlsl
- entry_point receiverVP
- target vs_2_0
-
- preprocessor_defines LINEAR_RANGE=0
-
- default_params
- {
- param_named_auto world world_matrix
- param_named_auto worldIT inverse_transpose_world_matrix
- param_named_auto worldViewProj worldviewproj_matrix
- param_named_auto texViewProj texture_viewproj_matrix
- param_named_auto lightPosition light_position 0
- param_named_auto lightColour light_diffuse_colour 0
- //param_named_auto shadowDepthRange shadow_scene_depth_range 0
- }
-}
-
-
-fragment_program Ogre/DepthShadowmap/ReceiverFP_HLSL hlsl
-{
- source DepthShadowmap.hlsl
- entry_point receiverFP
- target ps_2_0
-
- preprocessor_defines LINEAR_RANGE=0,FUZZY_TEST=0,PCF=0
-
- default_params
- {
- param_named inverseShadowmapSize float 0.0009765625
- param_named fixedDepthBias float 0.0005
- param_named gradientClamp float 0.0098
- param_named gradientScaleBias float 0
- //param_named shadowFuzzyWidth float 1
- }
-}
-
-fragment_program Ogre/DepthShadowmap/ReceiverFPPCF_HLSL hlsl
-{
- source DepthShadowmap.hlsl
- entry_point receiverFP
- target ps_2_0
-
- preprocessor_defines LINEAR_RANGE=0,FUZZY_TEST=0,PCF=1
-
- default_params
- {
- param_named inverseShadowmapSize float 0.0009765625
- param_named gradientClamp float 0.0098
- param_named gradientScaleBias float 0
- //param_named shadowFuzzyWidth float 1
- }
-}
-vertex_program Ogre/DepthShadowmap/NormalMapReceiverVP_HLSL hlsl
-{
- source DepthShadowmap.hlsl
- entry_point normalMapShadowReceiverVp
- target vs_2_0
-
- preprocessor_defines LINEAR_RANGE=0
-
- default_params
- {
- param_named_auto world world_matrix
- param_named_auto worldViewProj worldviewproj_matrix
- param_named_auto texViewProj texture_viewproj_matrix
- param_named_auto lightPosition light_position_object_space 0
- //param_named_auto shadowDepthRange shadow_scene_depth_range 0
- }
-}
-
-fragment_program Ogre/DepthShadowmap/NormalMapReceiverFP_HLSL hlsl
-{
- source DepthShadowmap.hlsl
- entry_point normalMapShadowReceiverFp
- target ps_2_0
-
- preprocessor_defines LINEAR_RANGE=0,FUZZY_TEST=0,PCF=0
-
- default_params
- {
- param_named_auto lightColour light_diffuse_colour 0
- param_named inverseShadowmapSize float 0.0009765625
- param_named fixedDepthBias float 0.0005
- param_named gradientClamp float 0.0098
- param_named gradientScaleBias float 0
- //param_named shadowFuzzyWidth float 1
- }
-}
-fragment_program Ogre/DepthShadowmap/NormalMapReceiverFPPCF_HLSL hlsl
-{
- source DepthShadowmap.hlsl
- entry_point normalMapShadowReceiverFp
- target ps_2_0
-
- preprocessor_defines LINEAR_RANGE=0,FUZZY_TEST=0,PCF=1
-
- default_params
- {
- param_named_auto lightColour light_diffuse_colour 0
- param_named inverseShadowmapSize float 0.0009765625
- param_named fixedDepthBias float 0.0005
- param_named gradientClamp float 0.0098
- param_named gradientScaleBias float 0
- //param_named shadowFuzzyWidth float 1
- }
-}
-
-
-
-// **-- End HLSL Section --**
-
-// **-- Begin GLSL Section --**
-vertex_program Ogre/DepthShadowmap/CasterVP_GLSL glsl
-{
- source DepthShadowmapCasterVp.glsl
-
- preprocessor_defines LINEAR_RANGE=0
-
- default_params
- {
- param_named_auto worldViewProj worldviewproj_matrix
- param_named_auto texelOffsets texel_offsets
- //param_named_auto depthRange scene_depth_range
- }
-}
-
-
-fragment_program Ogre/DepthShadowmap/CasterFP_GLSL glsl
-{
- source DepthShadowmapCasterFp.glsl
-
- preprocessor_defines LINEAR_RANGE=0
-
- default_params
- {
- }
-}
-
-
-vertex_program Ogre/DepthShadowmap/ReceiverVP_GLSL glsl
-{
- source DepthShadowmapReceiverVp.glsl
-
- preprocessor_defines LINEAR_RANGE=0
-
- default_params
- {
- param_named_auto world world_matrix
- param_named_auto worldIT inverse_transpose_world_matrix
- param_named_auto worldViewProj worldviewproj_matrix
- param_named_auto texViewProj texture_viewproj_matrix
- param_named_auto lightPosition light_position 0
- param_named_auto lightColour light_diffuse_colour 0
- //param_named_auto shadowDepthRange shadow_scene_depth_range 0
- }
-}
-
-
-fragment_program Ogre/DepthShadowmap/ReceiverFP_GLSL glsl
-{
- source DepthShadowmapReceiverFp.glsl
-
- preprocessor_defines LINEAR_RANGE=0,FUZZY_TEST=0,PCF=0
-
- default_params
- {
- param_named shadowMap int 0
- param_named inverseShadowmapSize float 0.0009765625
- param_named fixedDepthBias float 0.0005
- param_named gradientClamp float 0.0098
- param_named gradientScaleBias float 0
- //param_named shadowFuzzyWidth float 1
- }
-}
-
-fragment_program Ogre/DepthShadowmap/ReceiverFPPCF_GLSL glsl
-{
- source DepthShadowmapReceiverFp.glsl
-
- preprocessor_defines LINEAR_RANGE=0,FUZZY_TEST=0,PCF=1
-
- default_params
- {
- param_named inverseShadowmapSize float 0.0009765625
- param_named gradientClamp float 0.0098
- param_named gradientScaleBias float 0
- //param_named shadowFuzzyWidth float 1
- }
-}
-vertex_program Ogre/DepthShadowmap/NormalMapReceiverVP_GLSL glsl
-{
- source DepthShadowmapNormalMapReceiverVp.glsl
-
- preprocessor_defines LINEAR_RANGE=0
-
- default_params
- {
- param_named_auto world world_matrix
- param_named_auto worldViewProj worldviewproj_matrix
- param_named_auto texViewProj texture_viewproj_matrix
- param_named_auto lightPosition light_position_object_space 0
- //param_named_auto shadowDepthRange shadow_scene_depth_range 0
- }
-}
-
-fragment_program Ogre/DepthShadowmap/NormalMapReceiverFP_GLSL glsl
-{
- source DepthShadowmapNormalMapReceiverFp.glsl
-
- preprocessor_defines LINEAR_RANGE=0,FUZZY_TEST=0,PCF=0
-
- default_params
- {
- param_named_auto lightColour light_diffuse_colour 0
- param_named inverseShadowmapSize float 0.0009765625
- param_named fixedDepthBias float 0.0005
- param_named gradientClamp float 0.0098
- param_named gradientScaleBias float 0
- //param_named shadowFuzzyWidth float 1
-
- param_named shadowMap int 0
- param_named normalMap int 1
- }
-}
-fragment_program Ogre/DepthShadowmap/NormalMapReceiverFPPCF_GLSL glsl
-{
- source DepthShadowmapNormalMapReceiverFp.glsl
-
- preprocessor_defines LINEAR_RANGE=0,FUZZY_TEST=0,PCF=1
-
- default_params
- {
- param_named_auto lightColour light_diffuse_colour 0
- param_named inverseShadowmapSize float 0.0009765625
- param_named fixedDepthBias float 0.0005
- param_named gradientClamp float 0.0098
- param_named gradientScaleBias float 0
- //param_named shadowFuzzyWidth float 1
-
- param_named shadowMap int 0
- param_named normalMap int 1
- }
-}
-
-// **-- End GLSL Section --**
-
-// **-- Begin Unified Section --**
-vertex_program Ogre/DepthShadowmap/CasterVP unified
-{
- delegate Ogre/DepthShadowmap/CasterVP_GLSL
- delegate Ogre/DepthShadowmap/CasterVP_HLSL
-}
-fragment_program Ogre/DepthShadowmap/CasterFP unified
-{
- delegate Ogre/DepthShadowmap/CasterFP_GLSL
- delegate Ogre/DepthShadowmap/CasterFP_HLSL
-}
-vertex_program Ogre/DepthShadowmap/ReceiverVP unified
-{
- delegate Ogre/DepthShadowmap/ReceiverVP_GLSL
- delegate Ogre/DepthShadowmap/ReceiverVP_HLSL
-}
-fragment_program Ogre/DepthShadowmap/ReceiverFP unified
-{
- delegate Ogre/DepthShadowmap/ReceiverFP_GLSL
- delegate Ogre/DepthShadowmap/ReceiverFP_HLSL
-}
-fragment_program Ogre/DepthShadowmap/ReceiverFPPCF unified
-{
- delegate Ogre/DepthShadowmap/ReceiverFPPCF_GLSL
- delegate Ogre/DepthShadowmap/ReceiverFPPCF_HLSL
-}
-vertex_program Ogre/DepthShadowmap/NormalMapReceiverVP unified
-{
- delegate Ogre/DepthShadowmap/NormalMapReceiverVP_HLSL
- delegate Ogre/DepthShadowmap/NormalMapReceiverVP_GLSL
-}
-vertex_program Ogre/DepthShadowmap/NormalMapReceiverFP unified
-{
- delegate Ogre/DepthShadowmap/NormalMapReceiverFP_HLSL
- delegate Ogre/DepthShadowmap/NormalMapReceiverFP_GLSL
-}
-vertex_program Ogre/DepthShadowmap/NormalMapReceiverFPPCF unified
-{
- delegate Ogre/DepthShadowmap/NormalMapReceiverFPPCF_HLSL
- delegate Ogre/DepthShadowmap/NormalMapReceiverFPPCF_GLSL
-}
-
-// **-- End Unified Section --**
-
-
-
-// Generic Shadow caster material (floating point shadowmap)
-material Ogre/DepthShadowmap/Caster/Float
-{
- technique
- {
- pass
- {
- vertex_program_ref Ogre/DepthShadowmap/CasterVP
- {
- }
- fragment_program_ref Ogre/DepthShadowmap/CasterFP
- {
- }
- }
- }
-}
-
-// Generic Shadow receiver material (floating point shadowmap)
-material Ogre/DepthShadowmap/Receiver/Float
-{
- technique
- {
- pass
- {
- vertex_program_ref Ogre/DepthShadowmap/ReceiverVP
- {
- }
- fragment_program_ref Ogre/DepthShadowmap/ReceiverFP
- {
- }
- texture_unit ShadowMap
- {
- tex_address_mode clamp
- filtering none
- }
- }
- }
-}
-
-
-// Specific receiver material for rockwall
-material Ogre/DepthShadowmap/Receiver/RockWall
-{
-
- // This is the preferred technique which uses both vertex and
- // fragment programs, supports coloured lights
- technique
- {
- // Base ambient pass
- pass
- {
- // base colours, not needed for rendering, but as information
- // to lighting pass categorisation routine
- ambient 1 1 1
- diffuse 0 0 0
- specular 0 0 0 0
- // Really basic vertex program
- vertex_program_ref Ogre/BasicVertexPrograms/AmbientOneTextureUnified
- {
- }
-
- }
- // Now do the lighting pass
- // NB we don't do decal texture here because this is repeated per light
- pass lighting
- {
- // base colours, not needed for rendering, but as information
- // to lighting pass categorisation routine
- ambient 0 0 0
-
- // do this for each light
- iteration once_per_light
-
-
- scene_blend add
-
- // Vertex program reference
- vertex_program_ref Ogre/DepthShadowmap/ReceiverVP
- {
- }
- shadow_receiver_vertex_program_ref Ogre/DepthShadowmap/ReceiverVP
- {
- }
-
- // Fragment program
- fragment_program_ref Ogre/DepthShadowmap/ReceiverFP
- {
- }
- shadow_receiver_fragment_program_ref Ogre/DepthShadowmap/ReceiverFP
- {
- }
-
- // shadowmap texture will be bound by code
-
- }
-
- // Decal pass
- pass
- {
- // base colours, not needed for rendering, but as information
- // to lighting pass categorisation routine
- lighting off
- // Really basic vertex program
- vertex_program_ref Ogre/BasicVertexPrograms/AmbientOneTextureUnified
- {
- param_named ambient float4 1 1 1 1
- }
- scene_blend dest_colour zero
-
-
- texture_unit
- {
- texture rockwall.tga
- }
-
- }
- }
-
-
-}
-
-// Specific receiver material for Athene
-material Ogre/DepthShadowmap/Receiver/Athene
-{
-
- // This is the preferred technique which uses both vertex and
- // fragment programs, supports coloured lights
- technique
- {
- // Base ambient pass
- pass
- {
- // base colours, not needed for rendering, but as information
- // to lighting pass categorisation routine
- ambient 1 1 1
- diffuse 0 0 0
- specular 0 0 0 0
- // Really basic vertex program
- vertex_program_ref Ogre/BasicVertexPrograms/AmbientOneTextureUnified
- {
- }
-
- }
- // Now do the lighting pass
- // NB we don't do decal texture here because this is repeated per light
- pass lighting
- {
- // base colours, not needed for rendering, but as information
- // to lighting pass categorisation routine
- ambient 0 0 0
-
- // do this for each light
- iteration once_per_light
-
-
- scene_blend add
-
- // Vertex program reference
- vertex_program_ref Ogre/DepthShadowmap/NormalMapReceiverVP
- {
- }
- shadow_receiver_vertex_program_ref Ogre/DepthShadowmap/NormalMapReceiverVP
- {
- }
-
- // Fragment program
- fragment_program_ref Ogre/DepthShadowmap/NormalMapReceiverFP
- {
- }
- shadow_receiver_fragment_program_ref Ogre/DepthShadowmap/NormalMapReceiverFP
- {
- }
-
- // shadowmap texture will be bound by code
-
- // Base bump map
- texture_unit
- {
- texture atheneNormalMap.png
- colour_op replace
- }
- // Normalisation cube map
- texture_unit
- {
- cubic_texture nm.png combinedUVW
- tex_coord_set 1
- tex_address_mode clamp
- }
-
- }
-
- // Decal pass
- pass
- {
- // base colours, not needed for rendering, but as information
- // to lighting pass categorisation routine
- lighting off
- // Really basic vertex program
- vertex_program_ref Ogre/BasicVertexPrograms/AmbientOneTextureUnified
- {
- param_named ambient float4 1 1 1 1
- }
- scene_blend dest_colour zero
-
-
- texture_unit
- {
- texture egyptrockyfull.jpg
- }
-
- }
- }
-
-
-}
-
-
-
-// Specialisation to use PCF
-material Ogre/DepthShadowmap/Receiver/Float/PCF : Ogre/DepthShadowmap/Receiver/Float
-{
- technique
- {
- pass
- {
- // override just receiver program
- fragment_program_ref Ogre/DepthShadowmap/ReceiverFPPCF
- {
- }
-
- }
- }
-}
-
-// Specialisation to use PCF
-material Ogre/DepthShadowmap/Receiver/RockWall/PCF : Ogre/DepthShadowmap/Receiver/RockWall
-{
- technique
- {
- pass lighting
- {
- // override just receiver program
- shadow_receiver_fragment_program_ref Ogre/DepthShadowmap/ReceiverFPPCF
- {
- }
-
- }
- }
-}
-// Specialisation to use PCF
-material Ogre/DepthShadowmap/Receiver/Athene/PCF : Ogre/DepthShadowmap/Receiver/Athene
-{
- technique
- {
- pass lighting
- {
- // override just receiver program
- shadow_receiver_fragment_program_ref Ogre/DepthShadowmap/NormalMapReceiverFPPCF
- {
- }
-
- }
- }
-}
-
-
+
+// ***-- Begin HLSL section --**
+
+vertex_program Ogre/DepthShadowmap/CasterVP_HLSL hlsl
+{
+ source DepthShadowmap.hlsl
+ entry_point casterVP
+ target vs_2_0
+
+ preprocessor_defines LINEAR_RANGE=0
+
+ default_params
+ {
+ param_named_auto worldViewProj worldviewproj_matrix
+ param_named_auto texelOffsets texel_offsets
+ //param_named_auto depthRange scene_depth_range
+ }
+}
+
+
+fragment_program Ogre/DepthShadowmap/CasterFP_HLSL hlsl
+{
+ source DepthShadowmap.hlsl
+ entry_point casterFP
+ target ps_2_0
+
+ preprocessor_defines LINEAR_RANGE=0
+
+ default_params
+ {
+ }
+}
+
+
+vertex_program Ogre/DepthShadowmap/ReceiverVP_HLSL hlsl
+{
+ source DepthShadowmap.hlsl
+ entry_point receiverVP
+ target vs_2_0
+
+ preprocessor_defines LINEAR_RANGE=0
+
+ default_params
+ {
+ param_named_auto world world_matrix
+ param_named_auto worldIT inverse_transpose_world_matrix
+ param_named_auto worldViewProj worldviewproj_matrix
+ param_named_auto texViewProj texture_viewproj_matrix
+ param_named_auto lightPosition light_position 0
+ param_named_auto lightColour light_diffuse_colour 0
+ //param_named_auto shadowDepthRange shadow_scene_depth_range 0
+ }
+}
+
+
+fragment_program Ogre/DepthShadowmap/ReceiverFP_HLSL hlsl
+{
+ source DepthShadowmap.hlsl
+ entry_point receiverFP
+ target ps_2_0
+
+ preprocessor_defines LINEAR_RANGE=0,FUZZY_TEST=0,PCF=0
+
+ default_params
+ {
+ param_named inverseShadowmapSize float 0.0009765625
+ param_named fixedDepthBias float 0.0005
+ param_named gradientClamp float 0.0098
+ param_named gradientScaleBias float 0
+ //param_named shadowFuzzyWidth float 1
+ }
+}
+
+fragment_program Ogre/DepthShadowmap/ReceiverFPPCF_HLSL hlsl
+{
+ source DepthShadowmap.hlsl
+ entry_point receiverFP
+ target ps_2_0
+
+ preprocessor_defines LINEAR_RANGE=0,FUZZY_TEST=0,PCF=1
+
+ default_params
+ {
+ param_named inverseShadowmapSize float 0.0009765625
+ param_named gradientClamp float 0.0098
+ param_named gradientScaleBias float 0
+ //param_named shadowFuzzyWidth float 1
+ }
+}
+vertex_program Ogre/DepthShadowmap/NormalMapReceiverVP_HLSL hlsl
+{
+ source DepthShadowmap.hlsl
+ entry_point normalMapShadowReceiverVp
+ target vs_2_0
+
+ preprocessor_defines LINEAR_RANGE=0
+
+ default_params
+ {
+ param_named_auto world world_matrix
+ param_named_auto worldViewProj worldviewproj_matrix
+ param_named_auto texViewProj texture_viewproj_matrix
+ param_named_auto lightPosition light_position_object_space 0
+ //param_named_auto shadowDepthRange shadow_scene_depth_range 0
+ }
+}
+
+fragment_program Ogre/DepthShadowmap/NormalMapReceiverFP_HLSL hlsl
+{
+ source DepthShadowmap.hlsl
+ entry_point normalMapShadowReceiverFp
+ target ps_2_0
+
+ preprocessor_defines LINEAR_RANGE=0,FUZZY_TEST=0,PCF=0
+
+ default_params
+ {
+ param_named_auto lightColour light_diffuse_colour 0
+ param_named inverseShadowmapSize float 0.0009765625
+ param_named fixedDepthBias float 0.0005
+ param_named gradientClamp float 0.0098
+ param_named gradientScaleBias float 0
+ //param_named shadowFuzzyWidth float 1
+ }
+}
+fragment_program Ogre/DepthShadowmap/NormalMapReceiverFPPCF_HLSL hlsl
+{
+ source DepthShadowmap.hlsl
+ entry_point normalMapShadowReceiverFp
+ target ps_2_0
+
+ preprocessor_defines LINEAR_RANGE=0,FUZZY_TEST=0,PCF=1
+
+ default_params
+ {
+ param_named_auto lightColour light_diffuse_colour 0
+ param_named inverseShadowmapSize float 0.0009765625
+ param_named fixedDepthBias float 0.0005
+ param_named gradientClamp float 0.0098
+ param_named gradientScaleBias float 0
+ //param_named shadowFuzzyWidth float 1
+ }
+}
+
+
+
+// **-- End HLSL Section --**
+
+// **-- Begin GLSL Section --**
+vertex_program Ogre/DepthShadowmap/CasterVP_GLSL glsl
+{
+ source DepthShadowmapCasterVp.glsl
+
+ preprocessor_defines LINEAR_RANGE=0
+
+ default_params
+ {
+ param_named_auto worldViewProj worldviewproj_matrix
+ param_named_auto texelOffsets texel_offsets
+ //param_named_auto depthRange scene_depth_range
+ }
+}
+
+
+fragment_program Ogre/DepthShadowmap/CasterFP_GLSL glsl
+{
+ source DepthShadowmapCasterFp.glsl
+
+ preprocessor_defines LINEAR_RANGE=0
+
+ default_params
+ {
+ }
+}
+
+
+vertex_program Ogre/DepthShadowmap/ReceiverVP_GLSL glsl
+{
+ source DepthShadowmapReceiverVp.glsl
+
+ preprocessor_defines LINEAR_RANGE=0
+
+ default_params
+ {
+ param_named_auto world world_matrix
+ param_named_auto worldIT inverse_transpose_world_matrix
+ param_named_auto worldViewProj worldviewproj_matrix
+ param_named_auto texViewProj texture_viewproj_matrix
+ param_named_auto lightPosition light_position 0
+ param_named_auto lightColour light_diffuse_colour 0
+ //param_named_auto shadowDepthRange shadow_scene_depth_range 0
+ }
+}
+
+
+fragment_program Ogre/DepthShadowmap/ReceiverFP_GLSL glsl
+{
+ source DepthShadowmapReceiverFp.glsl
+
+ preprocessor_defines LINEAR_RANGE=0,FUZZY_TEST=0,PCF=0
+
+ default_params
+ {
+ param_named shadowMap int 0
+ param_named inverseShadowmapSize float 0.0009765625
+ param_named fixedDepthBias float 0.0005
+ param_named gradientClamp float 0.0098
+ param_named gradientScaleBias float 0
+ //param_named shadowFuzzyWidth float 1
+ }
+}
+
+fragment_program Ogre/DepthShadowmap/ReceiverFPPCF_GLSL glsl
+{
+ source DepthShadowmapReceiverFp.glsl
+
+ preprocessor_defines LINEAR_RANGE=0,FUZZY_TEST=0,PCF=1
+
+ default_params
+ {
+ param_named inverseShadowmapSize float 0.0009765625
+ param_named gradientClamp float 0.0098
+ param_named gradientScaleBias float 0
+ //param_named shadowFuzzyWidth float 1
+ }
+}
+vertex_program Ogre/DepthShadowmap/NormalMapReceiverVP_GLSL glsl
+{
+ source DepthShadowmapNormalMapReceiverVp.glsl
+
+ preprocessor_defines LINEAR_RANGE=0
+
+ default_params
+ {
+ param_named_auto world world_matrix
+ param_named_auto worldViewProj worldviewproj_matrix
+ param_named_auto texViewProj texture_viewproj_matrix
+ param_named_auto lightPosition light_position_object_space 0
+ //param_named_auto shadowDepthRange shadow_scene_depth_range 0
+ }
+}
+
+fragment_program Ogre/DepthShadowmap/NormalMapReceiverFP_GLSL glsl
+{
+ source DepthShadowmapNormalMapReceiverFp.glsl
+
+ preprocessor_defines LINEAR_RANGE=0,FUZZY_TEST=0,PCF=0
+
+ default_params
+ {
+ param_named_auto lightColour light_diffuse_colour 0
+ param_named inverseShadowmapSize float 0.0009765625
+ param_named fixedDepthBias float 0.0005
+ param_named gradientClamp float 0.0098
+ param_named gradientScaleBias float 0
+ //param_named shadowFuzzyWidth float 1
+
+ param_named shadowMap int 0
+ param_named normalMap int 1
+ }
+}
+fragment_program Ogre/DepthShadowmap/NormalMapReceiverFPPCF_GLSL glsl
+{
+ source DepthShadowmapNormalMapReceiverFp.glsl
+
+ preprocessor_defines LINEAR_RANGE=0,FUZZY_TEST=0,PCF=1
+
+ default_params
+ {
+ param_named_auto lightColour light_diffuse_colour 0
+ param_named inverseShadowmapSize float 0.0009765625
+ param_named fixedDepthBias float 0.0005
+ param_named gradientClamp float 0.0098
+ param_named gradientScaleBias float 0
+ //param_named shadowFuzzyWidth float 1
+
+ param_named shadowMap int 0
+ param_named normalMap int 1
+ }
+}
+
+// **-- End GLSL Section --**
+
+// **-- Begin Unified Section --**
+vertex_program Ogre/DepthShadowmap/CasterVP unified
+{
+ delegate Ogre/DepthShadowmap/CasterVP_GLSL
+ delegate Ogre/DepthShadowmap/CasterVP_HLSL
+}
+fragment_program Ogre/DepthShadowmap/CasterFP unified
+{
+ delegate Ogre/DepthShadowmap/CasterFP_GLSL
+ delegate Ogre/DepthShadowmap/CasterFP_HLSL
+}
+vertex_program Ogre/DepthShadowmap/ReceiverVP unified
+{
+ delegate Ogre/DepthShadowmap/ReceiverVP_GLSL
+ delegate Ogre/DepthShadowmap/ReceiverVP_HLSL
+}
+fragment_program Ogre/DepthShadowmap/ReceiverFP unified
+{
+ delegate Ogre/DepthShadowmap/ReceiverFP_GLSL
+ delegate Ogre/DepthShadowmap/ReceiverFP_HLSL
+}
+fragment_program Ogre/DepthShadowmap/ReceiverFPPCF unified
+{
+ delegate Ogre/DepthShadowmap/ReceiverFPPCF_GLSL
+ delegate Ogre/DepthShadowmap/ReceiverFPPCF_HLSL
+}
+vertex_program Ogre/DepthShadowmap/NormalMapReceiverVP unified
+{
+ delegate Ogre/DepthShadowmap/NormalMapReceiverVP_HLSL
+ delegate Ogre/DepthShadowmap/NormalMapReceiverVP_GLSL
+}
+vertex_program Ogre/DepthShadowmap/NormalMapReceiverFP unified
+{
+ delegate Ogre/DepthShadowmap/NormalMapReceiverFP_HLSL
+ delegate Ogre/DepthShadowmap/NormalMapReceiverFP_GLSL
+}
+vertex_program Ogre/DepthShadowmap/NormalMapReceiverFPPCF unified
+{
+ delegate Ogre/DepthShadowmap/NormalMapReceiverFPPCF_HLSL
+ delegate Ogre/DepthShadowmap/NormalMapReceiverFPPCF_GLSL
+}
+
+// **-- End Unified Section --**
+
+
+
+// Generic Shadow caster material (floating point shadowmap)
+material Ogre/DepthShadowmap/Caster/Float
+{
+ technique
+ {
+ pass
+ {
+ vertex_program_ref Ogre/DepthShadowmap/CasterVP
+ {
+ }
+ fragment_program_ref Ogre/DepthShadowmap/CasterFP
+ {
+ }
+ }
+ }
+}
+
+// Generic Shadow receiver material (floating point shadowmap)
+material Ogre/DepthShadowmap/Receiver/Float
+{
+ technique
+ {
+ pass
+ {
+ vertex_program_ref Ogre/DepthShadowmap/ReceiverVP
+ {
+ }
+ fragment_program_ref Ogre/DepthShadowmap/ReceiverFP
+ {
+ }
+ texture_unit ShadowMap
+ {
+ tex_address_mode clamp
+ filtering none
+ }
+ }
+ }
+}
+
+
+// Specific receiver material for rockwall
+material Ogre/DepthShadowmap/Receiver/RockWall
+{
+
+ // This is the preferred technique which uses both vertex and
+ // fragment programs, supports coloured lights
+ technique
+ {
+ // Base ambient pass
+ pass
+ {
+ // base colours, not needed for rendering, but as information
+ // to lighting pass categorisation routine
+ ambient 1 1 1
+ diffuse 0 0 0
+ specular 0 0 0 0
+ // Really basic vertex program
+ vertex_program_ref Ogre/BasicVertexPrograms/AmbientOneTextureUnified
+ {
+ }
+
+ }
+ // Now do the lighting pass
+ // NB we don't do decal texture here because this is repeated per light
+ pass lighting
+ {
+ // base colours, not needed for rendering, but as information
+ // to lighting pass categorisation routine
+ ambient 0 0 0
+
+ // do this for each light
+ iteration once_per_light
+
+
+ scene_blend add
+
+ // Vertex program reference
+ vertex_program_ref Ogre/DepthShadowmap/ReceiverVP
+ {
+ }
+ shadow_receiver_vertex_program_ref Ogre/DepthShadowmap/ReceiverVP
+ {
+ }
+
+ // Fragment program
+ fragment_program_ref Ogre/DepthShadowmap/ReceiverFP
+ {
+ }
+ shadow_receiver_fragment_program_ref Ogre/DepthShadowmap/ReceiverFP
+ {
+ }
+
+ // shadowmap texture will be bound by code
+
+ }
+
+ // Decal pass
+ pass
+ {
+ // base colours, not needed for rendering, but as information
+ // to lighting pass categorisation routine
+ lighting off
+ // Really basic vertex program
+ vertex_program_ref Ogre/BasicVertexPrograms/AmbientOneTextureUnified
+ {
+ param_named ambient float4 1 1 1 1
+ }
+ scene_blend dest_colour zero
+
+
+ texture_unit
+ {
+ texture rockwall.tga
+ }
+
+ }
+ }
+
+
+}
+
+// Specific receiver material for Athene
+material Ogre/DepthShadowmap/Receiver/Athene
+{
+
+ // This is the preferred technique which uses both vertex and
+ // fragment programs, supports coloured lights
+ technique
+ {
+ // Base ambient pass
+ pass
+ {
+ // base colours, not needed for rendering, but as information
+ // to lighting pass categorisation routine
+ ambient 1 1 1
+ diffuse 0 0 0
+ specular 0 0 0 0
+ // Really basic vertex program
+ vertex_program_ref Ogre/BasicVertexPrograms/AmbientOneTextureUnified
+ {
+ }
+
+ }
+ // Now do the lighting pass
+ // NB we don't do decal texture here because this is repeated per light
+ pass lighting
+ {
+ // base colours, not needed for rendering, but as information
+ // to lighting pass categorisation routine
+ ambient 0 0 0
+
+ // do this for each light
+ iteration once_per_light
+
+
+ scene_blend add
+
+ // Vertex program reference
+ vertex_program_ref Ogre/DepthShadowmap/NormalMapReceiverVP
+ {
+ }
+ shadow_receiver_vertex_program_ref Ogre/DepthShadowmap/NormalMapReceiverVP
+ {
+ }
+
+ // Fragment program
+ fragment_program_ref Ogre/DepthShadowmap/NormalMapReceiverFP
+ {
+ }
+ shadow_receiver_fragment_program_ref Ogre/DepthShadowmap/NormalMapReceiverFP
+ {
+ }
+
+ // shadowmap texture will be bound by code
+
+ // Base bump map
+ texture_unit
+ {
+ texture atheneNormalMap.png
+ colour_op replace
+ }
+ // Normalisation cube map
+ texture_unit
+ {
+ cubic_texture nm.png combinedUVW
+ tex_coord_set 1
+ tex_address_mode clamp
+ }
+
+ }
+
+ // Decal pass
+ pass
+ {
+ // base colours, not needed for rendering, but as information
+ // to lighting pass categorisation routine
+ lighting off
+ // Really basic vertex program
+ vertex_program_ref Ogre/BasicVertexPrograms/AmbientOneTextureUnified
+ {
+ param_named ambient float4 1 1 1 1
+ }
+ scene_blend dest_colour zero
+
+
+ texture_unit
+ {
+ texture egyptrockyfull.jpg
+ }
+
+ }
+ }
+
+
+}
+
+
+
+// Specialisation to use PCF
+material Ogre/DepthShadowmap/Receiver/Float/PCF : Ogre/DepthShadowmap/Receiver/Float
+{
+ technique
+ {
+ pass
+ {
+ // override just receiver program
+ fragment_program_ref Ogre/DepthShadowmap/ReceiverFPPCF
+ {
+ }
+
+ }
+ }
+}
+
+// Specialisation to use PCF
+material Ogre/DepthShadowmap/Receiver/RockWall/PCF : Ogre/DepthShadowmap/Receiver/RockWall
+{
+ technique
+ {
+ pass lighting
+ {
+ // override just receiver program
+ shadow_receiver_fragment_program_ref Ogre/DepthShadowmap/ReceiverFPPCF
+ {
+ }
+
+ }
+ }
+}
+// Specialisation to use PCF
+material Ogre/DepthShadowmap/Receiver/Athene/PCF : Ogre/DepthShadowmap/Receiver/Athene
+{
+ technique
+ {
+ pass lighting
+ {
+ // override just receiver program
+ shadow_receiver_fragment_program_ref Ogre/DepthShadowmap/NormalMapReceiverFPPCF
+ {
+ }
+
+ }
+ }
+}
+
+
Modified: trunk/python-ogre/demos/media/materials/scripts/Dither.material
===================================================================
--- trunk/python-ogre/demos/media/materials/scripts/Dither.material 2008-10-28 14:16:13 UTC (rev 780)
+++ trunk/python-ogre/demos/media/materials/scripts/Dither.material 2008-10-30 03:03:17 UTC (rev 781)
@@ -1,46 +1,46 @@
-fragment_program Ogre/Compositor/DitherFP cg
-{
- source DitherFP.cg
- entry_point Dither_ps
- profiles ps_2_0 arbfp1
-
-}
-
-material Ogre/Compositor/Dither
-{
- technique
- {
-
- pass
- {
- cull_hardware none
- cull_software none
- depth_func always_pass
-
- vertex_program_ref Ogre/Compositor/StdQuad_Tex2a_vp
- {
- }
-
-
- fragment_program_ref Ogre/Compositor/DitherFP
- {
-
- }
-
- texture_unit RT
- {
- tex_coord_set 0
- tex_address_mode clamp
- filtering trilinear
- }
-
- texture_unit noise
- {
- te...
[truncated message content] |