colorCorrection(CRImage)
colorCorrection()所属R语言包:CRImage
译者:生物统计家园网 机器人LoveR
描述----------Description----------
The colors of one image are adapted to the colors of a target image.
一个图像的颜色调整目标图像的颜色。
用法----------Usage----------
colorCorrection(imgO, meanStdTarget,whiteMask = c())
参数----------Arguments----------
参数:imgO
The image who's colors should be adapted
应调整图像的颜色
参数:meanStdTarget
Array with mean and standard deviation of the target image.
阵列与目标图像的均值和标准偏差。
参数:whiteMask
Boolean mask of white pixel in the image. These pixels are excluded from color correction.
布尔掩模图像中的白色像素。这些像素被排除从色彩校正。
Details
详情----------Details----------
Mean and standard deviation of the target image can be calculated using the function calculateMeanStdTarget.
均值和目标图像的标准差,可以计算出使用的功能calculateMeanStdTarget。
值----------Value----------
The image with adapted colors.
适应颜色的图像。
作者(S)----------Author(s)----------
Henrik Failmezger, failmezger@cip.ifi.lmu.de
参考文献----------References----------
doi: 10.1109/38.946629
参见----------See Also----------
calculateMeanStandardTarget
calculateMeanStandardTarget
举例----------Examples----------
#read the target image[阅读目标图像]
f1= system.file("extdata", "exImg2.jpg", package="CRImage")
targetImage=readImage(f1)
#read the image whose color values should be adapted[阅读的图像,其色彩应适应值]
f2= system.file("extdata", "exImg3.jpg", package="CRImage")
imgToConvert=readImage(f2)
#calculate mean and standard deviation of target color channels[计算平均值和标准偏离目标色通道]
mst=calculateMeanStdTarget(targetImage)
# create a white pixel mask[创建一个白色像素面具]
whitePixelMask=imgToConvert[,,1]>0.85 & imgToConvert[,,2]>0.85 & imgToConvert[,,3]>0.85
#adapt color channels of image[调整图像的颜色通道]
imgCorrected=colorCorrection(imgToConvert,mst,whitePixelMask)
转载请注明:出自 生物统计家园网(http://www.biostatistic.net)。
注:
注1:为了方便大家学习,本文档为生物统计家园网机器人LoveR翻译而成,仅供个人R语言学习参考使用,生物统计家园保留版权。
注2:由于是机器人自动翻译,难免有不准确之处,使用时仔细对照中、英文内容进行反复理解,可以帮助R语言的学习。
注3:如遇到不准确之处,请在本贴的后面进行回帖,我们会逐渐进行修订。
|