the only way to render a bitmap is to use a RenderTargetBitmap.
Take a look at this example:
BitmapSource bitmap=GetYourBitmap(); Rectangle r=new Rectangle(); r.Background=new ImageBrush(bitmap); r.Effect=yourEffect; Size sz=new Size(bitmap.PixelWidth, bitmap.PixelHeight); r.Measure(sz); r.Arrange(new Rect(sz); var rtb=new RenderTargetBitmap(); rtb.Render(r); return rtb;
Hope this helps
source share