コード例 #1
0
ファイル: SharpenForm.cs プロジェクト: netcharm/PhotoTools
        private void SharpenForm_Load(object sender, EventArgs e)
        {
            thumb            = AddinUtils.CreateThumb(addin.ImageData, imgPreview.Size);
            imgPreview.Image = thumb;

            if (sharpenMode == SharpenMode.Normal)
            {
                btnModeNormal.PerformClick();
            }
            else if (sharpenMode == SharpenMode.Gaussian)
            {
                btnModeGaussian.PerformClick();
            }
            else if (sharpenMode == SharpenMode.GDI)
            {
                btnModeGdi.PerformClick();
            }

            edGaussianSigma.Value     = Convert.ToDecimal(gaussianSigma);
            edGaussianSize.Value      = Convert.ToDecimal(gaussianSize);
            edGaussianThreshold.Value = Convert.ToDecimal(gaussianThreshold);

            edGdiRatio.Value  = Convert.ToDecimal(gdiRatio);
            edGdiAmount.Value = Convert.ToDecimal(gdiAmount);
        }
コード例 #2
0
        /// <summary>
        /// ////
        /// </summary>
        /// <param name="filter"></param>
        public CropForm(IAddin filter)
        {
            this.addin = filter;
            InitializeComponent();
            toolTip.ToolTipTitle = addin.DisplayName;
            AddinUtils.Translate(addin, this, toolTip);

            aspectList.Clear();
            aspectList.Add("1 x 1", new Size(1, 1));
            aspectList.Add("2 x 1", new Size(2, 1));
            aspectList.Add("3 x 1", new Size(3, 1));
            aspectList.Add("3 x 2", new Size(3, 2));
            aspectList.Add("4 x 3", new Size(4, 3));
            aspectList.Add("16 x 9", new Size(16, 9));
            aspectList.Add("16 x 10", new Size(16, 10));
            aspectList.Add("1 x 2", new Size(1, 2));
            aspectList.Add("1 x 3", new Size(1, 3));
            aspectList.Add("2 x 3", new Size(2, 3));
            aspectList.Add("3 x 4", new Size(3, 4));
            aspectList.Add("9 x 16", new Size(9, 16));
            aspectList.Add("10 x 16", new Size(10, 16));

            thumb            = AddinUtils.CreateThumb(addin.ImageData, imgPreview.Size);
            imgPreview.Image = thumb;
        }
コード例 #3
0
ファイル: HueFilterForm.cs プロジェクト: netcharm/PhotoTools
        private void HueFilterForm_Load(object sender, EventArgs e)
        {
            thumb = AddinUtils.CreateThumb(addin.ImageData, imgPreview.Size);

            edHue.Step       = 1;
            edHue.Value      = 180;
            imgPreview.Image = addin.Apply(thumb);
        }
コード例 #4
0
        private void HslFilterForm_Load(object sender, EventArgs e)
        {
            thumb            = AddinUtils.CreateThumb(addin.ImageData, imgPreview.Size);
            imgPreview.Image = thumb;

            cbGrayMode.DataSource = Enum.GetValues(typeof(GrayscaleMode));
            edSat.Color           = edHue.ToRgb(hslSat, hslLum);
            //edLum.Color = edHue.ToRgb( hslSat, hslLum );
        }
コード例 #5
0
        /// <summary>
        /// ////
        /// </summary>
        /// <param name="filter"></param>
        public RotateForm(IAddin filter)
        {
            this.addin = filter;
            InitializeComponent();
            toolTip.ToolTipTitle = addin.DisplayName;
            AddinUtils.Translate(addin, this, toolTip);

            //thumb = CreateThumb( addin.ImageData );
            thumb = AddinUtils.CreateThumb(addin.ImageData, imgPreview.Size);
        }
コード例 #6
0
ファイル: GrayscaleForm.cs プロジェクト: netcharm/PhotoTools
        public GrayscaleForm(IAddin filter)
        {
            this.addin = filter;
            InitializeComponent();

            toolTip.ToolTipTitle = addin.DisplayName;
            AddinUtils.Translate(addin, this, toolTip);

            thumb            = AddinUtils.CreateThumb(addin.ImageData, imgPreview.Size);
            imgPreview.Image = thumb;

            cbGrayMode.Tag        = false;
            cbGrayMode.DataSource = Enum.GetValues(typeof(GrayscaleMode));
            cbGrayMode.Tag        = true;
        }
コード例 #7
0
ファイル: InvertForm.cs プロジェクト: netcharm/PhotoTools
 private void InvertForm_Load(object sender, EventArgs e)
 {
     thumb            = AddinUtils.CreateThumb(addin.ImageData, imgPreview.Size);
     imgPreview.Image = addin.Apply(thumb);
 }