Why Gemfury? Push, build, and install  RubyGems npm packages Python packages Maven artifacts PHP packages Go Modules Debian packages RPM packages NuGet packages

Repository URL to install this package:

Details    
lightworks / usr / share / lightworks / Shaders / bars.fx
Size: Mime:
//--------------------------------------------------------------//
// Shapes
//
// Copyright (c) EditShare EMEA.  All Rights Reserved
//--------------------------------------------------------------//

int _LwksEffectInfo
<
   string EffectGroup = "GenericPixelShader";
   string Description = "Colour Bars";
   string Category    = "Mattes";
> = 0;


//--------------------------------------------------------------//
// Params
//--------------------------------------------------------------//
int SetTechnique
<
   string Description = "Standard";
   string Enum = "Seventy Five Percent,One Hundred Percent";
> = 0;

float4 _colours100[] =
{
   { 1.0,1.0,1.0,1.0 },
   { 1.0,1.0,0.0,1.0 },
   { 0.0,1.0,1.0,1.0 },
   { 0.0,1.0,0.0,1.0 },
   { 1.0,0.0,1.0,1.0 },
   { 1.0,0.0,0.0,1.0 },
   { 0.0,0.0,1.0,1.0 },
   { 0.0,0.0,0.0,1.0 }
};

float4 _colours75[] =
{
   { 0.75,0.75,0.75, 1.0 },
   { 0.75,0.75,0.0, 1.0 },
   { 0.0,0.75,0.75, 1.0 },
   { 0.0,0.75,0.0,  1.0 },
   { 0.75,0.0,0.75, 1.0 },
   { 0.75,0.0,0.0,  1.0 },
   { 0.0,0.0,0.75,  1.0 },
   { 0.0,0.0,0.0,   1.0 }
};

//--------------------------------------------------------------//
// Code
//--------------------------------------------------------------//
float4 seventyFivePercentBars( float2 xyNorm : TEXCOORD0 ) : COLOR
{
   return _colours75[ xyNorm.x / 0.125 ];
}
//--------------------------------------------------------------//
float4 oneHundredPercentBars( float2 xyNorm : TEXCOORD0 ) : COLOR
{
   return _colours100[ xyNorm.x / 0.125 ];
}

//--------------------------------------------------------------//
// Technique Section for Image Processing Effects
//--------------------------------------------------------------//
technique SeventyFivePercent { pass Single_Pass { PixelShader = compile PROFILE seventyFivePercentBars(); } }
technique OneHundredPercent  { pass Single_Pass { PixelShader = compile PROFILE oneHundredPercentBars(); } }