C

QSafeBitmapBuffer Class

class SafeRenderer::QSafeBitmapBuffer

The QSafeBitmapBuffer class holds the bitmap data. More...

Header: #include <QSafeBitmapBuffer>
Since: QtSafeRenderer 1.0
Inherits: SafeRenderer::QSafeBitmap
Inherited By:

SafeRenderer::QSafeTextLayout

This class was introduced in QtSafeRenderer 1.0.

Public Types

enum BitmapExceptions { OutOfDataCache }

Public Functions

QSafeBitmapBuffer()
void reserveBitmapBuffer(const SafeRenderer::quint32 sizeArgInBytes)

Reimplemented Public Functions

virtual const SafeRenderer::ARGB *scanline(const SafeRenderer::quint32 pixelRow) const override

Detailed Description

The QSafeBitmapBuffer holds the data of a bitmap file. Memory for the bitmap data is statically reserved. The maximum size of the bitmap file can be changed in qsafeconstraints.h. The variable is SafeRenderer::Constraints::MAX_IMAGE_PIXELS.

Member Type Documentation

enum QSafeBitmapBuffer::BitmapExceptions

This enum describes the exception values of the class QSafeBitmapBuffer

ConstantValueDescription
SafeRenderer::QSafeBitmapBuffer::OutOfDataCache0The total bitmap data size exceeds SafeRenderer::Constraints::MEMORY_POOL_SIZE.

Member Function Documentation

QSafeBitmapBuffer::QSafeBitmapBuffer()

Constructs a QSafeBitmapBuffer object.

void QSafeBitmapBuffer::reserveBitmapBuffer(const SafeRenderer::quint32 sizeArgInBytes)

Reserves a bitmap buffer with size sizeArgInBytes. The bitmap index to the buffer is adjusted so that the underlying address in memory is aligned to 4 byte boundary for safe access via quint32 pointer during blitting the bitmap.

This function was introduced in QtSafeRenderer 1.1.

[override virtual] const SafeRenderer::ARGB *QSafeBitmapBuffer::scanline(const SafeRenderer::quint32 pixelRow) const

Reimplements: QSafeBitmap::scanline(const SafeRenderer::quint32 pixelRow) const.

Getter for a bitmap row. Returns the pointer to the start of bitmap's pixelRow row or NULL if pixelRow is out of range.

Available under certain Qt licenses.
Find out more.