mirror of https://github.com/OpenMW/openmw.git
cleanup
parent
791d16bbdb
commit
42883ec64b
@ -1,91 +0,0 @@
|
||||
// Compositor that just controls output to the MRT textures
|
||||
compositor gbuffer
|
||||
{
|
||||
technique
|
||||
{
|
||||
// MRT output. Currently this is a color texture plus a depth texture
|
||||
texture mrt_output target_width target_height PF_FLOAT16_RGBA PF_FLOAT16_RGBA chain_scope depth_pool 2
|
||||
|
||||
target mrt_output
|
||||
{
|
||||
input none
|
||||
|
||||
pass clear
|
||||
{
|
||||
colour_value 0 0 0 1
|
||||
}
|
||||
pass render_quad
|
||||
{
|
||||
// this makes sure the depth for background is set to 1
|
||||
material openmw_viewport_init
|
||||
}
|
||||
pass render_scene
|
||||
{
|
||||
// Renders everything except water
|
||||
first_render_queue 0
|
||||
last_render_queue 50
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
target_output
|
||||
{
|
||||
input none
|
||||
|
||||
pass render_quad
|
||||
{
|
||||
material quad
|
||||
input 0 mrt_output 0
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// Finalizer compositor to render objects that we don't want in the MRT textures (ex. water)
|
||||
// NB the water has to be rendered in a seperate compositor anyway, because it
|
||||
// accesses the MRT textures which can't be done while they are still being rendered to.
|
||||
compositor gbufferFinalizer
|
||||
{
|
||||
technique
|
||||
{
|
||||
texture no_mrt_output target_width target_height PF_R8G8B8A8 depth_pool 2 no_fsaa
|
||||
texture previousscene target_width target_height PF_R8G8B8A8
|
||||
|
||||
target previousscene
|
||||
{
|
||||
input previous
|
||||
}
|
||||
target no_mrt_output
|
||||
{
|
||||
input none
|
||||
shadows off
|
||||
pass clear
|
||||
{
|
||||
buffers colour
|
||||
colour_value 0 0 0 0
|
||||
}
|
||||
pass render_quad
|
||||
{
|
||||
material quad_noDepthWrite
|
||||
input 0 previousscene
|
||||
}
|
||||
pass render_scene
|
||||
{
|
||||
first_render_queue 51
|
||||
last_render_queue 105
|
||||
}
|
||||
}
|
||||
target_output
|
||||
{
|
||||
input none
|
||||
pass clear
|
||||
{
|
||||
}
|
||||
pass render_quad
|
||||
{
|
||||
material quad_noDepthWrite
|
||||
input 0 no_mrt_output
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
@ -1,23 +0,0 @@
|
||||
#include "core.h"
|
||||
|
||||
#ifdef SH_VERTEX_SHADER
|
||||
|
||||
SH_BEGIN_PROGRAM
|
||||
shUniform(float4x4, wvp) @shAutoConstant(wvp, worldviewproj_matrix)
|
||||
SH_START_PROGRAM
|
||||
{
|
||||
shOutputPosition = shMatrixMult(wvp, shInputPosition);
|
||||
}
|
||||
|
||||
#else
|
||||
|
||||
SH_BEGIN_PROGRAM
|
||||
shUniform(float3, viewportBackground) @shSharedParameter(viewportBackground)
|
||||
shDeclareMrtOutput(1)
|
||||
SH_START_PROGRAM
|
||||
{
|
||||
shOutputColour(0) = float4(viewportBackground, 1);
|
||||
shOutputColour(1) = float4(1,1,1,1);
|
||||
}
|
||||
|
||||
#endif
|
Loading…
Reference in New Issue