123456789101112131415161718192021222324252627282930313233343536373839404142434445 |
- #include "PlayerGlobalInfo.h"
- Image_QImage::Image_QImage()
- {
- width = 0;
- height = 0;
- /* 设置为RGB888 */
- image = QImage(1, 1, QImage::Format_RGB888);
- }
- /* 移动构造函数 */
- Image_QImage::Image_QImage(Image_QImage&& other)
- {
- width = other.width;
- height = other.height;
- image = std::move(other.image);
- }
- /* 拷贝构造函数 */
- Image_QImage::Image_QImage(const Image_QImage& other)
- {
- width = other.width;
- height = other.height;
- image = other.image;
- }
- /* 重载= */
- Image_QImage& Image_QImage::operator=(const Image_QImage& other)
- {
- width = other.width;
- height = other.height;
- image = other.image;
- return *this;
- }
- /* 移动幅值函数 */
- void Image_QImage::moveFrom(Image_QImage& other)
- {
- width = other.width;
- height = other.height;
- image = std::move(other.image);
- }
|