mirror of
https://github.com/opencv/opencv.git
synced 2024-11-25 11:40:44 +08:00
java: fix Mat.toString() for higher dimensions
This commit is contained in:
parent
5fd47352cf
commit
4d3989817c
@ -954,8 +954,11 @@ public class Mat {
|
||||
// javadoc:Mat::toString()
|
||||
@Override
|
||||
public String toString() {
|
||||
return "Mat [ " +
|
||||
rows() + "*" + cols() + "*" + CvType.typeToString(type()) +
|
||||
String _dims = (dims() > 0) ? "" : "-1*-1*";
|
||||
for (int i=0; i<dims(); i++) {
|
||||
_dims += size(i) + "*";
|
||||
}
|
||||
return "Mat [ " + _dims + CvType.typeToString(type()) +
|
||||
", isCont=" + isContinuous() + ", isSubmat=" + isSubmatrix() +
|
||||
", nativeObj=0x" + Long.toHexString(nativeObj) +
|
||||
", dataAddr=0x" + Long.toHexString(dataAddr()) +
|
||||
|
Loading…
Reference in New Issue
Block a user