去掉QT里面对BGR888格式的支持,因为有的qt版本不支持
This commit is contained in:
parent
e7c04c77db
commit
4f60853960
|
@ -3489,8 +3489,6 @@ QImage* HGImgThumb::createItemImage(HGImage srcImage, int itemSize)
|
||||||
fmt = QImage::Format_RGB888;
|
fmt = QImage::Format_RGB888;
|
||||||
else if (info.type == HGBASE_IMGTYPE_RGBA)
|
else if (info.type == HGBASE_IMGTYPE_RGBA)
|
||||||
fmt = QImage::Format_RGBA8888;
|
fmt = QImage::Format_RGBA8888;
|
||||||
else if (info.type == HGBASE_IMGTYPE_BGR)
|
|
||||||
fmt = QImage::Format_BGR888;
|
|
||||||
if (QImage::Format_Invalid == fmt)
|
if (QImage::Format_Invalid == fmt)
|
||||||
{
|
{
|
||||||
return nullptr;
|
return nullptr;
|
||||||
|
|
|
@ -1999,8 +1999,6 @@ QImage* HGImgView::createQImage()
|
||||||
fmt = QImage::Format_RGB888;
|
fmt = QImage::Format_RGB888;
|
||||||
else if (info.type == HGBASE_IMGTYPE_RGBA)
|
else if (info.type == HGBASE_IMGTYPE_RGBA)
|
||||||
fmt = QImage::Format_RGBA8888;
|
fmt = QImage::Format_RGBA8888;
|
||||||
else if (info.type == HGBASE_IMGTYPE_BGR)
|
|
||||||
fmt = QImage::Format_BGR888;
|
|
||||||
if (QImage::Format_Invalid == fmt)
|
if (QImage::Format_Invalid == fmt)
|
||||||
{
|
{
|
||||||
return nullptr;
|
return nullptr;
|
||||||
|
|
|
@ -2700,8 +2700,6 @@ void MainWindow::on_act_imageEdit_triggered()
|
||||||
fmt = QImage::Format_RGB888;
|
fmt = QImage::Format_RGB888;
|
||||||
else if (info.type == HGBASE_IMGTYPE_RGBA)
|
else if (info.type == HGBASE_IMGTYPE_RGBA)
|
||||||
fmt = QImage::Format_RGBA8888;
|
fmt = QImage::Format_RGBA8888;
|
||||||
else if (info.type == HGBASE_IMGTYPE_BGR)
|
|
||||||
fmt = QImage::Format_BGR888;
|
|
||||||
if (QImage::Format_Invalid == fmt)
|
if (QImage::Format_Invalid == fmt)
|
||||||
{
|
{
|
||||||
return;
|
return;
|
||||||
|
@ -2733,8 +2731,6 @@ void MainWindow::on_act_imageEdit_triggered()
|
||||||
info.type = HGBASE_IMGTYPE_RGB;
|
info.type = HGBASE_IMGTYPE_RGB;
|
||||||
else if (QImage::Format_RGBA8888 == image.format())
|
else if (QImage::Format_RGBA8888 == image.format())
|
||||||
info.type = HGBASE_IMGTYPE_RGBA;
|
info.type = HGBASE_IMGTYPE_RGBA;
|
||||||
else if (QImage::Format_BGR888 == image.format())
|
|
||||||
info.type = HGBASE_IMGTYPE_BGR;
|
|
||||||
info.widthStep = (HGUInt)image.bytesPerLine();
|
info.widthStep = (HGUInt)image.bytesPerLine();
|
||||||
info.origin = HGBASE_IMGORIGIN_TOP;
|
info.origin = HGBASE_IMGORIGIN_TOP;
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue