2020-09-10 21:14:28 +08:00
|
|
|
#pragma once
|
|
|
|
#include "base/CCData.h"
|
|
|
|
|
|
|
|
#include "Macros.h"
|
|
|
|
#include "Types.h"
|
|
|
|
|
|
|
|
CC_BACKEND_BEGIN
|
|
|
|
|
|
|
|
struct PixelBufferDescriptor
|
|
|
|
{
|
|
|
|
PixelBufferDescriptor() = default;
|
|
|
|
PixelBufferDescriptor(const PixelBufferDescriptor&) = default;
|
|
|
|
PixelBufferDescriptor(PixelBufferDescriptor&& rhs) : _data(std::move(rhs._data)), _width(rhs._width), _height(rhs._height) {
|
|
|
|
|
|
|
|
}
|
2020-09-10 21:38:24 +08:00
|
|
|
|
|
|
|
explicit operator bool() const { return !_data.isNull(); }
|
|
|
|
|
2020-09-10 21:14:28 +08:00
|
|
|
Data _data;
|
|
|
|
int _width;
|
|
|
|
int _height;
|
|
|
|
};
|
|
|
|
|
|
|
|
CC_BACKEND_END
|