From 935762506d75418ab360b96709759a51d27ca34a Mon Sep 17 00:00:00 2001 From: Bruno Date: Tue, 16 Feb 2021 22:50:15 +0100 Subject: [PATCH] Bugfix: frae grabber should be called in Mixer Grab frames in session update fails with SessionSource and SessionGroups. --- FrameGrabber.h | 2 +- Mixer.cpp | 3 +++ Session.cpp | 3 --- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/FrameGrabber.h b/FrameGrabber.h index 254f178..5144677 100644 --- a/FrameGrabber.h +++ b/FrameGrabber.h @@ -80,7 +80,7 @@ protected: */ class FrameGrabbing { - friend class Session; + friend class Mixer; // Private Constructor FrameGrabbing(); diff --git a/Mixer.cpp b/Mixer.cpp index 8b15c74..690aef4 100644 --- a/Mixer.cpp +++ b/Mixer.cpp @@ -209,6 +209,9 @@ void Mixer::update() // update session and associated sources session_->update(dt_); + // grab frames to recorders & streamers + FrameGrabbing::manager().grabFrame(session_->frame(), dt_); + // delete sources which failed update (one by one) Source *failure = session()->failedSource(); if (failure != nullptr) { diff --git a/Session.cpp b/Session.cpp index c05389c..10c9020 100644 --- a/Session.cpp +++ b/Session.cpp @@ -99,9 +99,6 @@ void Session::update(float dt) // draw render view in Frame Buffer render_.draw(); - // grab frames to recorders & streamers - FrameGrabbing::manager().grabFrame(render_.frame(), dt); - }