|
OSSIM - Open Source Software Image Map
Version 1.9.0 (20180803)
|
class ossimRectanglePartitioner Utility class to partition up a rectangle. More...
#include <ossimRectanglePartitioner.h>
Public Member Functions | |
| ossimRectanglePartitioner () | |
| default construtor More... | |
| ~ossimRectanglePartitioner () | |
| destructor More... | |
| void | binaryPartition (const ossimIrect &inputRectangle, std::vector< ossimIrect > &result, ossim_uint64 maxSizeInBytes, ossim_uint32 bands, ossim_uint32 bytesPerPixel, ossim_uint32 internalOverlapPixels=0) const |
| Partitions the rectangle doing a binary split on the longest dimension until the total size is less than or equal to the "maxSizeInBytes". More... | |
Private Member Functions | |
| void | splitUntilLessThanMax (ossimIrect &rect, ossim_uint64 maxSizeInBytes, ossim_uint32 bands, ossim_uint32 bytesPerPixel, ossim_uint32 internalOverlapPixels=0) const |
| Recursively splits the input rectangle until the size is less than or equal to maxSizeInBytes. More... | |
| void | splitRect (ossimIrect &rect) const |
| Splits rectangle in half rounding up if needed. More... | |
| ossim_uint64 | getSize (const ossimIrect &rect, ossim_uint32 bands, ossim_uint32 bytesPerPixel, ossim_uint32 internalOverlapPixels=0) const |
| void | trace (const ossimIrect &r, const std::vector< ossimIrect > &v, ossim_uint64 maxSizeInBytes, ossim_uint32 bands, ossim_uint32 bytesPerPixel) const |
| Convenience trace method. More... | |
class ossimRectanglePartitioner Utility class to partition up a rectangle.
Definition at line 27 of file ossimRectanglePartitioner.h.
| ossimRectanglePartitioner::ossimRectanglePartitioner | ( | ) |
| ossimRectanglePartitioner::~ossimRectanglePartitioner | ( | ) |
| void ossimRectanglePartitioner::binaryPartition | ( | const ossimIrect & | inputRectangle, |
| std::vector< ossimIrect > & | result, | ||
| ossim_uint64 | maxSizeInBytes, | ||
| ossim_uint32 | bands, | ||
| ossim_uint32 | bytesPerPixel, | ||
| ossim_uint32 | internalOverlapPixels = 0 |
||
| ) | const |
Partitions the rectangle doing a binary split on the longest dimension until the total size is less than or equal to the "maxSizeInBytes".
Initializes "result" with the resulting rectangles starting at the upper left corner.
| inputRectangle | The source rectangle usually the bounding rectangle of a scene. |
| result | The vector of ossimIrects to hold the result. |
| maxSizeInBytes | Maximum size of the resulting rectangle partitions in bytes. |
| bands | The number of bands in the image. |
| bytesPerPixel. | The number of bytes per pixel for a single band. |
| internalOverlapPixels | Overlap in pixels for desired partitions. (default = 0) This is added to all four sides of the rectangle so |
Definition at line 32 of file ossimRectanglePartitioner.cpp.
References ossimIrect::hasNans(), ossimNotify(), and ossimNotifyLevel_WARN.
|
private |
| rect | Rectangle to give size for in bytes. |
| bands | The number of bands in the image. |
| bytesPerPixel. | The number of bytes per pixel for a single band. |
| internalOverlapPixels | Overlap in pixels. (default = 0) |
Definition at line 210 of file ossimRectanglePartitioner.cpp.
References ossimIrect::height(), and ossimIrect::width().
|
private |
Splits rectangle in half rounding up if needed.
| input | Rectangle to split. |
Will split the longest dimension. If square will split in the lengthwise direction.
Definition at line 189 of file ossimRectanglePartitioner.cpp.
References ossimIrect::height(), and ossimIrect::width().
|
private |
Recursively splits the input rectangle until the size is less than or equal to maxSizeInBytes.
| rect | Input rectangle to split. |
| maxSizeInBytes | Maximum size of the resulting rectangle partitions in bytes. |
| bands | The number of bands in the image. |
| bytesPerPixel. | The number of bytes per pixel for a single band. |
| internalOverlapPixels | Overlap in pixels for desired partitions. (default = 0) |
Definition at line 172 of file ossimRectanglePartitioner.cpp.
|
private |
Convenience trace method.
| r | Input rectangle. |
| v | Vector of resulting partitioned rectangles. |
| maxSizeInBytes | Maximum size of the resulting rectangle partitions in bytes. |
| bands | The number of bands in the image. |
| bytesPerPixel. | The number of bytes per pixel for a single band. |
Definition at line 221 of file ossimRectanglePartitioner.cpp.
References ossimNotify(), ossimNotifyLevel_DEBUG, and ossimIrect::size().
1.8.14