mirror of
https://github.com/opencv/opencv.git
synced 2025-01-18 06:03:15 +08:00
Merge pull request #12515 from hmaarrfk:fix_bayer2rgba_blue_channel
This commit is contained in:
commit
63affb2be9
@ -923,8 +923,10 @@ static void Bayer2RGB_( const Mat& srcmat, Mat& dstmat, int code )
|
||||
{
|
||||
int dst_step = (int)(dstmat.step/sizeof(T));
|
||||
Size size = srcmat.size();
|
||||
int blue = code == CV_BayerBG2BGR || code == CV_BayerGB2BGR ? -1 : 1;
|
||||
int start_with_green = code == CV_BayerGB2BGR || code == CV_BayerGR2BGR;
|
||||
int blue = (code == CV_BayerBG2BGR || code == CV_BayerGB2BGR ||
|
||||
code == CV_BayerBG2BGRA || code == CV_BayerGB2BGRA ) ? -1 : 1;
|
||||
int start_with_green = (code == CV_BayerGB2BGR || code == CV_BayerGR2BGR ||
|
||||
code == CV_BayerGB2BGRA || code == CV_BayerGR2BGRA);
|
||||
|
||||
int dcn = dstmat.channels();
|
||||
size.height -= 2;
|
||||
|
Loading…
Reference in New Issue
Block a user