27 #include "../raster/BandProperty.h" 
   39   m_blocksManager( blocksManager )
 
   60   m_blocksManager( dummyBlocksManager )
 
   78   m_setGetBlkX = c / m_blkWidth;
 
   79   m_setGetBlkY = r / m_blkHeight;
 
   80   m_setGetPos = c % m_blkWidth + ((r % m_blkHeight) * m_blkWidth);
 
   81   assert(m_setGetPos < ( m_blkWidth * m_blkHeight ) );
 
   82   m_setGetBufPtr = m_blocksManager.getBlockPointer( m_idx, m_setGetBlkX, 
 
   84   m_getBuff(m_setGetPos, m_setGetBufPtr, &value );
 
   89   m_setGetBlkX = c / m_blkWidth;
 
   90   m_setGetBlkY = r / m_blkHeight;
 
   91   m_setGetPos = c % m_blkWidth + ((r % m_blkHeight) * m_blkWidth);
 
   92   assert(m_setGetPos < ( m_blkWidth * m_blkHeight ) );
 
   93   m_setGetBufPtr = m_blocksManager.getBlockPointer( m_idx, m_setGetBlkX, 
 
   95   m_setBuff(m_setGetPos, m_setGetBufPtr, &value );
 
  100   m_setGetBlkX = c / m_blkWidth;
 
  101   m_setGetBlkY = r / m_blkHeight;
 
  102   m_setGetPos = c % m_blkWidth + ((r % m_blkHeight) * m_blkWidth);
 
  103   assert(m_setGetPos < ( m_blkWidth * m_blkHeight ) );
 
  104   m_setGetBufPtr = m_blocksManager.getBlockPointer( m_idx, m_setGetBlkX, 
 
  106   m_getBuffI(m_setGetPos, m_setGetBufPtr, &value );
 
  111   m_setGetBlkX = c / m_blkWidth;
 
  112   m_setGetBlkY = r / m_blkHeight;
 
  113   m_setGetPos = c % m_blkWidth + ((r % m_blkHeight) * m_blkWidth);
 
  114   assert(m_setGetPos < ( m_blkWidth * m_blkHeight ) );
 
  115   m_setGetBufPtr = m_blocksManager.getBlockPointer( m_idx, m_setGetBlkX, 
 
  117   m_setBuffI(m_setGetPos, m_setGetBufPtr, &value );
 
  122   assert( m_blocksManager.isInitialized() );
 
  123   memcpy( buffer, m_blocksManager.getBlockPointer( m_idx, x, y ),
 
  129   assert( m_blocksManager.isInitialized() );
 
  130   return m_blocksManager.getBlockPointer( m_idx, x, y );  
 
  135   assert( m_blocksManager.isInitialized() );
 
  136   memcpy( m_blocksManager.getBlockPointer( m_idx, x, y ), buffer,
 
An adapter class to allow concurrent access to raster data by multiple threads. 
 
A raster band description. 
 
te::rst::SetBufferValueFPtr m_setBuff
A pointer to a function that helps to insert a double or complex value into a specific buffer data ty...
 
virtual const Band * getBand(std::size_t i) const =0
Returns the raster i-th band. 
 
te::rst::GetBufferValueFPtr m_getBuff
A pointer to a function that helps to extract a double or complex value from a specific buffer data t...
 
te::rst::SetBufferValueFPtr m_setBuffI
A pointer to a function that helps to insert the imaginary part value into a specific buffer data typ...
 
te::rst::GetBufferValueFPtr m_getBuffI
A pointer to a function that helps to extract the imaginary part value from a specific buffer data ty...
 
unsigned int m_blkHeight
The current band blocks height. 
 
void read(int x, int y, void *buffer) const 
It reads a data block to the specified buffer. 
 
boost::mutex m_mutex
General sync mutex;. 
 
void write(int x, int y, void *buffer)
It writes a data block from the specified buffer. 
 
Syncrhonized raster band. 
 
unsigned int m_blkWidth
The current band blocks width. 
 
void getValue(unsigned int c, unsigned int r, double &value) const 
Returns the cell attribute value. 
 
static SynchronizedBandBlocksManager dummyBlocksManager
A global static dummy blocks manager. 
 
void setValue(unsigned int c, unsigned int r, const double value)
Sets the cell attribute value. 
 
BandProperty * getProperty()
Returns the band property. 
 
int m_blkw
Block width (pixels). 
 
te::rst::Raster * getRaster() const 
Returns the associated raster. 
 
A raster band description. 
 
Synchronized raster raster band blocks manager. 
 
unsigned int m_blkSizeBytes
The blocks size (bytes);. 
 
SynchronizedRaster * m_syncRasterPtr
The synchronized raster instance (parent raster). 
 
RasterSynchronizer * getSynchronizer() const 
Return a pointer to the assotiated synchronizer instance or NULL if there is none. 
 
void setIValue(unsigned int c, unsigned int r, const double value)
Sets the imaginary attribute value in a complex band of a cell. 
 
int getType() const 
It returns the data type of the elements in the band. 
 
int m_blkh
Block height (pixels). 
 
void getIValue(unsigned int c, unsigned int r, double &value) const 
Returns the imaginary attribute value in a complex band of a cell. 
 
virtual int getBlockSize() const 
It returns the number of bytes ocuppied by a data block. 
 
TERASTEREXPORT void SetBlockFunctions(GetBufferValueFPtr *gb, GetBufferValueFPtr *gbi, SetBufferValueFPtr *sb, SetBufferValueFPtr *sbi, int type)
Sets the pointers to functions that helps to extract a double or complex value from a specific buffer...
 
BandProperty * m_property
The band information.