HDK
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
ImageBuf::IteratorBase Class Reference

#include <imagebuf.h>

+ Inheritance diagram for ImageBuf::IteratorBase:

Public Member Functions

 IteratorBase (const ImageBuf &ib, WrapMode wrap)
 
 IteratorBase (const ImageBuf &ib, const ROI &roi, WrapMode wrap)
 Construct valid iteration region from ImageBuf and ROI. More...
 
 IteratorBase (const ImageBuf &ib, int xbegin, int xend, int ybegin, int yend, int zbegin, int zend, WrapMode wrap)
 
 IteratorBase (const IteratorBase &i)
 
 ~IteratorBase ()
 
const IteratorBaseassign_base (const IteratorBase &i)
 
int x () const
 
int y () const
 
int z () const
 
bool valid () const
 Is the current location within the designated iteration range? More...
 
bool valid (int x_, int y_, int z_=0) const
 
bool exists (int x_, int y_, int z_=0) const
 
bool exists () const
 
bool done () const
 Are we finished iterating over the region? More...
 
int deep_samples () const
 Retrieve the number of deep data samples at this pixel. More...
 
WrapMode wrap () const
 Return the wrap mode. More...
 
void pos (int x_, int y_, int z_=0)
 
OIIO_FORCEINLINE void operator++ ()
 
void operator++ (int)
 
ROI range () const
 Return the iteration range. More...
 
void rerange (int xbegin, int xend, int ybegin, int yend, int zbegin, int zend, WrapMode wrap=WrapDefault)
 

Protected Member Functions

void init_ib (WrapMode wrap)
 
void range_is_image ()
 
OIIO_FORCEINLINE void pos_xincr ()
 
void pos_done ()
 
void make_writable ()
 
void OIIO_API release_tile ()
 

Protected Attributes

const ImageBufm_ib = nullptr
 
bool m_valid = false
 
bool m_exists = false
 
bool m_deep = false
 
bool m_localpixels = false
 
int m_img_xbegin
 
int m_img_xend
 
int m_img_ybegin
 
int m_img_yend
 
int m_img_zbegin
 
int m_img_zend
 
int m_rng_xbegin
 
int m_rng_xend
 
int m_rng_ybegin
 
int m_rng_yend
 
int m_rng_zbegin
 
int m_rng_zend
 
int m_x
 
int m_y
 
int m_z
 
pvt::ImageCacheTile * m_tile = nullptr
 
int m_tilexbegin
 
int m_tileybegin
 
int m_tilezbegin
 
int m_tilexend
 
int m_nchannels
 
stride_t m_pixel_stride
 
char * m_proxydata = nullptr
 
WrapMode m_wrap = WrapBlack
 

Friends

class ImageBuf
 
class ImageBufImpl
 

Detailed Description

Definition at line 1188 of file imagebuf.h.

Constructor & Destructor Documentation

ImageBuf::IteratorBase::IteratorBase ( const ImageBuf ib,
WrapMode  wrap 
)
inline

Definition at line 1190 of file imagebuf.h.

ImageBuf::IteratorBase::IteratorBase ( const ImageBuf ib,
const ROI roi,
WrapMode  wrap 
)
inline

Construct valid iteration region from ImageBuf and ROI.

Definition at line 1198 of file imagebuf.h.

ImageBuf::IteratorBase::IteratorBase ( const ImageBuf ib,
int  xbegin,
int  xend,
int  ybegin,
int  yend,
int  zbegin,
int  zend,
WrapMode  wrap 
)
inline

Construct from an ImageBuf and designated region – iterate over region, starting with the upper left pixel.

Definition at line 1216 of file imagebuf.h.

ImageBuf::IteratorBase::IteratorBase ( const IteratorBase i)
inline

Definition at line 1229 of file imagebuf.h.

ImageBuf::IteratorBase::~IteratorBase ( )
inline

Definition at line 1242 of file imagebuf.h.

Member Function Documentation

const IteratorBase& ImageBuf::IteratorBase::assign_base ( const IteratorBase i)
inline

Assign one IteratorBase to another

Definition at line 1250 of file imagebuf.h.

int ImageBuf::IteratorBase::deep_samples ( ) const
inline

Retrieve the number of deep data samples at this pixel.

Definition at line 1314 of file imagebuf.h.

bool ImageBuf::IteratorBase::done ( ) const
inline

Are we finished iterating over the region?

Definition at line 1303 of file imagebuf.h.

bool ImageBuf::IteratorBase::exists ( int  x_,
int  y_,
int  z_ = 0 
) const
inline

Is the location (x,y[,z]) within the region of the ImageBuf that contains pixel values (sometimes called the "data window")?

Definition at line 1291 of file imagebuf.h.

bool ImageBuf::IteratorBase::exists ( ) const
inline

Does the current location exist within the ImageBuf's data window?

Definition at line 1299 of file imagebuf.h.

void ImageBuf::IteratorBase::init_ib ( WrapMode  wrap)
inlineprotected

Definition at line 1445 of file imagebuf.h.

void ImageBuf::IteratorBase::make_writable ( )
inlineprotected

Definition at line 1526 of file imagebuf.h.

OIIO_FORCEINLINE void ImageBuf::IteratorBase::operator++ ( )
inline

Increment to the next pixel in the region.

Definition at line 1368 of file imagebuf.h.

void ImageBuf::IteratorBase::operator++ ( int  )
inline

Increment to the next pixel in the region.

Definition at line 1393 of file imagebuf.h.

void ImageBuf::IteratorBase::pos ( int  x_,
int  y_,
int  z_ = 0 
)
inline

Explicitly point the iterator. This results in an invalid iterator if outside the previously-designated region.

Definition at line 1321 of file imagebuf.h.

void ImageBuf::IteratorBase::pos_done ( )
inlineprotected

Definition at line 1517 of file imagebuf.h.

OIIO_FORCEINLINE void ImageBuf::IteratorBase::pos_xincr ( )
inlineprotected

Definition at line 1480 of file imagebuf.h.

ROI ImageBuf::IteratorBase::range ( ) const
inline

Return the iteration range.

Definition at line 1396 of file imagebuf.h.

void ImageBuf::IteratorBase::range_is_image ( )
inlineprotected

Definition at line 1467 of file imagebuf.h.

void OIIO_API ImageBuf::IteratorBase::release_tile ( )
protected
void ImageBuf::IteratorBase::rerange ( int  xbegin,
int  xend,
int  ybegin,
int  yend,
int  zbegin,
int  zend,
WrapMode  wrap = WrapDefault 
)
inline

Reset the iteration range for this iterator and reposition to the beginning of the range, but keep referring to the same image.

Definition at line 1405 of file imagebuf.h.

bool ImageBuf::IteratorBase::valid ( ) const
inline

Is the current location within the designated iteration range?

Definition at line 1278 of file imagebuf.h.

bool ImageBuf::IteratorBase::valid ( int  x_,
int  y_,
int  z_ = 0 
) const
inline

Is the location (x,y[,z]) within the designated iteration range?

Definition at line 1282 of file imagebuf.h.

WrapMode ImageBuf::IteratorBase::wrap ( ) const
inline

Return the wrap mode.

Definition at line 1317 of file imagebuf.h.

int ImageBuf::IteratorBase::x ( ) const
inline

Retrieve the current x location of the iterator.

Definition at line 1269 of file imagebuf.h.

int ImageBuf::IteratorBase::y ( ) const
inline

Retrieve the current y location of the iterator.

Definition at line 1272 of file imagebuf.h.

int ImageBuf::IteratorBase::z ( ) const
inline

Retrieve the current z location of the iterator.

Definition at line 1275 of file imagebuf.h.

Friends And Related Function Documentation

friend class ImageBuf
friend

Definition at line 1422 of file imagebuf.h.

friend class ImageBufImpl
friend

Definition at line 1423 of file imagebuf.h.

Member Data Documentation

bool ImageBuf::IteratorBase::m_deep = false
protected

Definition at line 1426 of file imagebuf.h.

bool ImageBuf::IteratorBase::m_exists = false
protected

Definition at line 1425 of file imagebuf.h.

const ImageBuf* ImageBuf::IteratorBase::m_ib = nullptr
protected

Definition at line 1424 of file imagebuf.h.

int ImageBuf::IteratorBase::m_img_xbegin
protected

Definition at line 1429 of file imagebuf.h.

int ImageBuf::IteratorBase::m_img_xend
protected

Definition at line 1429 of file imagebuf.h.

int ImageBuf::IteratorBase::m_img_ybegin
protected

Definition at line 1429 of file imagebuf.h.

int ImageBuf::IteratorBase::m_img_yend
protected

Definition at line 1429 of file imagebuf.h.

int ImageBuf::IteratorBase::m_img_zbegin
protected

Definition at line 1429 of file imagebuf.h.

int ImageBuf::IteratorBase::m_img_zend
protected

Definition at line 1429 of file imagebuf.h.

bool ImageBuf::IteratorBase::m_localpixels = false
protected

Definition at line 1427 of file imagebuf.h.

int ImageBuf::IteratorBase::m_nchannels
protected

Definition at line 1438 of file imagebuf.h.

stride_t ImageBuf::IteratorBase::m_pixel_stride
protected

Definition at line 1439 of file imagebuf.h.

char* ImageBuf::IteratorBase::m_proxydata = nullptr
protected

Definition at line 1440 of file imagebuf.h.

int ImageBuf::IteratorBase::m_rng_xbegin
protected

Definition at line 1432 of file imagebuf.h.

int ImageBuf::IteratorBase::m_rng_xend
protected

Definition at line 1432 of file imagebuf.h.

int ImageBuf::IteratorBase::m_rng_ybegin
protected

Definition at line 1432 of file imagebuf.h.

int ImageBuf::IteratorBase::m_rng_yend
protected

Definition at line 1432 of file imagebuf.h.

int ImageBuf::IteratorBase::m_rng_zbegin
protected

Definition at line 1432 of file imagebuf.h.

int ImageBuf::IteratorBase::m_rng_zend
protected

Definition at line 1432 of file imagebuf.h.

pvt::ImageCacheTile* ImageBuf::IteratorBase::m_tile = nullptr
protected

Definition at line 1435 of file imagebuf.h.

int ImageBuf::IteratorBase::m_tilexbegin
protected

Definition at line 1436 of file imagebuf.h.

int ImageBuf::IteratorBase::m_tilexend
protected

Definition at line 1437 of file imagebuf.h.

int ImageBuf::IteratorBase::m_tileybegin
protected

Definition at line 1436 of file imagebuf.h.

int ImageBuf::IteratorBase::m_tilezbegin
protected

Definition at line 1436 of file imagebuf.h.

bool ImageBuf::IteratorBase::m_valid = false
protected

Definition at line 1425 of file imagebuf.h.

WrapMode ImageBuf::IteratorBase::m_wrap = WrapBlack
protected

Definition at line 1441 of file imagebuf.h.

int ImageBuf::IteratorBase::m_x
protected

Definition at line 1434 of file imagebuf.h.

int ImageBuf::IteratorBase::m_y
protected

Definition at line 1434 of file imagebuf.h.

int ImageBuf::IteratorBase::m_z
protected

Definition at line 1434 of file imagebuf.h.


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