You've already forked libopenshot
mirror of
https://github.com/OpenShot/libopenshot.git
synced 2026-03-02 08:53:52 -08:00
Added a new experimental overlay method to a frame, which composites images from multiple frames, and adds the result to the bottom right side of the image.
This commit is contained in:
@@ -502,6 +502,22 @@ void Frame::AddEffect(string name)
|
||||
image->swirl(30.0);
|
||||
}
|
||||
|
||||
// Experimental method to add overlay images to this frame
|
||||
void Frame::AddOverlay(Frame* frame)
|
||||
{
|
||||
// Get overlay image (if any)
|
||||
Magick::Image* overlay = frame->GetImage();
|
||||
|
||||
// Composite image onto this image
|
||||
image->composite(*overlay, Magick::SouthEastGravity, Magick::OverCompositeOp);
|
||||
}
|
||||
|
||||
// Get pointer to Magick++ image object
|
||||
Magick::Image* Frame::GetImage()
|
||||
{
|
||||
return image;
|
||||
}
|
||||
|
||||
// Play audio samples for this frame
|
||||
void Frame::Play()
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user