private async void SaveImage()
        {
            IPainterExport export = DependencyService.Get <IPainterExport>();
            //var background = DependencyService.Get<ISaveAndLoad>().GetFileBinary(DependencyService.Get<ISaveAndLoad>().GetPathForFile("background.jpg"), false);

            float scale = painterView.GetDrawingScale();

            Debug.WriteLine(scale);

            var data = await export.GetCurrentImageAsPNG((int)painterView.Width, (int)painterView.Height, 1.0f, painterView.GetStrokes(), Painter.Abstractions.Scaling.Relative_Fit, 80, new Painter.Abstractions.Color(1, 1, 1, 1), true, null);

            DependencyService.Get <ISaveAndLoad>().SaveFile(data, "image.png");

            Debug.WriteLine(data.Length);
        }
Ejemplo n.º 2
0
 public PainterExport()
 {
     nativePainter = new Painter.Droid.PainterExport();
 }
Ejemplo n.º 3
0
 public PainterExport()
 {
     nativePainter = new Painter.iOS.PainterExport();
 }