From d818cad3c0cb7b2536b7c30196a517f51ce2d873 Mon Sep 17 00:00:00 2001 From: xia-chu <771730766@qq.com> Date: Sun, 12 Mar 2023 09:39:49 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E5=A4=8D=E4=BD=8E=E7=89=88=E6=9C=ACgc?= =?UTF-8?q?c=E7=BC=96=E8=AF=91=E5=99=A8lambda=E4=B8=8D=E6=94=AF=E6=8C=81?= =?UTF-8?q?=E5=8F=AF=E5=8F=98=E9=95=BF=E5=BA=A6=E6=A8=A1=E6=9D=BF=E5=8F=82?= =?UTF-8?q?=E6=95=B0=E6=8D=95=E8=8E=B7=E5=AF=BC=E8=87=B4=E7=9A=84=E7=BC=96?= =?UTF-8?q?=E8=AF=91=E9=97=AE=E9=A2=98:#2295?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- api/source/mk_media.cpp | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/api/source/mk_media.cpp b/api/source/mk_media.cpp index 402546fa..67bcfe30 100755 --- a/api/source/mk_media.cpp +++ b/api/source/mk_media.cpp @@ -19,11 +19,10 @@ using namespace mediakit; class MediaHelper : public MediaSourceEvent , public std::enable_shared_from_this { public: using Ptr = std::shared_ptr; - template - MediaHelper(ArgsType &&...args) { + MediaHelper(const char *vhost, const char *app, const char *stream, float duration, const ProtocolOption &option) { _poller = EventPollerPool::Instance().getPoller(); // 在poller线程中创建DevChannel(MultiMediaSourceMuxer)对象,确保严格的线程安全限制 - _poller->sync([&]() { _channel = std::make_shared(std::forward(args)...); }); + _poller->sync([&]() { _channel = std::make_shared(vhost, app, stream, duration, option); }); } ~MediaHelper() = default;