update the api of "github.com/gonum/matrix/mat64"
*mat64.Dense has removed the "Col" function.
This commit is contained in:
parent
08a8c82102
commit
9360634c0c
1 changed files with 4 additions and 4 deletions
|
|
@ -24,11 +24,11 @@ func GcvInitCameraMatrix2D(objPts, imgPts *mat64.Dense, dims [2]int,
|
||||||
imgPtsVec := NewGcvPoint2f32Vector(int64(nObjPts))
|
imgPtsVec := NewGcvPoint2f32Vector(int64(nObjPts))
|
||||||
|
|
||||||
for j := 0; j < nObjPts; j++ {
|
for j := 0; j < nObjPts; j++ {
|
||||||
objPtsVec.Set(j, NewGcvPoint3f32(objPts.Col(nil, j)...))
|
objPtsVec.Set(j, NewGcvPoint3f32(mat64.Col(nil,j,objPts.ColView(j))...))
|
||||||
}
|
}
|
||||||
|
|
||||||
for j := 0; j < nObjPts; j++ {
|
for j := 0; j < nObjPts; j++ {
|
||||||
imgPtsVec.Set(j, NewGcvPoint2f32(imgPts.Col(nil, j)...))
|
imgPtsVec.Set(j, NewGcvPoint2f32( mat64.Col(nil,j,imgPts.ColView(j))...))
|
||||||
}
|
}
|
||||||
|
|
||||||
_imgSize := NewGcvSize2i(dims[0], dims[1])
|
_imgSize := NewGcvSize2i(dims[0], dims[1])
|
||||||
|
|
@ -52,11 +52,11 @@ func GcvCalibrateCamera(objPts, imgPts, camMat, distCoeffs *mat64.Dense,
|
||||||
imgPtsVec := NewGcvPoint2f32Vector(int64(nObjPts))
|
imgPtsVec := NewGcvPoint2f32Vector(int64(nObjPts))
|
||||||
|
|
||||||
for j := 0; j < nObjPts; j++ {
|
for j := 0; j < nObjPts; j++ {
|
||||||
objPtsVec.Set(j, NewGcvPoint3f32(objPts.Col(nil, j)...))
|
objPtsVec.Set(j, NewGcvPoint3f32(mat64.Col(nil,j,objPts.ColView(j))...))
|
||||||
}
|
}
|
||||||
|
|
||||||
for j := 0; j < nObjPts; j++ {
|
for j := 0; j < nObjPts; j++ {
|
||||||
imgPtsVec.Set(j, NewGcvPoint2f32(imgPts.Col(nil, j)...))
|
imgPtsVec.Set(j, NewGcvPoint2f32(mat64.Col(nil,j,imgPts.ColView(j))...))
|
||||||
}
|
}
|
||||||
|
|
||||||
_camMat := Mat64ToGcvMat(camMat)
|
_camMat := Mat64ToGcvMat(camMat)
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue