diff --git a/src/ImageProcessor.Playground/Program.cs b/src/ImageProcessor.Playground/Program.cs index 95f086331f..a8d0d07aea 100644 --- a/src/ImageProcessor.Playground/Program.cs +++ b/src/ImageProcessor.Playground/Program.cs @@ -52,8 +52,8 @@ namespace ImageProcessor.PlayGround // Image mask = Image.FromFile(Path.Combine(resolvedPath, "mask2.png")); Image overlay = Image.FromFile(Path.Combine(resolvedPath, "monster.png")); - //FileInfo fileInfo = new FileInfo(Path.Combine(resolvedPath, "cow_PNG2140.png")); - IEnumerable files = GetFilesByExtensions(di, ".jpg"); + //FileInfo fileInfo = new FileInfo(Path.Combine(resolvedPath, "monster.png")); + IEnumerable files = GetFilesByExtensions(di, ".png"); //IEnumerable files = GetFilesByExtensions(di, ".gif", ".webp", ".bmp", ".jpg", ".png", ".tif"); foreach (FileInfo fileInfo in files) @@ -69,7 +69,7 @@ namespace ImageProcessor.PlayGround { using (ImageFactory imageFactory = new ImageFactory(true)) { - Size size = new Size(200, 200); + Size size = new Size(844, 1017); ResizeLayer layer = new ResizeLayer(size, ResizeMode.Max, AnchorPosition.Center, false); //ContentAwareResizeLayer layer = new ContentAwareResizeLayer(size) @@ -78,13 +78,13 @@ namespace ImageProcessor.PlayGround //}; // Load, resize, set the format and quality and save an image. imageFactory.Load(inStream) - //.Overlay(new ImageLayer - // { - // Image = overlay, - // Size = size, - // Opacity = 80 - // }) - .Alpha(50) + .Overlay(new ImageLayer + { + Image = overlay, + Size = size, + Opacity = 80 + }) + //.Alpha(50) //.BackgroundColor(Color.White) //.Resize(new Size((int)(size.Width * 1.1), 0)) //.ContentAwareResize(layer) @@ -107,7 +107,7 @@ namespace ImageProcessor.PlayGround //.Filter(MatrixFilters.HiSatch) //.Pixelate(8) //.GaussianSharpen(10) - //.Format(new PngFormat() { IsIndexed = true }) + .Format(new PngFormat() { IsIndexed = true }) .Save(Path.GetFullPath(Path.Combine(Path.GetDirectoryName(path), @"..\..\images\output", fileInfo.Name))); stopwatch.Stop(); diff --git a/src/TestWebsites/MVC/Web.config b/src/TestWebsites/MVC/Web.config index 5aae58e7ed..9bef44eafd 100644 --- a/src/TestWebsites/MVC/Web.config +++ b/src/TestWebsites/MVC/Web.config @@ -5,7 +5,7 @@ --> - + diff --git a/src/TestWebsites/MVC/config/imageprocessor/processing.config b/src/TestWebsites/MVC/config/imageprocessor/processing.config index a2f9314629..6333254597 100644 --- a/src/TestWebsites/MVC/config/imageprocessor/processing.config +++ b/src/TestWebsites/MVC/config/imageprocessor/processing.config @@ -27,7 +27,21 @@ + + + + + + + + + + + + + + @@ -41,4 +55,4 @@ - + \ No newline at end of file