WPILibC++  unspecified
 All Classes Files Functions Variables Typedefs Enumerations Enumerator Pages
BinaryImage Class Reference

Included for ParticleAnalysisReport definition TODO: Eliminate this dependency! More...

#include <BinaryImage.h>

Inheritance diagram for BinaryImage:
MonoImage ImageBase ErrorBase

Public Member Functions

int GetNumberParticles ()
 Get then number of particles for the image. More...
 
ParticleAnalysisReport GetParticleAnalysisReport (int particleNumber)
 Get a single particle analysis report. More...
 
void GetParticleAnalysisReport (int particleNumber, ParticleAnalysisReport *par)
 Get a single particle analysis report. More...
 
std::vector
< ParticleAnalysisReport > * 
GetOrderedParticleAnalysisReports ()
 Get an ordered vector of particles for the image. More...
 
BinaryImageRemoveSmallObjects (bool connectivity8, int erosions)
 
BinaryImageRemoveLargeObjects (bool connectivity8, int erosions)
 
BinaryImageConvexHull (bool connectivity8)
 
BinaryImageParticleFilter (ParticleFilterCriteria2 *criteria, int criteriaCount)
 
virtual void Write (const char *fileName)
 Write a binary image to flash. More...
 
- Public Member Functions inherited from MonoImage
std::vector< EllipseMatch > * DetectEllipses (EllipseDescriptor *ellipseDescriptor, CurveOptions *curveOptions, ShapeDetectionOptions *shapeDetectionOptions, ROI *roi)
 Look for ellipses in an image. More...
 
std::vector< EllipseMatch > * DetectEllipses (EllipseDescriptor *ellipseDescriptor)
 
- Public Member Functions inherited from ImageBase
 ImageBase (ImageType type)
 Create a new instance of an ImageBase. More...
 
virtual ~ImageBase ()
 Frees memory associated with an ImageBase. More...
 
int GetHeight ()
 Gets the height of an image. More...
 
int GetWidth ()
 Gets the width of an image. More...
 
Image * GetImaqImage ()
 Access the internal IMAQ Image data structure. More...
 
- Public Member Functions inherited from ErrorBase
 ErrorBase (const ErrorBase &)=delete
 
ErrorBaseoperator= (const ErrorBase &)=delete
 
virtual ErrorGetError ()
 Retrieve the current error. More...
 
virtual const ErrorGetError () const
 
virtual void SetErrnoError (llvm::StringRef contextMessage, llvm::StringRef filename, llvm::StringRef function, uint32_t lineNumber) const
 Set error information associated with a C library call that set an error to the "errno" global variable. More...
 
virtual void SetImaqError (int success, llvm::StringRef contextMessage, llvm::StringRef filename, llvm::StringRef function, uint32_t lineNumber) const
 Set the current error information associated from the nivision Imaq API. More...
 
virtual void SetError (Error::Code code, llvm::StringRef contextMessage, llvm::StringRef filename, llvm::StringRef function, uint32_t lineNumber) const
 Set the current error information associated with this sensor. More...
 
virtual void SetWPIError (llvm::StringRef errorMessage, Error::Code code, llvm::StringRef contextMessage, llvm::StringRef filename, llvm::StringRef function, uint32_t lineNumber) const
 Set the current error information associated with this sensor. More...
 
virtual void CloneError (const ErrorBase &rhs) const
 
virtual void ClearError () const
 Clear the current error information associated with this sensor.
 
virtual bool StatusIsFatal () const
 Check if the current error code represents a fatal error. More...
 

Additional Inherited Members

- Static Public Member Functions inherited from ErrorBase
static void SetGlobalError (Error::Code code, llvm::StringRef contextMessage, llvm::StringRef filename, llvm::StringRef function, uint32_t lineNumber)
 
static void SetGlobalWPIError (llvm::StringRef errorMessage, llvm::StringRef contextMessage, llvm::StringRef filename, llvm::StringRef function, uint32_t lineNumber)
 
static ErrorGetGlobalError ()
 Retrieve the current global error.
 
- Protected Attributes inherited from ImageBase
Image * m_imaqImage
 
- Protected Attributes inherited from ErrorBase
Error m_error
 
- Static Protected Attributes inherited from ErrorBase
static priority_mutex _globalErrorMutex
 
static Error _globalError
 

Detailed Description

Included for ParticleAnalysisReport definition TODO: Eliminate this dependency!

Member Function Documentation

int BinaryImage::GetNumberParticles ( )

Get then number of particles for the image.

Returns
the number of particles found for the image.
vector< ParticleAnalysisReport > * BinaryImage::GetOrderedParticleAnalysisReports ( )

Get an ordered vector of particles for the image.

Create a vector of particle analysis reports sorted by size for an image. The vector contains the actual report structures.

Returns
a pointer to the vector of particle analysis reports. The caller must delete the vector when finished using it.
ParticleAnalysisReport BinaryImage::GetParticleAnalysisReport ( int  particleNumber)

Get a single particle analysis report.

Get one (of possibly many) particle analysis reports for an image.

Parameters
particleNumberWhich particle analysis report to return.
Returns
the selected particle analysis report
void BinaryImage::GetParticleAnalysisReport ( int  particleNumber,
ParticleAnalysisReport par 
)

Get a single particle analysis report.

Get one (of possibly many) particle analysis reports for an image. This version could be more efficient when copying many reports.

Parameters
particleNumberWhich particle analysis report to return.
parthe selected particle analysis report
void BinaryImage::Write ( const char *  fileName)
virtual

Write a binary image to flash.

Writes the binary image to flash on the cRIO for later inspection.

Parameters
fileNamethe name of the image file written to the flash.

Reimplemented from ImageBase.


The documentation for this class was generated from the following files: