You've already forked libopenshot
mirror of
https://github.com/OpenShot/libopenshot.git
synced 2026-03-02 08:53:52 -08:00
Fixing a bug with Frame::AddImage (convertToFormat) not actually doing anything. It returns a new image, and does not convert the format in-place.
This commit is contained in:
@@ -739,7 +739,7 @@ void Frame::AddImage(int new_width, int new_height, int bytes_per_pixel, QImage:
|
||||
|
||||
// Always convert to RGBA8888 (if different)
|
||||
if (image->format() != QImage::Format_RGBA8888)
|
||||
image->convertToFormat(QImage::Format_RGBA8888);
|
||||
*image = image->convertToFormat(QImage::Format_RGBA8888);
|
||||
|
||||
// Update height and width
|
||||
width = image->width();
|
||||
@@ -763,7 +763,7 @@ void Frame::AddImage(std::shared_ptr<QImage> new_image)
|
||||
|
||||
// Always convert to RGBA8888 (if different)
|
||||
if (image->format() != QImage::Format_RGBA8888)
|
||||
image->convertToFormat(QImage::Format_RGBA8888);
|
||||
*image = image->convertToFormat(QImage::Format_RGBA8888);
|
||||
|
||||
// Update height and width
|
||||
width = image->width();
|
||||
|
||||
Reference in New Issue
Block a user