C# Class Accord.Imaging.Tools

Static tool functions for imaging.

References: P. D. Kovesi. MATLAB and Octave Functions for Computer Vision and Image Processing. School of Computer Science and Software Engineering, The University of Western Australia. Available in: http://www.csse.uwa.edu.au/~pk/Research/MatlabFns/Match/matchbycorrelation.m

Afficher le fichier Open project: accord-net/framework Class Usage Examples

Méthodes publiques

Méthode Description
Center ( this rectangle ) : Point

Computes the center of a given rectangle.

Collinear ( PointF pt1, PointF pt2, PointF pt3 ) : bool

Detects if three points are collinear.

Collinear ( Accord.Imaging.PointH pt1, Accord.Imaging.PointH pt2, Accord.Imaging.PointH pt3 ) : bool

Detects if three points are collinear.

Fundamental ( PointF points1, PointF points2 ) : ].float[

Creates the fundamental matrix between two images from a set of points from each image.

Fundamental ( Accord.Imaging.PointH points1, Accord.Imaging.PointH points2 ) : ].float[

Creates the fundamental matrix between two images from a set of points from each image.

Fundamental ( Accord.Imaging.PointH points1, Accord.Imaging.PointH points2, Accord.Imaging.PointH &epipoles ) : ].float[

Creates the fundamental matrix between two images from a set of points from each image.

GetFormat ( string fileName ) : ImageFormat

Gets the image format most likely associated with a given file name.

Homography ( PointF points1, PointF points2 ) : MatrixH

Creates an homography matrix matching points from a set of points to another.

Homography ( Accord.Imaging.PointH points1, Accord.Imaging.PointH points2 ) : MatrixH

Creates an homography matrix matching points from a set of points to another.

InnerProduct ( this a, PointF b ) : float

Computes the inner product of two points.

IsEqual ( this objA, Rectangle objB, int threshold ) : bool

Compares two rectangles for equality, considering an acceptance threshold.

Max ( this image ) : int

Computes the maximum pixel value in the given image.

Max ( this image, Rectangle rectangle ) : int

Computes the maximum pixel value in the given image.

Max ( this image, int channel ) : int

Computes the maximum pixel value in the given image.

Mean ( this image ) : double

Computes the arithmetic mean of the pixels in a given image.

Mean ( this image, Rectangle rectangle ) : double

Computes the arithmetic mean of the pixels in a given image.

Min ( this image ) : int

Computes the minimum pixel value in the given image.

Min ( this image, Rectangle rectangle ) : int

Computes the minimum pixel value in the given image.

Min ( this image, int channel ) : int

Computes the maximum pixel value in the given image.

Multiply ( this transformationMatrix, PointF point ) : float[]

Multiplies a transformation matrix and a point.

Multiply ( this point, float transformationMatrix ) : float[]

Multiplies a point by a transformation matrix.

Normalize ( this points, MatrixH &transformation ) : System.Drawing.PointF[]

Normalizes a set of homogeneous points so that the origin is located at the centroid and the mean distance to the origin is sqrt(2).

Normalize ( this points, float &transformation ) : System.Drawing.PointF[]

Normalizes a set of homogeneous points so that the origin is located at the centroid and the mean distance to the origin is sqrt(2).

Normalize ( this points, MatrixH &transformation ) : Accord.Imaging.PointH[]

Normalizes a set of homogeneous points so that the origin is located at the centroid and the mean distance to the origin is sqrt(2).

Normalize ( this points, float &transformation ) : Accord.Imaging.PointH[]

Normalizes a set of homogeneous points so that the origin is located at the centroid and the mean distance to the origin is sqrt(2).

StandardDeviation ( this image, Rectangle rectangle, double mean ) : double

Computes the standard deviation of image pixels.

StandardDeviation ( this image, double mean ) : double

Computes the standard deviation of image pixels.

Sum ( this image ) : int

Computes the sum of the pixels in a given image.

Sum ( this image, Rectangle rectangle ) : int

Computes the sum of the pixels in a given image.

Sum ( this image, Rectangle rectangle ) : long

Computes the sum of the pixels in a given image.

TransformPoints ( this fundamentalMatrix ) : System.Drawing.PointF[]

Transforms the given points using this transformation matrix.

Private Methods

Méthode Description
ToBitmap ( this pixels ) : Bitmap
ToBitmap ( this pixels, int width, int height ) : Bitmap
ToBitmap ( this pixels, int width, int height, double min, double max ) : Bitmap
ToDoubleArray ( this image, int channel ) : double[]
ToDoubleArray ( this image, int channel, double min, double max ) : double[]
ToDoubleArray ( this image ) : double[][]
ToDoubleArray ( this image, double min, double max ) : double[][]
ToDoubleMatrix ( this image, int channel ) : ].double[
ToDoubleMatrix ( this image, int channel, double min, double max ) : ].double[
createFundamentalMatrix ( float A ) : ].float[

Method Details

Center() public static méthode

Computes the center of a given rectangle.
public static Center ( this rectangle ) : Point
rectangle this
Résultat Point

Collinear() public static méthode

Detects if three points are collinear.
public static Collinear ( PointF pt1, PointF pt2, PointF pt3 ) : bool
pt1 System.Drawing.PointF
pt2 System.Drawing.PointF
pt3 System.Drawing.PointF
Résultat bool

Collinear() public static méthode

Detects if three points are collinear.
public static Collinear ( Accord.Imaging.PointH pt1, Accord.Imaging.PointH pt2, Accord.Imaging.PointH pt3 ) : bool
pt1 Accord.Imaging.PointH
pt2 Accord.Imaging.PointH
pt3 Accord.Imaging.PointH
Résultat bool

Fundamental() public static méthode

Creates the fundamental matrix between two images from a set of points from each image.
public static Fundamental ( PointF points1, PointF points2 ) : ].float[
points1 System.Drawing.PointF
points2 System.Drawing.PointF
Résultat ].float[

Fundamental() public static méthode

Creates the fundamental matrix between two images from a set of points from each image.
public static Fundamental ( Accord.Imaging.PointH points1, Accord.Imaging.PointH points2 ) : ].float[
points1 Accord.Imaging.PointH
points2 Accord.Imaging.PointH
Résultat ].float[

Fundamental() public static méthode

Creates the fundamental matrix between two images from a set of points from each image.
public static Fundamental ( Accord.Imaging.PointH points1, Accord.Imaging.PointH points2, Accord.Imaging.PointH &epipoles ) : ].float[
points1 Accord.Imaging.PointH
points2 Accord.Imaging.PointH
epipoles Accord.Imaging.PointH
Résultat ].float[

GetFormat() public static méthode

Gets the image format most likely associated with a given file name.
public static GetFormat ( string fileName ) : ImageFormat
fileName string The filename in the form "image.jpg".
Résultat System.Drawing.Imaging.ImageFormat

Homography() public static méthode

Creates an homography matrix matching points from a set of points to another.
public static Homography ( PointF points1, PointF points2 ) : MatrixH
points1 System.Drawing.PointF
points2 System.Drawing.PointF
Résultat MatrixH

Homography() public static méthode

Creates an homography matrix matching points from a set of points to another.
public static Homography ( Accord.Imaging.PointH points1, Accord.Imaging.PointH points2 ) : MatrixH
points1 Accord.Imaging.PointH
points2 Accord.Imaging.PointH
Résultat MatrixH

InnerProduct() public static méthode

Computes the inner product of two points.
public static InnerProduct ( this a, PointF b ) : float
a this
b System.Drawing.PointF
Résultat float

IsEqual() public static méthode

Compares two rectangles for equality, considering an acceptance threshold.
public static IsEqual ( this objA, Rectangle objB, int threshold ) : bool
objA this
objB System.Drawing.Rectangle
threshold int
Résultat bool

Max() public static méthode

Computes the maximum pixel value in the given image.
public static Max ( this image ) : int
image this
Résultat int

Max() public static méthode

Computes the maximum pixel value in the given image.
public static Max ( this image, Rectangle rectangle ) : int
image this
rectangle System.Drawing.Rectangle
Résultat int

Max() public static méthode

Computes the maximum pixel value in the given image.
public static Max ( this image, int channel ) : int
image this
channel int
Résultat int

Mean() public static méthode

Computes the arithmetic mean of the pixels in a given image.
public static Mean ( this image ) : double
image this
Résultat double

Mean() public static méthode

Computes the arithmetic mean of the pixels in a given image.
public static Mean ( this image, Rectangle rectangle ) : double
image this
rectangle System.Drawing.Rectangle
Résultat double

Min() public static méthode

Computes the minimum pixel value in the given image.
public static Min ( this image ) : int
image this
Résultat int

Min() public static méthode

Computes the minimum pixel value in the given image.
public static Min ( this image, Rectangle rectangle ) : int
image this
rectangle System.Drawing.Rectangle
Résultat int

Min() public static méthode

Computes the maximum pixel value in the given image.
public static Min ( this image, int channel ) : int
image this
channel int
Résultat int

Multiply() public static méthode

Multiplies a transformation matrix and a point.
public static Multiply ( this transformationMatrix, PointF point ) : float[]
transformationMatrix this
point System.Drawing.PointF
Résultat float[]

Multiply() public static méthode

Multiplies a point by a transformation matrix.
public static Multiply ( this point, float transformationMatrix ) : float[]
point this
transformationMatrix float
Résultat float[]

Normalize() public static méthode

Normalizes a set of homogeneous points so that the origin is located at the centroid and the mean distance to the origin is sqrt(2).
public static Normalize ( this points, MatrixH &transformation ) : System.Drawing.PointF[]
points this
transformation MatrixH
Résultat System.Drawing.PointF[]

Normalize() public static méthode

Normalizes a set of homogeneous points so that the origin is located at the centroid and the mean distance to the origin is sqrt(2).
public static Normalize ( this points, float &transformation ) : System.Drawing.PointF[]
points this
transformation float
Résultat System.Drawing.PointF[]

Normalize() public static méthode

Normalizes a set of homogeneous points so that the origin is located at the centroid and the mean distance to the origin is sqrt(2).
public static Normalize ( this points, MatrixH &transformation ) : Accord.Imaging.PointH[]
points this
transformation MatrixH
Résultat Accord.Imaging.PointH[]

Normalize() public static méthode

Normalizes a set of homogeneous points so that the origin is located at the centroid and the mean distance to the origin is sqrt(2).
public static Normalize ( this points, float &transformation ) : Accord.Imaging.PointH[]
points this
transformation float
Résultat Accord.Imaging.PointH[]

StandardDeviation() public static méthode

Computes the standard deviation of image pixels.
public static StandardDeviation ( this image, Rectangle rectangle, double mean ) : double
image this
rectangle System.Drawing.Rectangle
mean double
Résultat double

StandardDeviation() public static méthode

Computes the standard deviation of image pixels.
public static StandardDeviation ( this image, double mean ) : double
image this
mean double
Résultat double

Sum() public static méthode

Computes the sum of the pixels in a given image.
public static Sum ( this image ) : int
image this
Résultat int

Sum() public static méthode

Computes the sum of the pixels in a given image.
public static Sum ( this image, Rectangle rectangle ) : int
image this
rectangle System.Drawing.Rectangle
Résultat int

Sum() public static méthode

Computes the sum of the pixels in a given image.
public static Sum ( this image, Rectangle rectangle ) : long
image this
rectangle System.Drawing.Rectangle
Résultat long

TransformPoints() public static méthode

Transforms the given points using this transformation matrix.
public static TransformPoints ( this fundamentalMatrix ) : System.Drawing.PointF[]
fundamentalMatrix this
Résultat System.Drawing.PointF[]