Browse Source

Update master

Former-commit-id: 8397922a44e83c2b9f66b698c06f47b6d6b3acc4
af/merge-core
James South 14 years ago
parent
commit
452c2c0f23
  1. 13
      README.md

13
README.md

@ -23,13 +23,10 @@ e.g.
// Read a file and resize it. // Read a file and resize it.
var photoBytes = File.ReadAllBytes(file); var photoBytes = File.ReadAllBytes(file);
var before = DateTime.Now; int quality = 90;
var quality = 90; ImageFormat format = ImageFormat.Jpeg;
var format = ImageFormat.Jpeg; int thumbnailSize = 150;
var thumbnailSize = 150;
byte[] resized;
using (var inStream = new MemoryStream(photoBytes)) using (var inStream = new MemoryStream(photoBytes))
{ {
using (var outStream = new MemoryStream()) using (var outStream = new MemoryStream())
@ -39,8 +36,6 @@ e.g.
// Load, resize and save an image. // Load, resize and save an image.
imageFactory.Load(inStream).Format(format).Quality(quality).Resize(thumbnailSize, 0).Save(outStream); imageFactory.Load(inStream).Format(format).Quality(quality).Resize(thumbnailSize, 0).Save(outStream);
} }
resized = outStream.ToArray();
} }
} }

Loading…
Cancel
Save