|
10 | 10 |
|
11 | 11 | 亮度调整是将图像像素的强度整体变大/变小,对比度调整指的是图像暗处的像素强度变低,亮出的变高,从而拓宽某个区域内的显示精度。
|
12 | 12 |
|
13 | | -OpenCV中亮度和对比度应用这个公式来计算:$ g(x)=\alpha f(x)+\beta ,ドル其中:α(>0)、β常称为增益与偏置值,分别控制图片的对比度和亮度。 |
| 13 | +OpenCV中亮度和对比度应用这个公式来计算:<span class="mrow" id="MathJax-Span-2"><span class="mi" id="MathJax-Span-3" style="font-family: MathJax_Math-italic;">g<span style="display: inline-block; overflow: hidden; height: 1px; width: 0.003em;"></span></span><span class="mo" id="MathJax-Span-4" style="font-family: MathJax_Main;">(</span><span class="mi" id="MathJax-Span-5" style="font-family: MathJax_Math-italic;">x</span><span class="mo" id="MathJax-Span-6" style="font-family: MathJax_Main;">)</span><span class="mo" id="MathJax-Span-7" style="font-family: MathJax_Main; padding-left: 0.281em;">=</span><span class="mi" id="MathJax-Span-8" style="font-family: MathJax_Math-italic; padding-left: 0.281em;">α</span><span class="mi" id="MathJax-Span-9" style="font-family: MathJax_Math-italic;">f<span style="display: inline-block; overflow: hidden; height: 1px; width: 0.058em;"></span></span><span class="mo" id="MathJax-Span-10" style="font-family: MathJax_Main;">(</span><span class="mi" id="MathJax-Span-11" style="font-family: MathJax_Math-italic;">x</span><span class="mo" id="MathJax-Span-12" style="font-family: MathJax_Main;">)</span><span class="mo" id="MathJax-Span-13" style="font-family: MathJax_Main; padding-left: 0.225em;">+</span><span class="mi" id="MathJax-Span-14" style="font-family: MathJax_Math-italic; padding-left: 0.225em;">β<span style="display: inline-block; overflow: hidden; height: 1px; width: 0.003em;"></span></span></span>,其中:α(>0)、β常称为增益与偏置值,分别控制图片的对比度和亮度。 |
14 | 14 |
|
15 | 15 | > 经验之谈:此处对α/β控制对比度和亮度有争议,具体请参考:[OpenCV关于对比度和亮度的误解](http://blog.csdn.net/abc20002929/article/details/40474807)。
|
16 | 16 |
|
@@ -43,4 +43,4 @@ cv2.waitKey(0)
|
43 | 43 | - [numpy.clip()](https://docs.scipy.org/doc/numpy/reference/generated/numpy.clip.html#numpy.clip)
|
44 | 44 | - [OpenCV关于对比度和亮度的误解](http://blog.csdn.net/abc20002929/article/details/40474807)
|
45 | 45 | - [OpenCV改变图像亮度和对比度以及优化](http://blog.csdn.net/u013139259/article/details/52145377)
|
46 | | -- [Mat::convertTo](https://docs.opencv.org/3.1.0/d3/d63/classcv_1_1Mat.html#a3f356665bb0ca452e7d7723ccac9a810) |
| 46 | +- [Mat::convertTo](https://docs.opencv.org/3.1.0/d3/d63/classcv_1_1Mat.html#a3f356665bb0ca452e7d7723ccac9a810) |
0 commit comments