示例#1
0
 bool Lock(uint8_t** data, gfx::IntSize* size, int32_t* stride,
           gfx::SurfaceFormat* format)
 {
     bool success = mDT->LockBits(data, size, stride, format);
     if (success)
         mLockedBits = *data;
     return success;
 }
示例#2
0
    bool Lock(uint8_t** data, gfx::IntSize* size, int32_t* stride,
              gfx::SurfaceFormat* format)
    {
        if (!mDT->LockBits(data, size, stride, format))
            return false;

        mLockedBits = *data;
        return true;
    }
示例#3
0
 ~AutoLockBits() {
     if (mLockedBits)
         mDT->ReleaseBits(mLockedBits);
 }