Fred's ImageMagick Scripts



    Licensing:

    Copyright © Fred Weinhaus

    My scripts are available free of charge for non-commercial use, ONLY.

    For use of my scripts in commercial (for-profit) environments or non-free applications, please contact me (Fred Weinhaus) for licensing arrangements. My email address is fmw at alink dot net.

    If you: 1) redistribute, 2) incorporate any of these scripts into other free applications or 3) reprogram them in another scripting language, then you must contact me for permission, especially if the result might be used in a commercial or for-profit environment.

    Usage, whether stated or not in the script, is restricted to the above licensing arrangements. It is also subject, in a subordinate manner, to the ImageMagick license, which can be found at: http://www.imagemagick.org/script/license.php

OMNISTRETCH


Enhances the dynamic range of brightness values and optionally saturation values in an image

Download Script

last modified: September 26, 2017



USAGE: omnistretch [option1] [option2] [option3] [option4] infile outfile

Option1 (choice of one only):
-h or -help ................ get help
-st ........................ get image statistics; requires input_file
-m or -model ............... processing (color) model (HSL, HSB, RGB);
............................ requires infile and outfile; default HSL if none specified

Option2 (choice of one only):
-b ... low,[high[,gamma]] .. process w/ brightness 0-100 for low,high; gamma 0-10
-c ... low,[high[,gamma]] .. process w/ histogram counts >=0 for low,high; gamma 0-10
-pc .. low,[high[,gamma]] .. process w/ % of max histogram counts 0-100 for low,high; gamma 0-10
-cc .. low,[high[,gamma]] .. process w/ cumulative histogram counts >=0 for low,high; gamma 0-10
-cd .. low,[high[,gamma]] .. process w/ cumulative histogram count differences >=0 for low,high; gamma 0-10
-ab .. gamma_method ........ auto process w/ default brightness values of min,max,gamma
-ac .. gamma_method ........ auto process w/ default histogram counts of 30,30,gamma
-apc . gamma_method ........ auto process w/ default % of max histogram counts of 10,10,gamma
-acc . gamma_method ........ auto process w/ default % cumulative histogram counts of .6,.6,gamma
-acd . gamma_method ........ auto process w/ default % cumulative histogram count differences of .06,.06,gamma

Option2:
-s ... sgamma .............. process w/ saturation; sgamma 0-10

Option3:
-g ......................... display graph of intensity mapping function,
............................ but must be used in conjunction with option 1 or 2,
............................ but not -h or -help or -st

PURPOSE: To enhance the dynamic range of brightness values and optionally saturation values in an image.

DESCRIPTION: OMNISTRETCH is designed to enhance the dynamic range of brightness values and optionally saturation values in an image. It has various means of linearly doing this as described below. If a gamma value is also supplied, then a non-linear change is affected on top of the linear change. It works by computing a grayscale histogram, which is then used to compute a low and high value to map to black and white, respectively in the image as a whole or on either the Lightness or Brightness channels, depending upon which colorspace model is selected. The script uses the IM -level function to do the processing. If a saturation change is desired, then the IM -gamma function will be applied to the saturation channel. No saturation processing is allowed if the image is grayscale. The graph is normally just viewed, but a default parameter in the program can be set to allow it to be saved as outfilename_graph.gif. To end the script, close/quit the graph image.

Argument: ........ displays help information.

Argument: -h ..... displays help information.

Argument: -g ..... displays graph of intensity mapping function.

Argument: -st .... displays image statistics, including: minimum, maximum, mean, standard deviation and histogram in a range of brightness values scaled to 0-100. An input_file is required with no output_file specified.

Argument: -m --- defines the processing color model to use for the processing of a color image. If HSL or HSB are specified, then the the image is first transformed into that color space and the corresponding channels are separated. Either the L or B channels will then be used to compute a histogram, which is then used to determine the low and high values to map to black and white, within that channel. The channels are then put back together and output in RGB format. If RGB is selected, the image is first converted to RGB format and used to generate a grayscale image. The grayscale image is then used to compute a histogram. The histogram is then used to determine the low and high values which are then stretched in the RGB image to black and white, respectively. The default for a color image is HSL. If a grayscale image is the input file, then the processing color model is ignored. Note that results for HSB tend to be undersaturated and for RGB tend to be oversaturated.

Argument: -b ..... defines the method using brightness values for low and high in the range of 0-100 to be linearly stretch to full black (0) and full white (100). If high is not provided, high=100-low. A value of 0,[100,[1]] leaves the image unchanged. Optionally, a gamma value may be included in the range of 0 upward; but, nominally 0-10, where 1 is no change, <1 is less contrast and >1 is more contrast. Gamma is a non-linear adjustment.

Argument: -c ..... defines the method using histogram counts for low and high. The method finds the first occurrences of the specified count (or higher) from each end of the histogram to locate the corresponding low and high brightness values to linearly stretch to full black (0) and full white (100). If only one count is specified, it will be used for both low and high. A value of 0,[0,[1]] leaves the image unchanged. Optionally, a gamma value may be included in the range of >=0; but, nominally 0-10, where 1 (default) is no change, <1 is less contrast and >1 is more contrast. Gamma is a non-linear adjustment.

Argument: -pc .... defines the method using percent of maximum histogram counts for low and high. The method finds the first occurrences of the specified percent of maximum histogram count (or higher) from each end of the histogram to locate the corresponding low and high brightness values to linearly stretch to full black (0) and full white (100). If only one count is specified, it will be used for both low and high. Counts for low and high are expressed as percent of the maximum count in the histogram, but the % symbol is not specified. A value of 0,[0,[1]] leaves the image unchanged. Optionally, a gamma value may be included in the range of >=0; but, nominally 0-10, where 1 (default) is no change, <1 is less contrast and >1 is more contrast. Gamma is a non-linear adjustment.

Argument: -cc .... defines the method using cumulative histogram counts in percent of total count for low and high. The method finds the first occurrences of the specified cumulative count (or higher) from each end of the histogram to locate the corresponding low and high brightness values to linearly stretch to full black (0) and full white (100). If only one cumulative count is specified, it will be used for both low and high. A value of 0,[0,[1]] indicates no change in the image. Cumulative counts for low and high are expressed as percent of total pixels in the image, but the % symbol is not specified. Optionally, a gamma value may be included in the range of >=0; but, nominally 0-10, where 1 (default) is no change, <1 is less saturation and >1 is more saturation. Gamma is a non-linear adjustment.

Argument: -cd .... defines the method using cumulative percent histogram count differences between successive histogram values equal to or exceeding low and high. The method finds the first occurrences of the specified cumulative count differences (or higher) from each end of the histogram to locate the corresponding low and high brightness values to linearly stretch to full black (0) and full white (100). If only one cumulative count difference is specified, it will be used for both low and high. A value of 0,[0,[1]] indicates no change in the image. Cumulative count differences for low and high are expressed as percent of total pixels in the image, but the % symbol is not specified. This method is basically looking for where the slope of the histogram, starting from each end, increases above a threshold given by low and high. Optionally, a gamma value may be included in the range of >=0; but, nominally 0-10, where 1 (default) is no change, <1 is less saturation and >1 is more saturation. Gamma is a non-linear adjustment.

Argument: -ab .... automatic version of -b using the image's actual minimum and maximum values for low and high. gamma_method=1 sets gamma=1. gamma_method=2 determines gamma from the computed low and high. gamma_method=3 determines gamma from the image's standard deviation.

Argument: -ac .... automatic version of -c using low and high counts of 30. gamma_method=1 sets gamma=1. gamma_method=2 determines gamma from computed low and high. gamma_method=3 determines gamma from the image's standard deviation.

Argument: -apc ... automatic version of -pc using low and high percent of maximum counts of 10. gamma_method=1 sets gamma=1. gamma_method=2 determines gamma from computed low and high. gamma_method=3 determines gamma from the image's standard deviation.

Argument: -acc ... automatic version of -cc using low and high cumulative counts of 0.6. gamma_method=1 sets gamma=1. gamma_method=2 determines gamma from computed low and high. gamma_method=3 determines gamma from the image's standard deviation

Argument: -acd ... automatic version of -cd using low and high cumulative count differences of 0.06. gamma_method=1 sets gamma=1. gamma_method=2 determines gamma from computed low and high. gamma_method=3 determines gamma from the image's standard deviation

OBSERVATION: All these algorithms tend to work better on image's which have long, low histogram tails or do not span the full range of 0-100. Typically, this means low contrast images.

REMARK: Feel free to change the default values below for the automatic methods: -ac, -apc and -acc, if you find that those values work better for your class of imagery. Also the methods for automatically determining gamma are not well tested. Method 2 is limited to histograms for which low > 0 and/or high < 100. Method 3 seems to work for both low and high contrast images.

CAVEAT: No guarantee that this script will work on all platforms, nor that trapping of inconsistent parameters is complete and foolproof. Use At Your Own Risk.


EXAMPLES


Autolevels


Original Image

artificially brightened and contrast lowered
convert lena.jpg -fx ".724u+.310" lenap.jpg



histogram min and max graylevels are automatically stretched to
0 and 100 (0 and 255)

Histogram Grayscale Value Mapped To Black = 50.5 (128 in range 0 - 255)
Histogram Grayscale Value Mapped To White = 100.0 (255 in range 0 - 255)
Break Points = 0,0 50.5,0 100.0,100.0 100.0,100.0

arguments:
-m HSB -ab 1 -g

arguments:
-m HSB -ab 1 -s 1.5

same but with saturation
increased by 50%;
graph will be the same and
does not show such changes


The example above on the right does the following:

  • Separates the RGB image into HSB channels.
  • Applies the linear stretch to the Brightness channel from graylevel 50.5 to black and 100 to white
  • Applies a gamma of 1.5 to the Saturation channel.
  • Merges the Hue, Saturation and Brightness channels back together as an RGB image.

This is equivalent to the following IM commands:

  • convert lenap.jpg -colorspace HSB -channel R -separate tmp0.jpg
  • convert lenap.jpg -colorspace HSB -channel G -separate tmp1.jpg
  • convert lenap.jpg -colorspace HSB -channel B -separate tmp2.jpg
  • convert tmp2.jpg -level 50.5%,100.0%,1 tmp2p.jpg
  • convert tmp1.jpg -gamma 1.5 tmp1p.jpg
  • convert tmp0.jpg -colorspace HSB tmp0.jpg -compose CopyRed -composite \
    tmp1p.jpg -compose CopyGreen -composite tmp2p.jpg -compose CopyBlue -composite \
    -colorspace RGB lenap-hsbmethod-ab1_s1p5.jpg



Autolevels: -ab and Processing Model: HSL
first occurrence of graylevel from either end corresponding to
cumulative histogram count=0.6% are automatically stretched to
0 and 100 (0 and 255)

Histogram Grayscale Value Mapped To Black = 41.7 (106 in range 0 - 255)
Histogram Grayscale Value Mapped To White = 96.2 (245 in range 0 - 255)
Break Points = 0,0 41.7,0 96.2,100.0 100.0,100.0

source image

arguments:
-m HSL -ab 1 -g

arguments:
-m HSL -ab 2 -g

arguments:
-m HSL -ab 3 -g

original image

   


Autolevels: -ab and Processing Model: HSB
first occurrence of graylevel from either end corresponding to
cumulative histogram count=0.6% are automatically stretched to
0 and 100 (0 and 255)

Histogram Grayscale Value Mapped To Black = 50.5 (128 in range 0 - 255)
Histogram Grayscale Value Mapped To White = 100.0 (255 in range 0 - 255)
Break Points = 0,0 50.5,0 100.0,100.0 100.0,100.0

source image

arguments:
-m HSB -ab 1 -g

arguments:
-m HSB -ab 2 -g

arguments:
-m HSB -ab 3 -g

original image

   


Autolevels: -ab and Processing Model: RGB
first occurrence of graylevel from either end corresponding to
cumulative histogram count=0.6% are automatically stretched to
0 and 100 (0 and 255)

Histogram Grayscale Value Mapped To Black = 37.2 (94 in range 0 - 255)
Histogram Grayscale Value Mapped To White = 92.5 (235 in range 0 - 255)
Break Points = 0,0 37.2,0 92.5,100.0 100.0,100.0

source image

arguments:
-m RGB -ab 1 -g

arguments:
-m RGB -ab 2 -g

arguments:
-m RGB -ab 3 -g

original image

   


Autolevels: -acc and Processing Model: HSL
first occurrence of graylevel from either end corresponding to
cumulative histogram count=0.6% are automatically stretched to
0 and 100 (0 and 255)

Histogram Grayscale Value Mapped To Black = 44.7 (113 in range 0 - 255)
Histogram Grayscale Value Mapped To White = 92.5 (235 in range 0 - 255)
Break Points = 0,0 44.7,0 92.5,100.0 100.0,100.0

source image

arguments:
-m HSL -acc 1 -g

arguments:
-m HSL -acc 2 -g

arguments:
-m HSL -acc 3 -g

original image

   


Autolevels: -acc and Processing Model: HSB
first occurrence of graylevel from either end corresponding to
cumulative histogram count=0.6% are automatically stretched to
0 and 100 (0 and 255)

Histogram Grayscale Value Mapped To Black = 53.7 (136 in range 0 - 255)
Histogram Grayscale Value Mapped To White = 100.0 (255 in range 0 - 255)
Break Points = 0,0 53.7,0 100.0,100.0 100.0,100.0

source image

arguments:
-m HSB -acc 1 -g

arguments:
-m HSB -acc 2 -g

arguments:
-m HSB -acc 3 -g

original image

   


Autolevels: -acc and Processing Model: RGB
first occurrence of graylevel from either end corresponding to
cumulative histogram count=0.6% are automatically stretched to
0 and 100 (0 and 255)

Histogram Grayscale Value Mapped To Black = 43.9 (111 in range 0 - 255)
Histogram Grayscale Value Mapped To White = 86.2 (219 in range 0 - 255)
Break Points = 0,0 43.9,0 86.2,100.0 100.0,100.0

source image

arguments:
-m RGB -acc 1 -g

arguments:
-m RGB -acc 2 -g

arguments:
-m RGB -acc 3 -g

original image

   


The example above for arguments:
-m HSB -acc 3 does the following:

  • Separates the RGB image into HSB channels.
  • Applies the linear stretch to the Brightness channel from graylevel 53.7 to black and 100 to white.
  • and also applies a gamma of 1.52 to the Brightness channel.
  • Merges the Hue, Saturation and Brightness channels back together as an RGB image.

This is equivalent to the following IM commands:

  • convert lenap.jpg -colorspace HSB -channel R -separate tmp0.jpg
  • convert lenap.jpg -colorspace HSB -channel G -separate tmp1.jpg
  • convert lenap.jpg -colorspace HSB -channel B -separate tmp2.jpg
  • convert tmp2.jpg -level 53.7%,100.0%,1.52 tmp2p.jpg
  • convert tmp0.jpg -colorspace HSB tmp0.jpg -compose CopyRed -composite \
    tmp1.jpg -compose CopyGreen -composite tmp2p.jpg -compose CopyBlue -composite \
    -colorspace RGB lenap-hsbmethod-acc3.jpg

Autolevels From Other Imaging Tools


Photoshop

GraphicConverter

GIMP



Option -st: Image Statistics (for artificially modified image and processing model HSB)

These are provided to assist in the manual selection of low and high values to map to black and white, respectively.


Image Statistics:

Colorspace = RGB

Width = 128
Height = 128
Total Pixels = 16384

Min (0-100) = 50.5
Max (0-100) = 100.0
Mean (0-100) = 82.2
Std (0-...) = 13.5


Histogram:

Total Values=127
Mid Point=63
Max Count = 511
Tot Count = 16384


B=brightness 0-100(0-255)
C=count
PC=percent of maximum count
CC=cumulative count percent
CD=cumulative count percent difference

1B=50.5(128)C=3PC=.5CC=.01CD=.01
2B=50.9(129)C=1PC=.1CC=.02CD=0
3B=51.3(130)C=7PC=1.3CC=.06CD=.04
4B=51.7(131)C=10PC=1.9CC=.12CD=.06
5B=52.1(132)C=12PC=2.3CC=.20CD=.07
6B=52.5(133)C=17PC=3.3CC=.30CD=.10
7B=52.9(134)C=15PC=2.9CC=.39CD=.09
8B=53.3(135)C=17PC=3.3CC=.50CD=.10
9B=53.7(136)C=27PC=5.2CC=.66CD=.16
10B=54.1(137)C=35PC=6.8CC=.87CD=.21
11B=54.5(138)C=42PC=8.2CC=1.13CD=.25
12B=54.9(139)C=63PC=12.3CC=1.51CD=.38
13B=55.2(140)C=67PC=13.1CC=1.92CD=.40
14B=55.6(141)C=87PC=17.0CC=2.45CD=.53
15B=56.0(142)C=108PC=21.1CC=3.11CD=.65
16B=56.4(143)C=115PC=22.5CC=3.82CD=.70
17B=56.8(144)C=132PC=25.8CC=4.62CD=.80
18B=57.2(145)C=148PC=28.9CC=5.52CD=.90
19B=57.6(146)C=138PC=27.0CC=6.37CD=.84
20B=58.0(147)C=168PC=32.8CC=7.39CD=1.02
21B=58.4(148)C=168PC=32.8CC=8.42CD=1.02
22B=58.8(149)C=169PC=33.0CC=9.45CD=1.03
23B=59.2(150)C=132PC=25.8CC=10.26CD=.80
24B=59.6(151)C=150PC=29.3CC=11.17CD=.91
25B=60.0(153)C=115PC=22.5CC=11.87CD=.70
26B=60.3(153)C=117PC=22.8CC=12.59CD=.71
27B=60.7(154)C=107PC=20.9CC=13.24CD=.65
28B=61.1(155)C=98PC=19.1CC=13.84CD=.59
29B=61.5(156)C=86PC=16.8CC=14.36CD=.52
30B=61.9(157)C=85PC=16.6CC=14.88CD=.51
31B=62.3(158)C=98PC=19.1CC=15.48CD=.59
32B=62.7(159)C=69PC=13.5CC=15.90CD=.42
33B=63.1(160)C=90PC=17.6CC=16.45CD=.54
34B=63.5(161)C=65PC=12.7CC=16.85CD=.39
35B=63.9(162)C=64PC=12.5CC=17.24CD=.39
36B=64.3(163)C=61PC=11.9CC=17.61CD=.37
37B=64.7(164)C=57PC=11.1CC=17.96CD=.34
38B=65.0(165)C=58PC=11.3CC=18.31CD=.35
39B=65.4(166)C=63PC=12.3CC=18.70CD=.38
40B=65.8(167)C=58PC=11.3CC=19.05CD=.35
41B=66.2(168)C=58PC=11.3CC=19.40CD=.35
42B=66.6(169)C=44PC=8.6CC=19.67CD=.26
43B=67.0(170)C=57PC=11.1CC=20.02CD=.34
44B=67.4(171)C=72PC=14.0CC=20.46CD=.43
45B=67.8(172)C=53PC=10.3CC=20.78CD=.32
46B=68.2(173)C=67PC=13.1CC=21.19CD=.40
47B=68.6(174)C=71PC=13.8CC=21.63CD=.43
48B=69.0(175)C=64PC=12.5CC=22.02CD=.39
49B=69.4(176)C=58PC=11.3CC=22.37CD=.35
50B=69.8(177)C=62PC=12.1CC=22.75CD=.37
51B=70.1(178)C=47PC=9.1CC=23.04CD=.28
52B=70.5(179)C=52PC=10.1CC=23.35CD=.31
53B=70.9(180)C=58PC=11.3CC=23.71CD=.35
54B=71.3(181)C=67PC=13.1CC=24.12CD=.40
55B=71.7(182)C=59PC=11.5CC=24.48CD=.36
56B=72.1(183)C=69PC=13.5CC=24.90CD=.42
57B=72.5(184)C=74PC=14.4CC=25.35CD=.45
58B=72.9(185)C=81PC=15.8CC=25.84CD=.49
59B=73.3(186)C=50PC=9.7CC=26.15CD=.30
60B=73.7(187)C=63PC=12.3CC=26.53CD=.38
61B=74.1(188)C=53PC=10.3CC=26.86CD=.32
62B=74.5(189)C=65PC=12.7CC=27.25CD=.39
63B=74.9(190)C=69PC=13.5CC=27.67CD=.42
64B=75.2(191)C=83PC=16.2CC=72.32CD=.50
65B=75.6(192)C=108PC=21.1CC=71.81CD=.65
66B=76.0(193)C=82PC=16.0CC=71.15CD=.50
67B=76.4(194)C=82PC=16.0CC=70.65CD=.50
68B=76.8(195)C=88PC=17.2CC=70.15CD=.53
69B=77.2(196)C=81PC=15.8CC=69.61CD=.49
70B=77.6(197)C=82PC=16.0CC=69.12CD=.50
71B=78.0(198)C=90PC=17.6CC=68.62CD=.54
72B=78.4(199)C=90PC=17.6CC=68.07CD=.54
73B=78.8(200)C=100PC=19.5CC=67.52CD=.61
74B=79.2(201)C=103PC=20.1CC=66.91CD=.62
75B=79.6(202)C=125PC=24.4CC=66.28CD=.76
76B=80.0(204)C=125PC=24.4CC=65.52CD=.76
77B=80.3(204)C=154PC=30.1CC=64.75CD=.93
78B=80.7(205)C=166PC=32.4CC=63.81CD=1.01
79B=81.1(206)C=187PC=36.5CC=62.80CD=1.14
80B=81.5(207)C=155PC=30.3CC=61.66CD=.94
81B=81.9(208)C=152PC=29.7CC=60.71CD=.92
82B=82.3(209)C=133PC=26.0CC=59.79CD=.81
83B=82.7(210)C=114PC=22.3CC=58.97CD=.69
84B=83.1(211)C=112PC=21.9CC=58.28CD=.68
85B=83.5(212)C=125PC=24.4CC=57.59CD=.76
86B=83.9(213)C=124PC=24.2CC=56.83CD=.75
87B=84.3(214)C=157PC=30.7CC=56.07CD=.95
88B=84.7(215)C=169PC=33.0CC=55.12CD=1.03
89B=85.0(216)C=164PC=32.0CC=54.08CD=1.00
90B=85.4(217)C=163PC=31.8CC=53.08CD=.99
91B=85.8(218)C=180PC=35.2CC=52.09CD=1.09
92B=86.2(219)C=187PC=36.5CC=50.99CD=1.14
93B=86.6(220)C=203PC=39.7CC=49.85CD=1.23
94B=87.0(221)C=172PC=33.6CC=48.61CD=1.04
95B=87.4(222)C=177PC=34.6CC=47.56CD=1.08
96B=87.8(223)C=192PC=37.5CC=46.48CD=1.17
97B=88.2(224)C=221PC=43.2CC=45.31CD=1.34
98B=88.6(225)C=252PC=49.3CC=43.96CD=1.53
99B=89.0(226)C=271PC=53.0CC=42.42CD=1.65
100B=89.4(227)C=285PC=55.7CC=40.77CD=1.73
101B=89.8(228)C=285PC=55.7CC=39.03CD=1.73
102B=90.1(229)C=276PC=54.0CC=37.29CD=1.68
103B=90.5(230)C=240PC=46.9CC=35.60CD=1.46
104B=90.9(231)C=239PC=46.7CC=34.14CD=1.45
105B=91.3(232)C=266PC=52.0CC=32.68CD=1.62
106B=91.7(233)C=227PC=44.4CC=31.06CD=1.38
107B=92.1(234)C=197PC=38.5CC=29.67CD=1.20
108B=92.5(235)C=196PC=38.3CC=28.47CD=1.19
109B=92.9(236)C=237PC=46.3CC=27.27CD=1.44
110B=93.3(237)C=254PC=49.7CC=25.83CD=1.55
111B=93.7(238)C=313PC=61.2CC=24.27CD=1.91
112B=94.1(239)C=336PC=65.7CC=22.36CD=2.05
113B=94.5(240)C=317PC=62.0CC=20.31CD=1.93
114B=94.9(241)C=306PC=59.8CC=18.38CD=1.86
115B=95.2(242)C=260PC=50.8CC=16.51CD=1.58
116B=95.6(243)C=230PC=45.0CC=14.92CD=1.40
117B=96.0(244)C=173PC=33.8CC=13.52CD=1.05
118B=96.4(245)C=164PC=32.0CC=12.46CD=1.00
119B=96.8(246)C=146PC=28.5CC=11.46CD=.89
120B=97.2(247)C=170PC=33.2CC=10.57CD=1.03
121B=97.6(248)C=181PC=35.4CC=9.53CD=1.10
122B=98.0(249)C=194PC=37.9CC=8.43CD=1.18
123B=98.4(250)C=186PC=36.3CC=7.25CD=1.13
124B=98.8(251)C=189PC=36.9CC=6.11CD=1.15
125B=99.2(252)C=168PC=32.8CC=4.96CD=1.02
126B=99.6(253)C=134PC=26.2CC=3.93CD=.81
127B=100.0(255)C=511PC=100.0CC=3.11CD=3.11