#include <pxl_imagewritable.h>

Public Member Functions | |
| virtual u8 * | getWritableBufferPtr (ssize_t *outRowStride, const Rect &inRect, bool inPreload=false)=0 |
| virtual void | write (const Rect &inRect, const void *inFirstLinePtr, ssize_t inRowStride)=0 |
| virtual void | flush ()=0 |
Definition at line 27 of file pxl_imagewritable.h.
| virtual u8* Celartem::ImageWriteLock::getWritableBufferPtr | ( | ssize_t * | outRowStride, | |
| const Rect & | inRect, | |||
| bool | inPreload = false | |||
| ) | [pure virtual] |
This method acquires the pointer to the raw data of the specified rectangle. You can access the raw data until the next any write or read access to the same ImageWriteLock instance. In some case, you want to reflect the changes immediately after your operations, then you can call flush method for that purpose.
| outRowStride | Pointer to the buffer that receives the row stride. | |
| inRect | This parameter specifies a portion to write/read. | |
| inPreload | If the value is false (the default), this function may not reflect the real raw data to the buffer returned; the buffer pointed by the returned pointer may be not initialized and you can not read any effective image data from that.If the value is true, you can read the effective raw data from the buffer. With some type of Image implementation, it may take some time to load the image to the buffer.If you don't have to see the original image, you had better let the value false (the default). |
| virtual void Celartem::ImageWriteLock::write | ( | const Rect & | inRect, | |
| const void * | inFirstLinePtr, | |||
| ssize_t | inRowStride | |||
| ) | [pure virtual] |
This method writes the specified data directly to the internal buffer.
| inRect | This parameter specifies a portion to write/read. | |
| inFirstLinePtr | Pointer to the first line of the image data. For bottom-up images, it is not identical to the pointer to the memory block. See Accessing to Raster Image Data for more information. | |
| inRowStride | The number of bytes to be skipped to go to the next line. It could be a negative value and then the image is regarded as bottom-upped. |
| virtual void Celartem::ImageWriteLock::flush | ( | ) | [pure virtual] |
This method enforces any pending getWritableBufferPtr write operations.