#include <REdgeDetection.h>
Collaboration diagram for REdgeDetection:
Public Member Functions | |
REdgeDetection (ImageProcessor &processor) | |
Default constructor. | |
~REdgeDetection () | |
Destructor. | |
bool | scanEast (int &x, int &y) |
Scans to the right side of the image and detects edges. | |
bool | scanWest (int &x, int &y) |
Scans to the left side of the image and detects edges. | |
bool | scanNorth (int &x, int &y) |
Scans to the top and detects edges. | |
bool | scanSouth (int &x, int &y) |
Scans to the bottom and detects edges. | |
bool | ballScanEast (int &x, int &y) |
Scans to the right side and detects edges of balls. | |
bool | ballScanWest (int &x, int &y) |
Scans to the left side and detects edges of balls. | |
bool | scan (int &x, int &y, Vector2< double > direction) |
Follows the given direction, and determines edges by the sum of all three channels. | |
bool | bufferedScan (int &x, int &y, Vector2< double > direction) |
Follows the given direction, and determines edges by the sum of all three channels. | |
bool | bufferedScan (int &x, int &y) |
Follows the last given direction. | |
bool | scanField (int &x, int &y, Vector2< double > direction) |
Follows the given direction,and searches for field-edge-points. | |
bool | scanField (int &x, int &y) |
Follows the last given direction,and searches for field-edge-points. | |
bool | scan (int &x, int &y) |
Follows the last given direction, and determines edges by the sum of all three channels. | |
bool | colorScan (int &x, int &y, Vector2< double > direction, colorClass &lastColor) |
Follows the given direction, and determines edges by looking for differences of the colorClass of two following pixels. | |
bool | colorScan (int &x, int &y, colorClass &lastColor) |
Follows the current direction, and determines edges by looking for differences of the colorClass of two following pixels. | |
bool | susanScan (int &x, int &y, Vector2< double > direction) |
Follows the given direction, and determines edges with help of the SUSANEdgeDetection. | |
bool | scan (int &x, int &y, int x1, int y1) |
Follows the given direction, and determines edges by the sum of all three channels. | |
bool | colorScan (int &x, int &y, int x1, int y1, colorClass &lastColor) |
Follows the given direction, and determines edges by the sum of all three channels. | |
void | setDirection (Vector2< double > dir) |
Setter for member direction. | |
colorClass | getColor (int index) |
Returns a color from the color buffer. | |
int | getRange (int index) |
Returns a range from the range buffer. | |
bool | isHorizontalEdge (int x, int y) |
This function implements a edge filter for horizontal edges. | |
int | horizontalEdgeVote (int x, int y) |
This function implements a edge filter for horizontal edges. | |
bool | isVerticalEdge (int x, int y) |
This function implements a edge filter for vertical edges. | |
int | verticalEdgeVote (int x, int y) |
This function implements a edge filter for vertical edges. | |
int | ballEdgeVote (int x, int y) |
This function implements a edge filter for the ball. | |
int | crossEdgeVote (int x, int y) |
This function implements a edge filter. | |
int | fieldEdgeVote (int x, int y) |
This function implements a edge filter. | |
colorClass | getColor (int x, int y) |
Implemented with ColorTable interface. | |
void | skip (int &x, int &y) |
Gives the next pixel of last scan. | |
bool | findStart (Vector2< int > &start, const Vector2< double > &dir) |
Determines the first valid point on a run. | |
int | getBufferSize () |
Getter for the size of the color-buffer. | |
Public Attributes | |
int | threshold |
Threshold for edge scans. | |
int | tempX |
Holds the last visited x-coordinate of a scan. | |
int | tempY |
Holds the last visited y-coordinate of a scan. | |
Private Member Functions | |
int | fastCrossEdgeVote (int x, int y) |
This function implements a edge filter. | |
void | addColor () |
Adds a color and its range to the buffers. | |
bool | insideImage (int x, int y) |
Tests, if a point is a valid. | |
int | susanVote (int x, int y) |
This function implements a edge filter. | |
Private Attributes | |
ImageProcessor & | ip |
the image processor interfaces | |
SUSANEdgeDetectionLite | susanDetector |
an external edgeDetector | |
Vector2< double > | direction |
current scan direction | |
int | e |
a value for bresenham algorithm | |
int | f |
a value for bresenham algorithm | |
int | g |
a value for bresenham algorithm | |
int | dx |
a value for bresenham algorithm | |
int | dy |
a value for bresenham algorithm | |
int | cx |
a value for bresenham algorithm | |
int | cy |
a value for bresenham algorithm | |
int | bufferSize |
current buffer size | |
colorClass | currentColor |
holds the color of the active pixel | |
colorClass | lastColor |
holds the color of the previous pixel | |
int | colorRange |
The last range of a color scan. | |
colorClass | colorBuffer [20] |
This buffer is used to store the colors passed by a buffered scan-method during the last scan. | |
int | ranges [20] |
This buffer is used to store the ranges of the colors. |
Definition at line 21 of file REdgeDetection.h.
|
Default constructor.
Definition at line 15 of file REdgeDetection.cpp. References DEFAULT_EDGE_THRESHOLD. |
|
Destructor.
Definition at line 24 of file REdgeDetection.cpp. |
|
Scans to the right side of the image and detects edges. The position of the edge is stored in x,y.
Definition at line 28 of file REdgeDetection.cpp. References Image::cameraInfo, fastCrossEdgeVote(), ImageProcessorInterfaces::image, insideImage(), and CameraInfo::resolutionWidth. Referenced by RFieldSpecialist::invokeOnPreScan(), RBridgeSpecialist::invokeOnPreScan(), and BoxSpecialist::invokeOnPreScan(). |
Here is the call graph for this function:
|
Scans to the left side of the image and detects edges. The position of the edge is stored in x,y.
Definition at line 53 of file REdgeDetection.cpp. References fastCrossEdgeVote(), and insideImage(). Referenced by RFieldSpecialist::invokeOnPreScan(), RBridgeSpecialist::invokeOnPreScan(), and BoxSpecialist::invokeOnPreScan(). |
Here is the call graph for this function:
|
Scans to the top and detects edges. The position of the edge is stored in x,y.
Definition at line 77 of file REdgeDetection.cpp. References fastCrossEdgeVote(), and insideImage(). |
Here is the call graph for this function:
|
Scans to the bottom and detects edges. The position of the edge is stored in x,y.
Definition at line 101 of file REdgeDetection.cpp. References Image::cameraInfo, fastCrossEdgeVote(), ImageProcessorInterfaces::image, insideImage(), and CameraInfo::resolutionHeight. |
Here is the call graph for this function:
|
Scans to the right side and detects edges of balls. The position of the edge is stored in x,y.
Definition at line 126 of file REdgeDetection.cpp. References ballEdgeVote(). |
Here is the call graph for this function:
|
Scans to the left side and detects edges of balls. The position of the edge is stored in x,y.
Definition at line 149 of file REdgeDetection.cpp. References ballEdgeVote(). |
Here is the call graph for this function:
|
Follows the given direction, and determines edges by the sum of all three channels. The position of the edge is stored in x and y.
Definition at line 172 of file REdgeDetection.cpp. References crossEdgeVote(), cx, cy, e, f, g, tempX, tempY, Vector2< double >::x, and Vector2< double >::y. Referenced by RBallSpecialist2::calculateLargeCircle(), RBridgeSpecialist::findBridgeMark(), BoxSpecialist::fitLandmark(), BoxSpecialist::searchGoal(), and BoxSpecialist::searchLandmark(). |
Here is the call graph for this function:
|
Follows the given direction, and determines edges by the sum of all three channels. The position of the edge is stored in x and y. Fills the colorBuffer while scanning, so the client can determine with the colorBuffer-Array what kind of object was found.
Definition at line 266 of file REdgeDetection.cpp. References addColor(), bufferSize, colorRange, crossEdgeVote(), cx, cy, e, f, g, getColor(), tempX, tempY, Vector2< double >::x, and Vector2< double >::y. Referenced by RDefaultStrategy::postScan(). |
Here is the call graph for this function:
|
Follows the last given direction. Skips 3 pixels at the beginning of each scan, while filling the buffer.
Definition at line 394 of file REdgeDetection.cpp. References addColor(), bufferSize, colorRange, crossEdgeVote(), cx, cy, e, f, g, getColor(), skip(), tempX, and tempY. |
Here is the call graph for this function:
|
Follows the given direction,and searches for field-edge-points. Determines edges by the sum of the first two channels. The position of the edge is stored in x and y.
Definition at line 511 of file REdgeDetection.cpp. References cx, cy, e, f, fieldEdgeVote(), g, tempX, tempY, Vector2< double >::x, and Vector2< double >::y. |
Here is the call graph for this function:
|
Follows the last given direction,and searches for field-edge-points. Determines edges by the sum of the first two channels. The position of the edge is stored in x and y.
Definition at line 605 of file REdgeDetection.cpp. References cx, cy, e, f, fieldEdgeVote(), g, tempX, and tempY. |
Here is the call graph for this function:
|
Follows the last given direction, and determines edges by the sum of all three channels.
Definition at line 1049 of file REdgeDetection.cpp. References crossEdgeVote(), cx, cy, e, f, g, tempX, and tempY. |
Here is the call graph for this function:
|
Follows the given direction, and determines edges by looking for differences of the colorClass of two following pixels.
Definition at line 840 of file REdgeDetection.cpp. References colorClass, cx, cy, e, f, g, getColor(), noColor, Vector2< double >::x, and Vector2< double >::y. Referenced by RBridgeSpecialist::findBridgeMark(), RBridgeSpecialist::getPosition(), and BoxSpecialist::searchLandmark(). |
Here is the call graph for this function:
|
Follows the current direction, and determines edges by looking for differences of the colorClass of two following pixels.
Definition at line 908 of file REdgeDetection.cpp. References colorClass, cx, cy, e, f, g, getColor(), and noColor. |
Here is the call graph for this function:
|
Follows the given direction, and determines edges with help of the SUSANEdgeDetection. The position of the edge is stored in x and y.
Definition at line 955 of file REdgeDetection.cpp. References cx, cy, e, f, g, susanVote(), tempX, tempY, Vector2< double >::x, and Vector2< double >::y. |
Here is the call graph for this function:
|
Follows the given direction, and determines edges by the sum of all three channels. The position of the edge is stored in x and y.
Definition at line 678 of file REdgeDetection.cpp. References crossEdgeVote(), cx, cy, e, f, fastCrossEdgeVote(), g, tempX, and tempY. |
Here is the call graph for this function:
|
Follows the given direction, and determines edges by the sum of all three channels. The position of the edge is stored in x and y.
Definition at line 771 of file REdgeDetection.cpp. References colorClass, cx, cy, e, f, g, getColor(), and noColor. |
Here is the call graph for this function:
|
Setter for member direction.
Definition at line 194 of file REdgeDetection.h. References cx, cy, e, f, g, Vector2< V >::x, and Vector2< V >::y. Referenced by RBridgeSpecialist::findBridgeMark(), RBridgeSpecialist::getPosition(), RDefaultStrategy::postScan(), and BoxSpecialist::searchLandmark(). |
|
Returns a color from the color buffer.
Definition at line 215 of file REdgeDetection.h. References colorBuffer, and colorClass. Referenced by bufferedScan(), colorScan(), and RFieldStateMachine::update(). |
|
Returns a range from the range buffer.
Definition at line 222 of file REdgeDetection.h. References ranges. Referenced by RFieldStateMachine::update(). |
|
This function implements a edge filter for horizontal edges.
Definition at line 230 of file REdgeDetection.h. References horizontalEdgeVote(). Referenced by RBallSpecialist2::isEdge(). |
Here is the call graph for this function:
|
This function implements a edge filter for horizontal edges.
Definition at line 238 of file REdgeDetection.h. References Image::cameraInfo, Image::image, ImageProcessorInterfaces::image, and CameraInfo::resolutionWidth. Referenced by isHorizontalEdge(). |
|
This function implements a edge filter for vertical edges.
Definition at line 256 of file REdgeDetection.h. References verticalEdgeVote(). Referenced by RBallSpecialist2::isEdge(). |
Here is the call graph for this function:
|
This function implements a edge filter for vertical edges.
Definition at line 264 of file REdgeDetection.h. References Image::cameraInfo, Image::image, ImageProcessorInterfaces::image, and CameraInfo::resolutionHeight. Referenced by isVerticalEdge(). |
|
This function implements a edge filter for the ball.
Definition at line 282 of file REdgeDetection.h. References Image::cameraInfo, Image::image, ImageProcessorInterfaces::image, CameraInfo::resolutionHeight, and CameraInfo::resolutionWidth. Referenced by ballScanEast(), and ballScanWest(). |
|
This function implements a edge filter.
Definition at line 317 of file REdgeDetection.h. References Image::cameraInfo, Image::image, ImageProcessorInterfaces::image, CameraInfo::resolutionHeight, and CameraInfo::resolutionWidth. Referenced by bufferedScan(), and scan(). |
|
This function implements a edge filter. Only looking at the gradients of the channels Y and U.
Definition at line 352 of file REdgeDetection.h. References Image::cameraInfo, Image::image, ImageProcessorInterfaces::image, CameraInfo::resolutionHeight, and CameraInfo::resolutionWidth. Referenced by scanField(). |
|
Implemented with ColorTable interface. Corrects the color before classifying.
Definition at line 384 of file REdgeDetection.h. References Image::cameraInfo, colorClass, ImageProcessorInterfaces::colorTable, ColorCorrector::correct(), cy, ColorTable::getColorClass(), Image::image, ImageProcessorInterfaces::image, CameraInfo::resolutionHeight, and CameraInfo::resolutionWidth. |
Here is the call graph for this function:
|
Gives the next pixel of last scan. This is only for the scans that use Bresenham's algorithm.
Definition at line 401 of file REdgeDetection.h. References cx, cy, e, f, and g. Referenced by bufferedScan(), RBridgeSpecialist::findBridgeMark(), BoxSpecialist::fitLandmark(), and BoxSpecialist::searchLandmark(). |
|
Determines the first valid point on a run.
Definition at line 430 of file REdgeDetection.h. References Image::cameraInfo, Geometry::clipLineWithRectangleCohenSutherland(), ImageProcessorInterfaces::image, CameraInfo::resolutionHeight, CameraInfo::resolutionWidth, Vector2< V >::x, and Vector2< V >::y. Referenced by RDefaultStrategy::postScan(). |
Here is the call graph for this function:
|
Getter for the size of the color-buffer.
Definition at line 446 of file REdgeDetection.h. References bufferSize. Referenced by RFieldStateMachine::update(). |
|
This function implements a edge filter.
Definition at line 510 of file REdgeDetection.h. References Image::image, and ImageProcessorInterfaces::image. Referenced by scan(), scanEast(), scanNorth(), scanSouth(), and scanWest(). |
|
Adds a color and its range to the buffers.
Definition at line 538 of file REdgeDetection.h. References bufferSize, colorBuffer, colorRange, and ranges. Referenced by bufferedScan(). |
|
Tests, if a point is a valid. Thats a helper.
Definition at line 554 of file REdgeDetection.h. References Image::cameraInfo, ImageProcessorInterfaces::image, CameraInfo::resolutionHeight, and CameraInfo::resolutionWidth. Referenced by scanEast(), scanNorth(), scanSouth(), and scanWest(). |
|
This function implements a edge filter.
Definition at line 564 of file REdgeDetection.h. References Image::cameraInfo, ImageProcessorInterfaces::image, SUSANEdgeDetectionLite::isEdgePoint(), CameraInfo::resolutionHeight, CameraInfo::resolutionWidth, and susanDetector. Referenced by susanScan(). |
Here is the call graph for this function:
|
Threshold for edge scans.
Definition at line 35 of file REdgeDetection.h. Referenced by RBallSpecialist2::executePostProcessing(), BoxSpecialist::executePostProcessing(), RBridgeSpecialist::init(), RBallSpecialist2::init(), BoxSpecialist::init(), RFieldSpecialist::invokeOnPreScan(), RDefaultStrategy::postScan(), and RDefaultStrategy::RDefaultStrategy(). |
|
Holds the last visited x-coordinate of a scan.
Definition at line 38 of file REdgeDetection.h. Referenced by bufferedScan(), scan(), scanField(), and susanScan(). |
|
Holds the last visited y-coordinate of a scan.
Definition at line 41 of file REdgeDetection.h. Referenced by bufferedScan(), scan(), scanField(), and susanScan(). |
|
the image processor interfaces
Definition at line 466 of file REdgeDetection.h. |
|
an external edgeDetector
Definition at line 469 of file REdgeDetection.h. Referenced by susanVote(). |
|
current scan direction
Definition at line 471 of file REdgeDetection.h. |
|
a value for bresenham algorithm
Definition at line 474 of file REdgeDetection.h. Referenced by bufferedScan(), colorScan(), scan(), scanField(), setDirection(), skip(), and susanScan(). |
|
a value for bresenham algorithm
Definition at line 476 of file REdgeDetection.h. Referenced by bufferedScan(), colorScan(), scan(), scanField(), setDirection(), skip(), and susanScan(). |
|
a value for bresenham algorithm
Definition at line 478 of file REdgeDetection.h. Referenced by bufferedScan(), colorScan(), scan(), scanField(), setDirection(), skip(), and susanScan(). |
|
a value for bresenham algorithm
Definition at line 480 of file REdgeDetection.h. |
|
a value for bresenham algorithm
Definition at line 482 of file REdgeDetection.h. |
|
a value for bresenham algorithm
Definition at line 484 of file REdgeDetection.h. Referenced by bufferedScan(), colorScan(), scan(), scanField(), setDirection(), skip(), and susanScan(). |
|
a value for bresenham algorithm
Definition at line 486 of file REdgeDetection.h. Referenced by bufferedScan(), colorScan(), getColor(), scan(), scanField(), setDirection(), skip(), and susanScan(). |
|
current buffer size
Definition at line 488 of file REdgeDetection.h. Referenced by addColor(), bufferedScan(), and getBufferSize(). |
|
holds the color of the active pixel
Definition at line 490 of file REdgeDetection.h. |
|
holds the color of the previous pixel
Definition at line 492 of file REdgeDetection.h. |
|
The last range of a color scan.
Definition at line 495 of file REdgeDetection.h. Referenced by addColor(), and bufferedScan(). |
|
This buffer is used to store the colors passed by a buffered scan-method during the last scan.
Definition at line 500 of file REdgeDetection.h. Referenced by addColor(), and getColor(). |
|
This buffer is used to store the ranges of the colors.
Definition at line 503 of file REdgeDetection.h. Referenced by addColor(), and getRange(). |