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;