Green Screen Remover. Runs on your device

CHROMA KEY NOTES / 014

Color Tolerance: What the Slider Actually Changes

SHORT ANSWER

The tolerance slider sets one cut point on a colour scale: how much green a pixel may still contain and still count as background. It is not a strength dial, and it does not touch the pixels themselves. On a clean, evenly lit screen frame, dragging it from 0 to 100 changed 739 pixels out of 268,800, just 0.27% of the image. If the background is still there at 100, or your subject is already losing pixels below 60, the number is not what needs to change.

Open the green screen remover ↗

What the number is compared against

Every pixel in the frame is scored on one axis, and the slider decides where the line goes. For the green preset that score is green excess: green minus the larger of red and blue, divided by the pixel's total brightness, scaled to 0–255. A pixel made of nothing but green scores 255. A neutral grey scores 0, no matter how light or dark it is. That last property is the reason the preset survives uneven lighting without re-sampling the backdrop.

The slider feeds two short formulas. In green mode, the cut point is 255 minus a cutoff that runs from 72 down to 8, which maps tolerance 0 to a threshold of 183 and tolerance 100 to a threshold of 247. In custom-colour mode the scale is entirely different, running from 4 up to 39. The two numbers on screen look the same and mean different things, which is worth knowing before you compare notes with someone using a different tool.

Number line from zero to 255 of green excess, with three markers showing where the tolerance slider puts the cut point at 0, 24 and 100.
Fig. 1 — the slider does not strengthen anything; it slides one line along the green axis.

The sweep, measured pixel by pixel

To see what a drag is worth, the slider was stepped one point at a time from 0 to 100 and the whole keying chain was re-run at each position: candidate scan, the perimeter flood fill, the enclosed-pocket pass, then the alpha conversion on edge pixels. Softness was held at its default of 18, which fixes the feather band at 65.4 units. All numbers below come from that sweep; the raw table is in the measurements file that ships with these notes.

On the studio frame the result is almost flat. Tolerance 0 removes 208,714 pixels. The default of 24 removes 209,102. Tolerance 50 removes 209,246, and the top of the slider removes 209,453. The entire travel is worth 739 pixels. The reason is visible in the pixel histogram: 206,397 of the screen pixels score exactly 84 on the green-excess scale, and almost nothing sits between 8 and 80. The frame is bimodal. Nearly every pixel is either obviously screen or obviously subject, so there is nothing near the line for the line to move past.

ToleranceCut pointPixels removedEdge pixels made partial
0183.0208,714709
24 (default)198.6209,1021,630
50214.2209,2461,615
100247.0209,4531,621

One column moves the other way. Edge pixels become partially transparent only when they fall inside the fixed feather band, so a stricter cut point puts more pixels into the soft zone. At tolerance 0 there are 709 of them; at the default there are 1,630. That is the only place where the default setting made a visible difference, and it is the reason a default of 24 rather than 0 gives a cleaner cutout on the same file.

Three panels comparing removed pixel counts on a studio green screen, a green subject and an object with faint edges across four tolerance settings.
Fig. 2 — the same slider, three frames. The useful movement is between 56 and 60, not at the top.

Where the slider does have range

The flat result is a property of that particular frame, not of the tool. Two other frames show the opposite behaviour, and they are the ones worth remembering.

The object frame, a cutout with faint green-tinted edges, has 43,415 subject pixels. At tolerance 0, two of them are candidates; at 24, five; at 50, seven; at 56, nineteen. The subject count does not move at all: 43,415 survive at every one of those settings. Then at 60 the pocket pass starts claiming 29 pixels and the edge conversion makes 46 more partial, and the survivor count finally drops to 43,383. By 100 the tool has taken 1,008 pixels as candidates and softened 1,309 more. So this frame has a genuine danger point, and it sits between 56 and 60, not at the top of the slider.

The green-subject frame is the third case, and it is the one that should end the idea of the slider as a rescue tool. Of 268,800 pixels, 259,875 score at or above 80 on the green-excess scale and 8,925 score below 8. Almost nothing sits in between. The removed count is 259,875 at tolerance 0, at 24, at 50 and at 100: identical. Lowering tolerance cannot save a green object, because there is no position on the scale where the object stops being green. The fix for that frame is a different key colour or a different subject, not a different number.

What other people get stuck on

The confusion is not unique to this tool. A video editor working with a shadowed green screen tried the obvious escalation: "Increasing the tolerance got side effects. Thus I thought of the obvious, just apply colorkey twice." Stacking two keys did not help, because each pass applies its own cut point to the same pixels rather than narrowing the first one.

Others have asked directly what the number means. One After Effects user wrote: "I read the documentation and what I gathered from it was that, say Match Tolerance is 10%, then any color that is withint 10% of the 'Color to Change' will also be included and modified accordingly. However, how does the math for Match Tolerance work?" That is the same question this page answers, and the honest answer is that percentage-of-what differs by tool. A photographer hitting the same wall wrote: "I have tried increasing tolerance, refining edges and using the smart brush for difficult places, but nothing can get satisfactory results."

A GIMP user described the more common failure in detail: "The range of brightness is quite wide, so I'm finding I have to select many times in an attempt to get rid of this," and then the part that matters here: "When I try to select some of the green, it starts selecting significant portions of the picture that I want to keep, mainly hair." That is the trade in one sentence. Every extra selection was another raise of the threshold, and each one pulled the edge of the subject closer to the cut point.

The remedy people eventually land on is not a bigger number but a narrower sample. Another user, asking about a different tool, put the requirement plainly: "I want to be able to manually set the tolerance level for similar colors as well as soft edges." Tolerance and softness are two separate controls for a reason, and softness is the one that decides how wide the transition band is, while tolerance only decides where the band starts.

A workable order of operations

Conclusion card listing three rules for the tolerance slider and one line describing what the slider cannot do.
Fig. 3 — drag it for a reason, and know which reason applies to your frame.

Why a wide feather makes the slider feel weaker

Softness widens the transition band, and a wider band changes the meaning of a small tolerance step. With softness at 18 the band is 65.4 units; push softness to its maximum and the band is 295. A pixel 20 units away from the cut point is fully removed when the band is narrow, because it falls outside it, and stays partially visible when the band is wide, because it falls inside it. So two people can move the same slider by the same amount and see different results, without either of them being wrong.

This is also why the edge pixel count in the table above is not noise. Those 709 to 1,630 pixels are the band doing its job on the handful of pixels that genuinely sit between screen and subject. The rest of the frame is far enough away on either side that the band never reaches it. If you want to see the band itself, the four-corner colour sampling check tells you how much spread your own backdrop has before you start dragging.

Where the second slider takes over

The tolerance slider ends at the cut point, and everything after that belongs to edge softness, which lengthens the ramp that runs from the cut point back towards the subject. On the same studio frame, softness moved the fully cleared count by 142 pixels across its whole range, against roughly 209,000 already cleared by tolerance, which is a useful way to see the division of labour: one slider decides membership, the other decides opacity.

A colour-distance axis where the cut point is fixed and the feather band widens to the right of it
Fig. 4 — The cut point stays where tolerance put it; softness only moves the far end of the ramp. Measured per step in the softness walkthrough.

Questions people actually ask

Does raising tolerance remove more background?
Only on pixels that sit close to the cut point, and on an evenly lit screen those pixels are rare. In the measured sweep, 0 to 100 was worth 739 pixels on a 268,800-pixel frame. If the background is still visible at 100, the number is not the problem.
Why does raising tolerance delete parts of my subject?
Because raising the cut point moves it into whatever is next on the scale, and that can be your subject. On the object frame, 43,415 subject pixels survived every setting up to 56, and at 60 the first 46 of them became partial.
What does the green preset actually measure?
Green excess, not absolute RGB distance. It scores (G − max(R,B)) ÷ (R+G+B) × 255, so brightness does not matter, only green dominance. That is why a pale grey subject scores zero at every position and a dark green wall still scores high.
Should I set tolerance to 0 for the cleanest edges?
No, 0 is the loosest setting, not the strictest. It accepts the most green as background: on the studio frame it removed 208,714 pixels and left only 709 partial edge pixels, against 1,630 at the default of 24.
Is the custom-colour slider the same scale?
No. Custom colour maps tolerance 0–100 onto a threshold of 4 to 39 using a straight RGB distance, while the green preset maps it onto 183 to 247 using green excess. The same number in the two modes is not comparable.
What if the background survives even at the top of the slider?
Then the backdrop is not green enough for the preset, and no setting will fix it. A white wall scored zero candidates at every position from 0 to 100 in testing; the answer there is a custom key colour or a different kind of tool.