| IOLink 1.11.0

Loading...
Searching...
No Matches
Classes | Public Member Functions | List of all members
CheckerboardImageView Class Reference
Inheritance diagram for CheckerboardImageView:

## Classes
class | ViewOriginImpl
| This class is an implementation of the ViewOriginExtension interface. More...

## Public Member Functions
| CheckerboardImageView (size_t width, size_t height, size_t tileCountByRow, size_t tileCountByColumn)
VectorXu64 & | shape () override
| Return the shape of the image, each component containing the size in this dimension.
DataType | dataType () override
| Return the data type of the samples of this image.
ImageCapabilitySet | capabilities () const override
| Return the capabilities of this image.
std::shared_ptr< const ImageProperties > | properties () override
| Return the view's properties.
std::shared_ptr< const MetadataNode > | metadata () const override
| Return the root node of the metadata attached to this image.
void | readRegion (const RegionXu64 &region, void *dst) override
| Read a region of the image into a buffer.
std::shared_ptr< Extension > | extension (size_t id) override
| This method can be implemented to provide access to specific extensions for ImageView.
Public Member Functions inherited from iolink::ImageView
size_t | dimensionCount ()
| Returns the dimension of the View.
bool | support (ImageCapabilitySet flags)
| Checks if the ImageView supports the given capabilities.
std::string | toString () const
| Return a string representation.
virtual void | read (const VectorXu64 &index, void *dst)
| Read the data at the given index into a buffer.
ImageInterpretation | imageInterpretation ()
| Shortcut to access Image interpretation from image properties.
ImageType | axesInterpretation ()
| Shortcut to access axes interpretation from image properties.
Vector3d | spatialOrigin ()
| Shortcut to access spatial origin from image properties.
Vector3d | spatialSpacing ()
| Shortcut to access spatial spacing from image properties.
std::string | spatialUnit ()
| Shortcut to access the spatial unit from image properties.
const SpatialDirections & | spatialDirections ()
| Shortcut to access spatial directions from image properties.
size_t | bitDepth ()
| Shortcut to access the sample bitdepth from image properties.
bool | hasAlpha ()
| Shortcut to access hasAlpha status from image properties.
Vector2d | valueRange ()
| Shortcut to access the sample value range from image properties.
virtual void | setProperties (std::shared_ptr< const ImageProperties > properties)
| Update the image's properties.
virtual void | setMetadata (std::shared_ptr< MetadataNode > metadata)
| Attach a new metadata node to the image.
virtual void | write (const VectorXu64 &index, const void *src)
| Write value from a buffer at the given index.
virtual void | writeRegion (const RegionXu64 &region, const void *src)
| Write a input buffer into a given region of the image.
void | setImageInterpretation (const ImageInterpretation interpretation)
| Shortcut to set Image interpretation into image properties.
void | setAxesInterpretation (const ImageType type)
| Shortcut to set axes interpretation into image properties.
void | setSpatialOrigin (const Vector3d &origin)
| Shortcut to set spatial origin into image properties.
void | setSpatialSpacing (const Vector3d &spacing)
| Shortcut to set spatial spacing into image properties.
void | setSpatialUnit (const std::string &unit)
| Shortcut to set spatial unit into image properties.
void | setSpatialDirections (const SpatialDirections &directions)
| Shortcut to set spatial direcitons into image properties.
void | setBitDepth (size_t bitDepth)
| Shortcut to set sample bitdepth into image properties.
void | setAlpha (bool value)
| Shortcut to indicate the presence of an alpha channel into image properties.
void | setValueRange (const Vector2d &range)
| Shortcut to set sample value range into image properties.
virtual void | reshape (const VectorXu64 &shape, DataType dataType)
| Change the shape and sample data type of the image.
virtual const Indexer & | indexer ()
| Return an Indexer describing the memory layout of the buffer.
virtual void * | buffer ()
| Return a mutable pointer to the internal CPU memory buffer.
virtual const void * | bufferReadOnly () const
| Return an immutable pointer to the internal CPU memory buffer.
virtual size_t | bufferSize ()
| Size in bytes of the internal CPU buffer.
std::shared_ptr< TilingInfoExtension > | tilingInfo ()
| Shortcut to retrieve TilingInfo extension.
std::shared_ptr< ParallelAccessExtension > | parallelAccess ()
| Shortcut to retrieve ParallelAccess extension.
Public Member Functions inherited from iolink::View
template<typename T >
std::shared_ptr< T > | extension ()
| Get an extension of the view, corresponding to the given type.
std::shared_ptr< ViewOriginExtension > | viewOrigin ()
| Shortcut to access to ViewOrigin extension.

## Detailed Description

Examples
  customImageView.cpp.

## Member Function Documentation

## ◆ capabilities()

ImageCapabilitySet CheckerboardImageView::capabilities | ( |  | ) | const
| inline override virtual

Return the capabilities of this image.

Implements iolink::ImageView.

Examples
  customImageView.cpp.

## ◆ dataType()

DataType CheckerboardImageView::dataType | ( |  | ) |
| inline override virtual

Return the data type of the samples of this image.

Implements iolink::ImageView.

Examples
  customImageView.cpp.

## ◆ extension()

std::shared_ptr< Extension > CheckerboardImageView::extension | ( | size_t | id | ) |
| inline override virtual

This method can be implemented to provide access to specific extensions for ImageView.

We implemented the ViewOriginExtension which can be accessed with this method.

Reimplemented from iolink::View.

## ◆ metadata()

std::shared_ptr< const MetadataNode > CheckerboardImageView::metadata | ( |  | ) | const
| inline override virtual

Return the root node of the metadata attached to this image.

Available when the ImageView has the READ capability.

Exceptions

  NotImplemented | If the implementation does not support reading.

Reimplemented from iolink::ImageView.

Examples
  customImageView.cpp.

## ◆ properties()

std::shared_ptr< const ImageProperties > CheckerboardImageView::properties | ( |  | ) |
| inline override virtual

Return the view's properties.

Implements iolink::ImageView.

Examples
  customImageView.cpp.

## ◆ readRegion()

void CheckerboardImageView::readRegion | ( | const RegionXu64 & | region,
|  | void * | dst
| ) |  |
| inline override virtual

Read a region of the image into a buffer.

Available when the ImageView has the READ capability.

Parameters

  region | The region of the image to read from.
  dst | The buffer where read data will be copied.

Exceptions

  NotImplemented | If the implementation does not support reading.

Reimplemented from iolink::ImageView.

Examples
  customImageView.cpp.

## ◆ shape()

VectorXu64 & CheckerboardImageView::shape | ( |  | ) |
| inline override virtual

Return the shape of the image, each component containing the size in this dimension.

Example:

- A 2D image will return a vector with two dimension, the first being the number of columns, and the second being the number of rows.
- A 3D image will return a vector with two dimension, the first being the number of columns, the second being the number of rows, and the third being the number of slices.

Implements iolink::ImageView.

Examples
  customImageView.cpp.

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

- example/cpp/ImageView/customImageView.cpp