//生成按钮 public async void Make(string filePath) { // Detect any faces in the image. faceList = await UploadAndDetectFaces(filePath); if (faceList.Count > 0) { LaterFace = AdjustFunction.Redraw(faceList, bitmapImage); } }
//一键生成按钮 public async void AutoMake(string filePath) { // Detect any faces in the image. faceList = await UploadAndDetectFaces(filePath); if (faceList.Count > 0) { Bitmap bitmap = AdjustFunction.BitmapImageToBitmap(bitmapImage); bitmapImage = AdjustFunction.BrightnessP(bitmap, 50); bitmapImage = AdjustFunction.SetTrans(bitmap, 50); bitmapImage = AdjustFunction.KiContrast(bitmap, 100); LaterFace = AdjustFunction.Redraw(faceList, bitmapImage); } }