Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

OpenCV.projectPoints input type are confusing (maybe incorrect?) #40

Open
tomerarnon opened this issue May 8, 2024 · 1 comment
Open
Labels
question Further information is requested

Comments

@tomerarnon
Copy link

OpenCV documentation for projectPoints describes all of the InputArray parameters as vectors or matrices. This agrees with how I see the function used by others in python from cv2.
The julia type signature of OpenCV.projectPoints requires AbstractArray{T, 3} for all of these, and it's not clear why these extra dimensions are needed or how they will be handled. This is the signature listed by methods(projectPoints):

projectPoints(objectPoints::Union{OpenCV.CxxMat, AbstractArray{T, 3} where T<:Union{Float32, Float64, Int16, Int32, Int8, UInt16, UInt8}},
              rvec::Union{OpenCV.CxxMat, AbstractArray{T, 3} where T<:Union{Float32, Float64, Int16, Int32, Int8, UInt16, UInt8}},
              tvec::Union{OpenCV.CxxMat, AbstractArray{T, 3} where T<:Union{Float32, Float64, Int16, Int32, Int8, UInt16, UInt8}},
              cameraMatrix::Union{OpenCV.CxxMat, AbstractArray{T, 3} where T<:Union{Float32, Float64, Int16, Int32, Int8, UInt16, UInt8}},
              distCoeffs::Union{OpenCV.CxxMat, AbstractArray{T, 3} where T<:Union{Float32, Float64, Int16, Int32, Int8, UInt16, UInt8}}
              ; imagePoints, jacobian, aspectRatio)
@rakeshksr rakeshksr added the question Further information is requested label Oct 30, 2024
@yakir12
Copy link

yakir12 commented Nov 26, 2024

I came here for similar reason but specifically for the arguments of calibrateCamera.

Can you please post an example of a correct instance of the arguments for projectPoints or calibrateCamera?

I can't even seem to be able to create anything that fits the objectPoints::Union{OpenCV.CxxMat, AbstractArray{T, 3} where T<:Union{Float32, Float64, Int16, Int32, Int8, UInt16, UInt8}} "bill"...

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
question Further information is requested
Projects
None yet
Development

No branches or pull requests

3 participants