收稿日期:2022-04-17∗基金项目:商洛学院科研基金项目(16SKY007),商洛学院科研横项基金项目(19HKY165)作者简介:李华(1980-),女,陕西西安人,硕士,副教授,从事基于可编程逻辑器件的图像处理相关的研究与教学工作,主要研究方向为数字图像处理。基于FPGA的自动白平衡算法设计∗李华1,蔡嘉烨2(1.商洛学院电子信息与电气工程学院,陕西商洛726000;2.航天系统部装备部军事代表局,西安710082)摘要:为了满足工程项目需求,获取生动彩色图像,设计了一套基于FPGA实现的自动白平衡算法。首先,将RGB图像转换成YCrCb格式,然后将图像划分成16个图像子块,分别统计色差,选择色彩丰富的图像块进行白平衡校正因子的计算,从而完成图像白平衡操作。算法以一片Xilinx公司FPGA作为硬件开发平台,使用Verilog-HDL硬件描述语言并采用由总到分的模块化开发对整个系统进行硬件描述。实验结果表明,所设计的自动白平衡算法获取的彩色图像色彩逼真,算法难度适中、便于硬件开发,具有非常好的工程应用前景。关键词:自动白平衡;FPGA;图像探测器;Bayer格式图像中图分类号:TP391.4文献标识码:ADOI编码:10.14016/j.cnki.1001-9227.2023.01.053DesignofAutoWhiteBalanceAlgorithmBasedonFPGALIHua1,CAIJiaye2(1.SchoolofElectronicInformationandElectricalEngineering,ShangluoUniversity,Shangluo,shaanxi726000,China;2.SpaceSystemDepartment,Xi’an710082,China)Abstract:Inordertomeetthedemandofactualprojectandgetvividcolorimages,thispaperdesignsasetofautomaticwhitebalancealgorithmbasedonFPGAimplementation.Firstofall,theRGBimageisconvertedintoYCrCbformat,andthentheimageisdividedinto16tilestostatisticthecolordifference.Thirdly,colorfulimageblockischosentocalculatethewhitebalancecorrectionfactor,thuscompletethewhitebalanceimageoperation.OneXilinxFieldProgrammableGateArray(FPGA)ischosenasthehardwaredesignplatform,andthealgorithmisdescribedwithVerilog-HDLtoperformthemodular-izationdesignfromtoptobottom.Experimentalresultsshowthatcolorimageobtainedfromtheautomaticwhitebalancealgo-rithmisvividandlowcomplexity,easyhardwareimplementationmakesthealgorithmhasagoodengineeringapplicationval-ue.Keywords:autobalance;FPGA;sensor;bayerpatternimage0引言白平衡(WhiteBalance,WB)是指对白色物体颜色的还原,根据物理学的解释,物体...