refinery
RAW file processor
Public Member Functions | Public Attributes

refinery::Point Struct Reference

A pixel coordinate counted from the top-left. More...

#include <refinery/image.h>

List of all members.

Public Member Functions

 Point ()
 Empty constructor.
 Point (int row, int col)
 Constructor.
 Point (const Point &rhs)
 Copy constructor.
Point operator+ (const Point &point) const
 Add an offset to this Point.
Point operator- (const Point &point) const
 Subtract an offset from this Point.
bool operator== (const Point &rhs) const
 Compare this Point to another.
bool operator!= (const Point &rhs) const
 Compare this Point to another.

Public Attributes

int row
 Pixel row.
int col
 Pixel column.

Detailed Description

A pixel coordinate counted from the top-left.

This can also represent a pixel-coordinate offset. In other words, you can add or subtract Point instances.

Definition at line 19 of file image.h.


Constructor & Destructor Documentation

refinery::Point::Point ( int  row,
int  col 
) [inline]

Constructor.

Parameters:
[in]rowPixel row.
[in]colPixel column.

Definition at line 33 of file image.h.

refinery::Point::Point ( const Point rhs) [inline]

Copy constructor.

Parameters:
[in]rhsOther Point.

Definition at line 39 of file image.h.


Member Function Documentation

bool refinery::Point::operator!= ( const Point rhs) const [inline]

Compare this Point to another.

Parameters:
[in]rhsOther Point.
Returns:
true iff this Point isn't equivalent to the other.

Definition at line 77 of file image.h.

Point refinery::Point::operator+ ( const Point point) const [inline]

Add an offset to this Point.

Parameters:
[in]pointPoint offset to add to this one.
Returns:
A Point representing the sum.

Definition at line 47 of file image.h.

Point refinery::Point::operator- ( const Point point) const [inline]

Subtract an offset from this Point.

Parameters:
[in]pointPoint offset to subtract from this one.
Returns:
A Point representing the sum.

Definition at line 57 of file image.h.

bool refinery::Point::operator== ( const Point rhs) const [inline]

Compare this Point to another.

Parameters:
[in]rhsOther Point.
Returns:
true iff this Point is equivalent to the other.

Definition at line 67 of file image.h.


Member Data Documentation

Pixel column.

Definition at line 21 of file image.h.

Pixel row.

Definition at line 20 of file image.h.


The documentation for this struct was generated from the following file:
 All Classes Functions Variables Typedefs Enumerations Enumerator