}
//kDebug()<<"// DURATION DIFF: "<<durationDiff.frames(25)<<", POS: "<<pos().x();
m_info.startPos += durationDiff;
- GenTime originalDiff = GenTime((int)(durationDiff.frames(m_fps) * speed + 0.5), m_fps);
+ GenTime originalDiff = GenTime((int)(durationDiff.frames(m_fps) * speed), m_fps);
if (type() == AVWIDGET) {
m_info.cropStart += durationDiff;
if ((int) scenePos().x() != posx) {
//kDebug()<<"////// WARNING, DIFF IN XPOS: "<<pos().x()<<" == "<<m_startPos.frames(m_fps);
GenTime diff = GenTime((int) pos().x() - posx, m_fps);
- GenTime originalDiff = GenTime((int)(diff.frames(m_fps) * speed + 0.5), m_fps);
+ GenTime originalDiff = GenTime((int)(diff.frames(m_fps) * speed), m_fps);
+
if (type() == AVWIDGET) {
m_info.cropStart += diff;
m_info.originalcropStart += originalDiff;
{
GenTime durationDiff = GenTime(posx, m_fps) - endPos();
if (durationDiff == GenTime()) return;
- //kDebug() << "// DUR DIFF1:" << durationDiff.frames(25) << ", ADJUSTED: " << durationDiff.frames(25) * speed << ", SPED:" << speed;
if (cropDuration() + durationDiff <= GenTime()) {
durationDiff = GenTime() - (cropDuration() - GenTime(3, m_fps));
}
- //kDebug() << "// DUR DIFF2:" << durationDiff.frames(25) << ", ADJUSTED: " << durationDiff.frames(25) * speed << ", SPED:" << speed;
- m_info.cropDuration += GenTime((int)(durationDiff.frames(m_fps) * speed + 0.5), m_fps);
+
+ m_info.cropDuration += GenTime((int)(durationDiff.frames(m_fps) * speed), m_fps);
+
setRect(0, 0, cropDuration().frames(m_fps) - 0.02, rect().height());
if (durationDiff > GenTime()) {
QList <QGraphicsItem *> collisionList = collidingItems(Qt::IntersectsItemBoundingRect);
kDebug() << "///////// CURRENT: " << startPos().frames(25) << "x" << endPos().frames(25) << ", RECT: " << rect() << "-" << pos();
kDebug() << "///////// COLLISION: " << ((AbstractClipItem *)item)->startPos().frames(25) << "x" << ((AbstractClipItem *)item)->endPos().frames(25) << ", RECT: " << ((AbstractClipItem *)item)->rect() << "-" << item->pos();*/
GenTime diff = ((AbstractClipItem *)item)->startPos() - GenTime(1, m_fps) - startPos();
- m_info.cropDuration = GenTime((int)(diff.frames(m_fps) * speed + 0.5), m_fps);
+ m_info.cropDuration = GenTime((int)(diff.frames(m_fps) * speed), m_fps);
setRect(0, 0, cropDuration().frames(m_fps) - 0.02, rect().height());
break;
}
if (posx > max && maxDuration() != GenTime()) posx = max;
if (posx == endPos().frames(m_fps)) return;
//kDebug() << "// NEW POS: " << posx << ", OLD END: " << endPos().frames(m_fps);
- const int previous = (int)(cropStart() + cropDuration()).frames(m_fps) - 1;
+ const int previous = cropDuration().frames(m_fps);
AbstractClipItem::resizeEnd(posx, m_speed);
- const int current = (int)(cropStart() + cropDuration()).frames(m_fps) - 1;
- if (current != previous) {
+ if ((int) cropDuration().frames(m_fps) != previous) {
if (m_hasThumbs && KdenliveSettings::videothumbnails()) {
/*connect(m_clip->thumbProducer(), SIGNAL(thumbReady(int, QPixmap)), this, SLOT(slotThumbReady(int, QPixmap)));*/
m_endThumbTimer.start(150);