implemented base transition support
While very much incomplete, transitions can now be created and will render correctly.
This commit is contained in:
@@ -22,6 +22,8 @@
|
||||
|
||||
#include <QDebug>
|
||||
|
||||
#include "transition/transition.h"
|
||||
|
||||
Block::Block() :
|
||||
previous_(nullptr),
|
||||
next_(nullptr)
|
||||
@@ -159,8 +161,16 @@ rational Block::MediaToSequenceTime(const rational &media_time) const
|
||||
void Block::CopyParameters(const Block *source, Block *dest)
|
||||
{
|
||||
dest->set_block_name(source->block_name());
|
||||
dest->set_length(source->length());
|
||||
dest->set_media_in(source->media_in());
|
||||
|
||||
if (source->type() == kTransition && dest->type() == kTransition) {
|
||||
const TransitionBlock* src_t = static_cast<const TransitionBlock*>(source);
|
||||
TransitionBlock* dst_t = static_cast<TransitionBlock*>(dest);
|
||||
|
||||
dst_t->set_in_and_out_offset(src_t->in_offset(), src_t->out_offset());
|
||||
} else {
|
||||
dest->set_length(source->length());
|
||||
}
|
||||
}
|
||||
|
||||
void Block::Link(Block *a, Block *b)
|
||||
|
||||
Reference in New Issue
Block a user