3D Shader Anaglyph pentru Under Over for DvbViewer 4.5 Pro
Creati un fisier text pe care iil redenumiti anaglyph_under_over.xml si dati copy-paste la codul de mai jos. Salvati fisierul si copiati-l in folderul de instalare al Dvb Viewer , in subfolderul Shaders, apoi porniti Dvb Viewer 4.5 pro si activati acest shader. Functioneaza pentru filme under over image 3d ( mkv , 3d tv si altele)convertind in anaglyph in real time.
Pentru ochelari Red Cyan standard :
<?xml version="1.0" encoding="iso-8859-1"?>Pentru ochelari Red Cyan colorfull:
<Shader>
<Profile>ps_2_0</Profile>
<Description>anaglyph</Description>
<Code>sampler s0 : register(s0);
float4 p0 : register(c0);
#define width (p0[0])
#define height (p0[1])
float4 main(float2 tex : TEXCOORD0) : COLOR
{
tex.y = tex.y / 2;
float4 l = tex2D(s0, tex);
tex.y = tex.y + 0.5;
float4 r = tex2D(s0, tex);
float red = l.g * 0.7 + l.b * 0.3;
float green = r.g;
float blue = r.b;
return float4(red, green, blue, 1);
}</Code>
</Shader>
<?xml version="1.0" encoding="iso-8859-1"?>Pentru ochelari magenta :
<Shader>
<Profile>ps_2_0</Profile>
<Description>anaglyph</Description>
<Code>sampler s0 : register(s0);
float4 p0 : register(c0);
#define width (p0[0])
#define height (p0[1])
float4 main(float2 tex : TEXCOORD0) : COLOR
{
tex.y = tex.y / 2;
float4 l = tex2D(s0, tex);
tex.y = tex.y + 0.5;
float4 r = tex2D(s0, tex);
float red =r.r*0.3+r.g*0.4+r.b*0.1;
float green =l.g*0.7;
float blue = l.b*0.7;
return float4(red, green, blue, 1);
}</Code>
</Shader>
<?xml version="1.0" encoding="iso-8859-1"?>
<Shader>
<Profile>ps_2_0</Profile>
<Description>anaglyph</Description>
<Code>sampler s0 : register(s0);
float4 p0 : register(c0);
#define width (p0[0])
#define height (p0[1])
float4 main(float2 tex : TEXCOORD0) : COLOR
{
tex.y = tex.y / 2;
float4 l = tex2D(s0, tex);
tex.y = tex.y + 0.5;
float4 r = tex2D(s0, tex);
float red = r.g;
float green = l.g * 0.7 + l.b * 0.3;
float blue = r.b;
return float4(red, green, blue, 1);
}</Code>
</Shader>
Trimiteți un comentariu
☑ Comentariile conforme cu regulile comunității vor fi aprobate în maxim 10 ore.