CV-0.3.5.3: OpenCV based machine vision library

Safe HaskellSafe-Infered

Utils.Rectangle

Synopsis

Documentation

data Rectangle a

Constructors

Rectangle !a !a !a !a 

Instances

Eq a => Eq (Rectangle a) 
Show a => Show (Rectangle a) 
NFData a => NFData (Rectangle a) 
(Num a, Ord a, Serial a) => Serial (Rectangle a) 
FromBounds (Rectangle a) 
BoundingBox (Rectangle a) 

s :: NFData a => a -> t -> t

left :: Rectangle t -> t

right :: Num a => Rectangle a -> a

top :: Rectangle t -> t

bottom :: Num a => Rectangle a -> a

topLeft :: Rectangle t -> (t, t)

topRight :: Num t => Rectangle t -> (t, t)

bottomLeft :: Num t => Rectangle t -> (t, t)

bottomRight :: Num t => Rectangle t -> (t, t)

vertices :: Num t => Rectangle t -> [(t, t)]

rSize :: Rectangle t -> (t, t)

rArea :: Num a => Rectangle a -> a

center :: Fractional t => Rectangle t -> (t, t)

centerI :: Integral t => Rectangle t -> (t, t)

around :: (Fractional a, Ord a) => (a, a) -> (a, a) -> Rectangle a

Create rectangle around point (x,y)

mkRectangle :: (Num a, Ord a) => (a, a) -> (a, a) -> Rectangle a

mkRectCorners :: (Num a, Ord a) => (a, a) -> (a, a) -> Rectangle a

prop_Corners :: (Int, Int) -> (Int, Int) -> Bool

fromPtSize :: (a, a) -> (a, a) -> Rectangle a

inCoords :: Num t => Rectangle t -> Rectangle t -> ((t, t), (t, t)) -> Rectangle (t, t)

Return rectangle r2 in coordinate system defined by r1

inCoords' :: Num t => Rectangle t -> (t, t) -> (t, t)

Return a point in coordinates of given rectangle

enlargeToNthPower :: (Integral a, Integral b) => b -> Rectangle a -> Rectangle a

 Adjust the size of the rectangle to be divisible by 2^n.

intersection :: (Num a, Ord a) => Rectangle a -> Rectangle a -> Rectangle a

intersects :: (Num a, Ord a) => Rectangle a -> Rectangle a -> Bool

contains :: (Num a, Ord a) => Rectangle a -> Rectangle a -> Bool

intersect1D :: Ord a => (a, a) -> (a, a) -> Bool

prop_intersect1DCommutes :: Ord a => (a, a) -> (a, a) -> Bool

tile :: (Enum a, Num a, Ord a) => (a, a) -> (a, a) -> Rectangle a -> [Rectangle a]

Create a tiling of a rectangles.

scale :: (Integral a3, Integral a, RealFrac a2, RealFrac a1) => (a1, a2) -> Rectangle a3 -> Rectangle a

Scale a rectangle

toInt :: (Integral a, Num a1) => Rectangle a -> Rectangle a1