video_stream->clear_queue();
lock.lock();
}
+ got_next_clip = false;
goto wait_for_clip;
}
if (override_stream_idx != -1) {
if (in_pts_lower == in_pts_upper) {
auto display_func = [this, primary_stream_idx, in_pts_lower, secondary_stream_idx, secondary_pts, fade_alpha]{
- destination->setFrame(primary_stream_idx, in_pts_lower, /*interpolated=*/false, secondary_stream_idx, secondary_pts, fade_alpha);
+ destination->setFrame(primary_stream_idx, in_pts_lower, secondary_stream_idx, secondary_pts, fade_alpha);
};
if (video_stream == nullptr) {
display_func();
next_frame_start, pts, display_func, QueueSpotHolder(this),
primary_stream_idx, in_pts_lower);
} else {
+ assert(secondary_pts != -1);
video_stream->schedule_faded_frame(next_frame_start, pts, display_func,
QueueSpotHolder(this), primary_stream_idx, in_pts_lower,
secondary_stream_idx, secondary_pts, fade_alpha);
double snap_pts_as_frameno = (snap_pts - in_pts_origin) * output_framerate / TIMEBASE / speed;
if (fabs(snap_pts_as_frameno - frameno) < 0.01) {
auto display_func = [this, primary_stream_idx, snap_pts, secondary_stream_idx, secondary_pts, fade_alpha]{
- destination->setFrame(primary_stream_idx, snap_pts, /*interpolated=*/false, secondary_stream_idx, secondary_pts, fade_alpha);
+ destination->setFrame(primary_stream_idx, snap_pts, secondary_stream_idx, secondary_pts, fade_alpha);
};
if (video_stream == nullptr) {
display_func();
next_frame_start, pts, display_func,
QueueSpotHolder(this), primary_stream_idx, snap_pts);
} else {
+ assert(secondary_pts != -1);
video_stream->schedule_faded_frame(
next_frame_start, pts, display_func, QueueSpotHolder(this),
primary_stream_idx, snap_pts, secondary_stream_idx, secondary_pts, fade_alpha);
if (video_stream == nullptr) {
// Previews don't do any interpolation.
assert(secondary_stream_idx == -1);
- destination->setFrame(primary_stream_idx, in_pts_lower, /*interpolated=*/false);
+ destination->setFrame(primary_stream_idx, in_pts_lower);
} else {
- auto display_func = [this, primary_stream_idx, pts, secondary_stream_idx, secondary_pts, fade_alpha]{
- destination->setFrame(primary_stream_idx, pts, /*interpolated=*/true, secondary_stream_idx, secondary_pts, fade_alpha);
+ auto display_func = [this](shared_ptr<Frame> frame) {
+ destination->setFrame(frame);
};
video_stream->schedule_interpolated_frame(
next_frame_start, pts, display_func, QueueSpotHolder(this),
if (it == frames[stream_idx].end()) {
return;
}
- destination->setFrame(stream_idx, *it, /*interpolated=*/false);
+ destination->setFrame(stream_idx, *it);
}
void Player::take_queue_spot()