开发者

QImage and its const bits() const method

Qt's QImage has two methods:

uchar* QImage::bits();
const uchar* QImage::bits() const;

But how to 开发者_运维技巧call a second one? Calling

const uchar* p = image.bits();

Will call a non-const version O_O.


const QImage* im = ℑ
const uchar* p = im->bits();

will use the const version.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜