Esempio n. 1
0
        public Image <Gray, byte> IsolateColorBlackByAverage(double threshold = 80)
        {
            var mask = ChannelR.ThresholdBinaryInv(new Gray(threshold), new Gray(255)).And(ChannelG.ThresholdBinaryInv(new Gray(threshold), new Gray(255))).And(ChannelB.ThresholdBinaryInv(new Gray(threshold), new Gray(255)));

            return(mask);
        }
Esempio n. 2
0
 /// <summary>
 /// Generates new image that contains wider range of red colors.
 /// </summary>
 /// <returns>New processed image.</returns>
 public Image <Gray, byte> IsolateColorRedByOtherColorsExclusion1()
 {
     return((ChannelR - ChannelB.ThresholdBinary(new Gray(50), new Gray(255)) - ChannelG.ThresholdBinary(new Gray(50), new Gray(255))) - IsolateColorYellowByOtherColorsExclusion1());
 }