• Home
  • Raw
  • Download

Lines Matching full:threshold

13 %                      MagickCore Image Threshold Methods                     %
87 #include "MagickCore/threshold.h"
123 " <threshold map=\"threshold\" alias=\"1x1\">"
124 " <description>Threshold 1x1 (non-dither)</description>"
128 " </threshold>"
129 " <threshold map=\"checks\" alias=\"2x1\">"
135 " </threshold>"
155 % AdaptiveThresholdImage() selects an individual threshold for each pixel
204 Initialize threshold image attributes. in AdaptiveThresholdImage()
222 Threshold image. in AdaptiveThresholdImage()
369 % AutoThresholdImage() automatically selects a threshold and replaces each
371 % the selected threshold otherwise white.
380 % o image: The image to auto-threshold.
406 threshold; in KapurThreshold() local
409 Compute optimal threshold from the entopy of the histogram. in KapurThreshold()
471 threshold=0; in KapurThreshold()
476 threshold=(size_t) j; in KapurThreshold()
484 return(100.0*threshold/MaxIntensity); in KapurThreshold()
496 threshold; in OTSUThreshold() local
502 Compute optimal threshold from maximization of inter-class variance. in OTSUThreshold()
540 Sigma maximization: inter-class variance and compute optimal threshold. in OTSUThreshold()
542 threshold=0; in OTSUThreshold()
553 threshold=(double) i; in OTSUThreshold()
563 return(100.0*threshold/MaxIntensity); in OTSUThreshold()
590 threshold; in TriangleThreshold() local
593 Compute optimal threshold with triangle algorithm. in TriangleThreshold()
619 Compute threshold at split point. in TriangleThreshold()
631 threshold=0; in TriangleThreshold()
640 threshold=i; in TriangleThreshold()
651 threshold=i; in TriangleThreshold()
655 return(100.0*threshold/MaxIntensity); in TriangleThreshold()
671 threshold; in AutoThresholdImage() local
726 Discover threshold from histogram. in AutoThresholdImage()
732 threshold=KapurThreshold(image,histogram,exception); in AutoThresholdImage()
738 threshold=OTSUThreshold(image,histogram,exception); in AutoThresholdImage()
743 threshold=TriangleThreshold(histogram,exception); in AutoThresholdImage()
748 if (threshold < 0.0) in AutoThresholdImage()
753 Threshold image. in AutoThresholdImage()
755 (void) FormatLocaleString(property,MagickPathExtent,"%g%%",threshold); in AutoThresholdImage()
756 (void) SetImageProperty(image,"auto-threshold:threshold",property,exception); in AutoThresholdImage()
757 return(BilevelImage(image,QuantumRange*threshold/100.0,exception)); in AutoThresholdImage()
778 % This function is what is used to implement the "-threshold" operator for
786 % MagickBooleanType BilevelImage(Image *image,const double threshold,
793 % o threshold: define the threshold values.
798 % with the 'threshold' value for both the black_point and the white_point.
801 MagickExport MagickBooleanType BilevelImage(Image *image,const double threshold, in BilevelImage() argument
804 #define ThresholdImageTag "Threshold/Image" in BilevelImage()
827 Bilevel threshold image. in BilevelImage()
869 q[i]=(Quantum) (pixel <= threshold ? 0 : QuantumRange); in BilevelImage()
906 % the threshold into black while leaving all pixels at or above the threshold
912 % const char *threshold,ExceptionInfo *exception)
918 % o threshold: define the threshold value.
926 #define ThresholdImageTag "Threshold/Image" in BlackThresholdImage()
941 threshold; in BlackThresholdImage() local
959 GetPixelInfo(image,&threshold); in BlackThresholdImage()
961 threshold.red=geometry_info.rho; in BlackThresholdImage()
962 threshold.green=geometry_info.rho; in BlackThresholdImage()
963 threshold.blue=geometry_info.rho; in BlackThresholdImage()
964 threshold.black=geometry_info.rho; in BlackThresholdImage()
965 threshold.alpha=100.0; in BlackThresholdImage()
967 threshold.green=geometry_info.sigma; in BlackThresholdImage()
969 threshold.blue=geometry_info.xi; in BlackThresholdImage()
971 threshold.alpha=geometry_info.psi; in BlackThresholdImage()
972 if (threshold.colorspace == CMYKColorspace) in BlackThresholdImage()
975 threshold.black=geometry_info.psi; in BlackThresholdImage()
977 threshold.alpha=geometry_info.chi; in BlackThresholdImage()
981 threshold.red*=(MagickRealType) (QuantumRange/100.0); in BlackThresholdImage()
982 threshold.green*=(MagickRealType) (QuantumRange/100.0); in BlackThresholdImage()
983 threshold.blue*=(MagickRealType) (QuantumRange/100.0); in BlackThresholdImage()
984 threshold.black*=(MagickRealType) (QuantumRange/100.0); in BlackThresholdImage()
985 threshold.alpha*=(MagickRealType) (QuantumRange/100.0); in BlackThresholdImage()
988 White threshold image. in BlackThresholdImage()
1030 if (pixel < GetPixelInfoChannel(&threshold,channel)) in BlackThresholdImage()
1198 % ThresholdMap *DestroyThresholdMap(Threshold *map)
1202 % o map: Pointer to the Threshold map to destroy
1229 % GetThresholdMap() loads and searches one or more threshold map files for the
1288 % GetThresholdMapFile() look for a given threshold map name or alias in the
1298 % o xml: The threshold map list in XML format.
1300 % o filename: The threshold map XML filename.
1329 *threshold, in GetThresholdMapFile() local
1333 "Loading threshold map file \"%s\" ...",filename); in GetThresholdMapFile()
1338 for (threshold=GetXMLTreeChild(thresholds,"threshold"); in GetThresholdMapFile()
1339 threshold != (XMLTreeInfo *) NULL; in GetThresholdMapFile()
1340 threshold=GetNextXMLTreeTag(threshold)) in GetThresholdMapFile()
1342 attribute=GetXMLTreeAttribute(threshold,"map"); in GetThresholdMapFile()
1345 attribute=GetXMLTreeAttribute(threshold,"alias"); in GetThresholdMapFile()
1349 if (threshold == (XMLTreeInfo *) NULL) in GetThresholdMapFile()
1354 description=GetXMLTreeChild(threshold,"description"); in GetThresholdMapFile()
1362 levels=GetXMLTreeChild(threshold,"levels"); in GetThresholdMapFile()
1374 attribute=GetXMLTreeAttribute(threshold,"map"); in GetThresholdMapFile()
1494 % ListThresholdMapFile() lists the threshold maps and their descriptions
1506 % o xml: The threshold map list in XML format.
1508 % o filename: The threshold map XML filename.
1523 *threshold, in ListThresholdMapFile() local
1529 "Loading threshold map file \"%s\" ...",filename); in ListThresholdMapFile()
1536 threshold=GetXMLTreeChild(thresholds,"threshold"); in ListThresholdMapFile()
1537 for ( ; threshold != (XMLTreeInfo *) NULL; in ListThresholdMapFile()
1538 threshold=GetNextXMLTreeTag(threshold)) in ListThresholdMapFile()
1540 map=GetXMLTreeAttribute(threshold,"map"); in ListThresholdMapFile()
1548 alias=GetXMLTreeAttribute(threshold,"alias"); in ListThresholdMapFile()
1549 description=GetXMLTreeChild(threshold,"description"); in ListThresholdMapFile()
1583 % ListThresholdMaps() lists the threshold maps and their descriptions
1584 % as defined by "threshold.xml" to a file.
1614 "\n Threshold Maps for Ordered Dither Operations\n"); in ListThresholdMaps()
1639 % of pre-defined dithering threshold maps, but over multiple intensity
1652 % o threshold_map: A string containing the name of the threshold dither
1792 threshold; in OrderedDitherImage() local
1803 threshold=(ssize_t) (QuantumScale*q[i]*(levels[n]*(map->divisor-1)+1)); in OrderedDitherImage()
1804 level=threshold/(map->divisor-1); in OrderedDitherImage()
1805 threshold-=level*(map->divisor-1); in OrderedDitherImage()
1806 q[i]=ClampToQuantum((double) (level+(threshold >= in OrderedDitherImage()
1858 % o epsilon: the epsilon threshold (e.g. 1.0e-9).
1994 % intensity of each pixel compared to a random threshold. The result is a
2015 #define ThresholdImageTag "Threshold/Image" in RandomThresholdImage()
2027 threshold; in RandomThresholdImage() local
2048 GetPixelInfo(image,&threshold); in RandomThresholdImage()
2050 Random threshold image. in RandomThresholdImage()
2088 threshold; in RandomThresholdImage() local
2095 threshold=min_threshold; in RandomThresholdImage()
2098 threshold=max_threshold; in RandomThresholdImage()
2100 threshold=(double) (QuantumRange* in RandomThresholdImage()
2102 q[i]=(double) q[i] <= threshold ? 0 : QuantumRange; in RandomThresholdImage()
2151 % o low_black: Define the minimum threshold value.
2153 % o low_white: Define the maximum threshold value.
2155 % o high_white: Define the minimum threshold value.
2157 % o low_white: Define the maximum threshold value.
2166 #define ThresholdImageTag "Threshold/Image" in RangeThresholdImage()
2189 Range threshold image. in RangeThresholdImage()
2285 % the threshold into white while leaving all pixels at or below the threshold
2291 % const char *threshold,ExceptionInfo *exception)
2297 % o threshold: Define the threshold value.
2305 #define ThresholdImageTag "Threshold/Image" in WhiteThresholdImage()
2320 threshold; in WhiteThresholdImage() local
2338 GetPixelInfo(image,&threshold); in WhiteThresholdImage()
2340 threshold.red=geometry_info.rho; in WhiteThresholdImage()
2341 threshold.green=geometry_info.rho; in WhiteThresholdImage()
2342 threshold.blue=geometry_info.rho; in WhiteThresholdImage()
2343 threshold.black=geometry_info.rho; in WhiteThresholdImage()
2344 threshold.alpha=100.0; in WhiteThresholdImage()
2346 threshold.green=geometry_info.sigma; in WhiteThresholdImage()
2348 threshold.blue=geometry_info.xi; in WhiteThresholdImage()
2350 threshold.alpha=geometry_info.psi; in WhiteThresholdImage()
2351 if (threshold.colorspace == CMYKColorspace) in WhiteThresholdImage()
2354 threshold.black=geometry_info.psi; in WhiteThresholdImage()
2356 threshold.alpha=geometry_info.chi; in WhiteThresholdImage()
2360 threshold.red*=(MagickRealType) (QuantumRange/100.0); in WhiteThresholdImage()
2361 threshold.green*=(MagickRealType) (QuantumRange/100.0); in WhiteThresholdImage()
2362 threshold.blue*=(MagickRealType) (QuantumRange/100.0); in WhiteThresholdImage()
2363 threshold.black*=(MagickRealType) (QuantumRange/100.0); in WhiteThresholdImage()
2364 threshold.alpha*=(MagickRealType) (QuantumRange/100.0); in WhiteThresholdImage()
2367 White threshold image. in WhiteThresholdImage()
2409 if (pixel > GetPixelInfoChannel(&threshold,channel)) in WhiteThresholdImage()