projects
/
platform
/
upstream
/
opencv.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
5327482
)
Fixed a valgrind 'Conditional jump or move depends on uninitialised value(s)' on...
author
Nghia Ho
<nghiaho12@yahoo.com>
Mon, 6 Jan 2014 09:19:07 +0000
(20:19 +1100)
committer
Nghia Ho
<nghiaho12@yahoo.com>
Mon, 6 Jan 2014 09:19:07 +0000
(20:19 +1100)
samples/cpp/kmeans.cpp
patch
|
blob
|
history
diff --git
a/samples/cpp/kmeans.cpp
b/samples/cpp/kmeans.cpp
index 97de6a0a485028a60c0a33dfdf869a522ee16a20..b742112059b6458cbe36290ddeeea781be4210d3 100644
(file)
--- a/
samples/cpp/kmeans.cpp
+++ b/
samples/cpp/kmeans.cpp
@@
-33,7
+33,7
@@
int main( int /*argc*/, char** /*argv*/ )
{
int k, clusterCount = rng.uniform(2, MAX_CLUSTERS+1);
int i, sampleCount = rng.uniform(1, 1001);
- Mat points(sampleCount,
1, CV_32FC2
), labels;
+ Mat points(sampleCount,
2, CV_32F
), labels;
clusterCount = MIN(clusterCount, sampleCount);
Mat centers(clusterCount, 1, points.type());