boost::gil::memory_based_2d_locator

Memory‐based pixel locator. Models: PixelLocatorConcept,HasDynamicXStepTypeConcept,HasDynamicYStepTypeConcept,HasTransposedTypeConcept

Description

The class takes a step iterator as a parameter. The step iterator provides navigation along the vertical axis while its base iterator provides horizontal navigation.

Each instantiation is optimal in terms of size and efficiency. For example, xy locator over interleaved rgb image results in a step iterator consisting of one std::ptrdiff_t for the row size and one native pointer (8 bytes total). ++locator.x() resolves to pointer increment. At the other extreme, a 2D navigation of the even pixels of a planar CMYK image results in a step iterator consisting of one std::ptrdiff_t for the doubled row size, and one step iterator consisting of one std::ptrdiff_t for the horizontal step of two and a CMYK planar_pixel_iterator consisting of 4 pointers (24 bytes). In this case ++locator.x() results in four native pointer additions.

Note also that memory_based_2d_locator does not require that its element type be a pixel. It could be instantiated with an iterator whose value_type models only Regular. In this case the locator models the weaker RandomAccess2DLocatorConcept, and does not model PixelBasedConcept. Many generic algorithms don't require the elements to be pixels./////////////////////////////////////////////////////////////////////////////////////

Types

Member Functions

Name

Description

memory_based_2d_locator [constructor]

Constructors

operator=

Copy assignment operator

axis_iterator

cache_location

is_1d_traversable

operator()

operator*

operator+

operator+=

operator‐

operator‐=

operator[]

Subscript operators

pixel_size

row_size

x

x_at

xy_at

y

y_at

y_distance_to

operator==

Equality operator

operator!=

Inequality operator

Static Data Members

Friends

Name

Description

boost::gil::memory_based_2d_locator

Memory‐based pixel locator. Models: PixelLocatorConcept,HasDynamicXStepTypeConcept,HasDynamicYStepTypeConcept,HasTransposedTypeConcept

Created with MrDocs