internal override void DrawToCameraRenderTarget(Camera camera,
ref Texture2D texture,
Color clearColor,
ref Rectangle sourceRectangle)
{
// Set the effect parameters
SetEffectParameters(camera);
#region Horizontal Blur
// Set the effect technique
mEffect.CurrentTechnique = mEffect.Techniques[mTechniqueHorizontal];
// Draw the horizontal pass
DrawToTexture(camera, ref mTexture, clearColor, ref texture, ref sourceRectangle);
#endregion
#region Vertical Blur
// Set the effect technique
mEffect.CurrentTechnique = mEffect.Techniques[mTechniqueVertical];
#if XNA4
throw new NotImplementedException();
// Unreachable code, but uncomment once the NotImplementedException is removed:
//DrawToCurrentTarget(camera, ref mTexture, clearColor, ref sourceRectangle);
#else
// Draw the vertical pass
DrawToCurrentTarget(camera, ref mTexture, clearColor, ref sourceRectangle);
camera.mRenderTargetTexture.SetOnDevice();
#endif
#endregion
}
#endregion