Ask Your Question

Revision history [back]

Are you sure that rgba is a color images ?

   rgba.convertTo(src, CvType.CV_32FC3, 1.0 / 255.0);

when you give a grey image to previous line no exception is thrown and src type can be 32FC1

Are you sure that rgba is a color images ?

   rgba.convertTo(src, CvType.CV_32FC3, 1.0 / 255.0);

when you give a grey image to previous line no exception is thrown and src type can be 32FC1

CvType.CV_32FC3 is not use because in cvtColor there is a mask : _type = CV_MAKETYPE(CV_MAT_DEPTH(_type), channels());

Are you sure that rgba is a color images image ?

   rgba.convertTo(src, CvType.CV_32FC3, 1.0 / 255.0);

when you give a grey image to previous line no exception is thrown and src type can be 32FC1

CvType.CV_32FC3 is not use because in cvtColor there is a mask : _type = CV_MAKETYPE(CV_MAT_DEPTH(_type), channels());

Are you sure that rgba is a color image with three channels and only three ?

   rgba.convertTo(src, CvType.CV_32FC3, 1.0 / 255.0);

when you give a grey image to previous line no exception is thrown and src type can be 32FC1

CvType.CV_32FC3 is not use because in cvtColor there is a mask : _type = CV_MAKETYPE(CV_MAT_DEPTH(_type), channels());