private static string StreamToBase64String(SKDynamicMemoryWStream mstream)
        {
            var str = mstream.DetachAsStream();
            var bts = new byte[str.Length];

            str.Read(bts, str.Length);
            return(Convert.ToBase64String(bts));
        }
        private static byte[] StreamToBase64Bytes(SKDynamicMemoryWStream mstream)
        {
            var str = mstream.DetachAsStream();
            var bts = new byte[str.Length];

            str.Read(bts, str.Length);
            return(bts);
        }