// Filtering of YCbCr channels private void filteringYCbCrFiltersItem_Click( object sender, System.EventArgs e ) { if ( image.PixelFormat != PixelFormat.Format24bppRgb ) { MessageBox.Show( "YCbCr filtering is available for color images only", "Message", MessageBoxButtons.OK, MessageBoxIcon.Exclamation ); return; } YCbCrFilteringForm form = new YCbCrFilteringForm( ); form.Image = image; if ( form.ShowDialog( ) == DialogResult.OK ) { ApplyFilter( form.Filter ); } }
// Filtering of YCbCr channels private void filteringYCbCrFiltersItem_Click( object sender, System.EventArgs e ) { if ( CheckIfColor( "YCbCr filtering" ) ) { YCbCrFilteringForm form = new YCbCrFilteringForm( ); form.Image = image; if ( form.ShowDialog( ) == DialogResult.OK ) { ApplyFilter( form.Filter ); } } }