💥 集成everything 开发

This commit is contained in:
BookerLiu
2023-03-27 18:10:39 +08:00
parent 300fcb78da
commit d0547da214
25 changed files with 2070 additions and 30 deletions

View File

@@ -20,6 +20,7 @@ namespace GeekDesk.Util
/// <returns></returns>
public static BitmapImage ByteArrToImage(byte[] array)
{
if (array == null) return null;
using (var ms = new System.IO.MemoryStream(array))
{
BitmapImage image = new BitmapImage();
@@ -39,6 +40,7 @@ namespace GeekDesk.Util
/// <returns></returns>
public static byte[] BitmapImageToByte(BitmapImage bi)
{
if (bi == null) return null;
using (MemoryStream memStream = new MemoryStream())
{
PngBitmapEncoder encoder = new PngBitmapEncoder();