Merge pull request #23108 from crackwitz:issue-23107
Usage of imread(): magic number 0, unchecked result * docs: rewrite 0/1 to IMREAD_GRAYSCALE/IMREAD_COLOR in imread() * samples, apps: rewrite 0/1 to IMREAD_GRAYSCALE/IMREAD_COLOR in imread() * tests: rewrite 0/1 to IMREAD_GRAYSCALE/IMREAD_COLOR in imread() * doc/py_tutorials: check imread() result
This commit is contained in:
committed by
GitHub
parent
7b7774476e
commit
a64b51dd94
@@ -175,7 +175,7 @@ public class OpenCVTestCase extends TestCase {
|
||||
rgba128 = new Mat(matSize, matSize, CvType.CV_8UC4, Scalar.all(128));
|
||||
|
||||
rgbLena = Imgcodecs.imread(OpenCVTestRunner.LENA_PATH);
|
||||
grayChess = Imgcodecs.imread(OpenCVTestRunner.CHESS_PATH, 0);
|
||||
grayChess = Imgcodecs.imread(OpenCVTestRunner.CHESS_PATH, Imgcodecs.IMREAD_GRAYSCALE);
|
||||
|
||||
gray255_32f_3d = new Mat(new int[]{matSize, matSize, matSize}, CvType.CV_32F, new Scalar(255.0));
|
||||
|
||||
|
||||
Reference in New Issue
Block a user