Ejemplo n.º 1
0
 protected void Attach(MemBitmap bmp, PixelBlender32 pixelBlender = null)
 {
     if (pixelBlender == null)
     {
         //use default pixel blender ?
         if (_defaultPixelBlender == null)
         {
             _defaultPixelBlender = new PixelBlenderBGRA();
         }
         pixelBlender = _defaultPixelBlender;
     }
     Attach(bmp.Width, bmp.Height, bmp.BitDepth, MemBitmap.GetBufferPtr(bmp), pixelBlender);
 }
Ejemplo n.º 2
0
        public static AggPainter Create(ActualBitmap bmp, PixelProcessing.PixelBlender32 blender = null)
        {
            //helper func

            AggRenderSurface renderSx = new AggRenderSurface(bmp);

            if (blender == null)
            {
                blender = new PixelProcessing.PixelBlenderBGRA();
            }
            renderSx.PixelBlender = blender;

            return(new AggPainter(renderSx));
        }