libCZI
Reading and Writing CZI documents made easy
|
#include <libCZI_Compositor.h>
Classes | |
struct | Options |
Options used for this accessor. More... | |
Public Member Functions | |
virtual libCZI::IntSize | CalcSize (const libCZI::IntRect &roi, float zoom) const =0 |
virtual std::shared_ptr< libCZI::IBitmapData > | Get (const libCZI::IntRect &roi, const libCZI::IDimCoordinate *planeCoordinate, float zoom, const libCZI::ISingleChannelScalingTileAccessor::Options *pOptions)=0 |
virtual std::shared_ptr< libCZI::IBitmapData > | Get (libCZI::PixelType pixeltype, const libCZI::IntRect &roi, const libCZI::IDimCoordinate *planeCoordinate, float zoom, const libCZI::ISingleChannelScalingTileAccessor::Options *pOptions)=0 |
virtual void | Get (libCZI::IBitmapData *pDest, const libCZI::IntRect &roi, const libCZI::IDimCoordinate *planeCoordinate, float zoom, const libCZI::ISingleChannelScalingTileAccessor::Options *pOptions)=0 |
Copy the composite to the specified bitmap. More... | |
Interface for single channel scaling tile accessors. This accessor creates a multi-tile composite of a single channel (and a single plane) with a given zoom-factor. It will use pyramid sub-blocks (if present) in order to create the destination bitmap. In this operation, it will use the pyramid-layer just above the specified zoom-factor and scale down to the requested size.
The scaling operation employed here is a simple nearest-neighbor algorithm.
|
pure virtual |
Calculates the size a bitmap will have (when created by this accessor) for the specified ROI and the specified Zoom. Since the exact size if subject to rounding errors, one should always use this method if the exact size must be known beforehand. The Get-method which operates on a pre-allocated bitmap will only work if the size (of the bitmap passed in) exactly matches.
roi | The ROI. |
zoom | The zoom factor. |
|
pure virtual |
Gets the scaled tile composite of the specified plane and the specified ROI with the specified zoom factor.
The pixeltype is determined by examining the first subblock found in the specified plane (which is an arbitrary subblock). A newly allocated bitmap is returned.
roi | The ROI. |
planeCoordinate | The plane coordinate. |
zoom | The zoom. |
pOptions | Options for controlling the operation (may be nullptr). |
|
pure virtual |
Copy the composite to the specified bitmap.
The size of the bitmap must exactly match the size reported by the method "CalcSize" (for the same ROI and zoom), otherwise an invalid_argument-exception is thrown.
pDest | [in,out] The destination bitmap. |
roi | The ROI. |
planeCoordinate | The plane coordinate. |
zoom | The zoom factor. |
pOptions | Options controlling the operation. May be nullptr. |
|
pure virtual |
Gets the scaled tile composite of the specified plane and the specified ROI with the specified zoom factor.
pixeltype | The pixeltype (of the destination bitmap). |
roi | The ROI. |
planeCoordinate | The plane coordinate. |
zoom | The zoom factor. |
pOptions | Options for controlling the operation (may be nullptr). |