public void AddTransform(Transform transform) { lock (transformList) { // Also updates the recovery index since they reference the same list Transform.AddOrSimplify(transformList, transform); } recoveryImage.Save(); }
public ScannedImage(Bitmap img, ScanBitDepth bitDepth, bool highQuality, int quality) { var tempFilePath = ScannedImageHelper.SaveSmallestBitmap(img, bitDepth, highQuality, quality, out var fileFormat); transformList = new List <Transform>(); recoveryImage = RecoveryImage.CreateNew(fileFormat, bitDepth, highQuality, transformList); File.Move(tempFilePath, recoveryImage.FilePath); recoveryImage.Save(); }
private ScannedImage(string pdfPath, bool copy) { transformList = new List <Transform>(); recoveryImage = RecoveryImage.CreateNew(null, ScanBitDepth.C24Bit, false, transformList); if (copy) { File.Copy(pdfPath, recoveryImage.FilePath); } else { File.Move(pdfPath, recoveryImage.FilePath); } recoveryImage.Save(); }