| 57 | } |
| 58 | |
| 59 | bool Bitmap::allocPixels(int width, int height, bool alphaOnly, bool tryHardware) { |
| 60 | pixelRef = PixelRef::Make(width, height, alphaOnly, tryHardware); |
| 61 | if (pixelRef != nullptr) { |
| 62 | _info = pixelRef->info(); |
| 63 | } |
| 64 | return pixelRef != nullptr; |
| 65 | } |
| 66 | |
| 67 | void* Bitmap::lockPixels() { |
| 68 | if (pixelRef == nullptr) { |
no test coverage detected