Пример #1
0
 public WinForm(IPictureIO pictureIO, IFilter pictureManipulation, IEdge edge)
 {
     //Instenciate interfaces
     this.pictureIO           = pictureIO;
     this.pictureManipulation = pictureManipulation;
     this.edge = edge;
 }
Пример #2
0
        private void btnLoad_Click(object sender, EventArgs e)
        {
            //Call classes needed
            this.pictureIO = new PictureIO();
            this.edge      = new Edge();

            originalBitmap = pictureIO.openPicture();

            previewBitmap = originalBitmap;

            //Size in the picture box
            previewBitmap = edge.CopyToSquareCanvas(previewBitmap, pictureBox1.Width);

            //Put the picture in the picture box
            pictureBox1.Image = previewBitmap;


            ApplyFilter();
        }
Пример #3
0
 private void btnSave_Click(object sender, EventArgs e)
 {
     this.pictureIO = new PictureIO();
     pictureIO.savePicture(resultBitmap);
 }