Merge pull request #61 from hpgood/patch-1
update the api of "github.com/gonum/matrix/mat64"
This commit is contained in:
commit
60747d253e
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))
|
||||
|
||||
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++ {
|
||||
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])
|
||||
|
|
@ -52,11 +52,11 @@ func GcvCalibrateCamera(objPts, imgPts, camMat, distCoeffs *mat64.Dense,
|
|||
imgPtsVec := NewGcvPoint2f32Vector(int64(nObjPts))
|
||||
|
||||
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++ {
|
||||
imgPtsVec.Set(j, NewGcvPoint2f32(imgPts.Col(nil, j)...))
|
||||
imgPtsVec.Set(j, NewGcvPoint2f32(mat64.Col(nil,j,imgPts.ColView(j))...))
|
||||
}
|
||||
|
||||
_camMat := Mat64ToGcvMat(camMat)
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue