public Bitmap pixelCensorship(Image image, int[] coordinates)
        {
            Bitmap bitmap = image.BitmapImage;

            double[] coordinatesDouble = new double[coordinates.Length];
            for (int i = 0; i < coordinates.Length; i++)
            {
                coordinatesDouble[i] = Convert.ToDouble(coordinates[i]);
            }
            Scissors scissors      = new Scissors();
            Resizer  resizer       = new Resizer();
            AddImage AI            = new AddImage();
            Bitmap   cropped       = scissors.Crop(bitmap, coordinatesDouble);
            Bitmap   ResizedSmall  = resizer.ResizeImage(cropped, 10, 10);
            Bitmap   ResizedNormal = resizer.ResizeImage(ResizedSmall, cropped.Width, cropped.Height);
            Bitmap   Final         = AI.InsertImage(bitmap, ResizedNormal, coordinates[0], coordinates[1], coordinates[2], coordinates[3]);

            return(Final);
        }
Пример #2
0
        public System.Drawing.Bitmap Collage(List <Image> images, int baseWidth, int baseHeight, int insertWidth, int insertHeight, System.Drawing.Bitmap backgroundImage = null, int R = 0, int G = 0, int B = 0)
        {
            AddImage AI = new AddImage();

            return(AI.ImageCollage(images, baseWidth, baseHeight, insertWidth, insertHeight, backgroundImage, R, G, B));
        }
Пример #3
0
        public System.Drawing.Bitmap Mosaic(Image imagenBase, List <Image> Imagenes, int width, int height)
        {
            AddImage AI = new AddImage();

            return(AI.Mosaic(imagenBase, Imagenes, width, height));
        }