LumiGuide / haskell-opencv

Haskell binding to OpenCV-3.x
Other
154 stars 44 forks source link

getPerspectiveTransform should accept V4 instead of Vector #140

Closed yorickvP closed 5 years ago

yorickvP commented 5 years ago
getPerspectiveTransform
    :: (IsPoint2 point2 CFloat, MonadError CvException m)
    => V.Vector (point2 CFloat) -- ^ Array of 4 floating-point Points representing 4 vertices in source image
    -> V.Vector (point2 CFloat) -- ^ Array of 4 floating-point Points representing 4 vertices in destination image
    -> m (Mat (ShapeT [3,3]) ('S 1) ('S Double)) -- ^ The output perspective transformation, 3x3 floating-point-matrix.

Since this takes an array of 4 floating-point Points, it should be represented as a V4, just like getAffineTransform uses as V3.

roelvandijk commented 5 years ago

Good point!