1
0
mirror of https://github.com/opencv/opencv_contrib.git synced 2025-10-20 21:40:49 +08:00

Draw keylines in random color by default as documentation depicts

This commit is contained in:
Jan S. (Milania1)
2015-09-26 22:30:30 +02:00
parent 2de6ff576c
commit 34cf8f7021

View File

@@ -166,7 +166,7 @@ void drawKeylines( const Mat& image, const std::vector<KeyLine>& keylines, Mat&
{ {
/* decide lines' color */ /* decide lines' color */
Scalar lineColor; Scalar lineColor;
if( color != Scalar::all( -1 ) ) if( color == Scalar::all( -1 ) )
{ {
int R = ( rand() % (int) ( 255 + 1 ) ); int R = ( rand() % (int) ( 255 + 1 ) );
int G = ( rand() % (int) ( 255 + 1 ) ); int G = ( rand() % (int) ( 255 + 1 ) );