예제 #1
0
	AutotrainerSipCall::AutotrainerSipCall(iCore::MsgThread &thread,
		iLogW::ILogSessionCreator &logCreator,
		boost::function<void (T *)> deleter,
		Utils::SafeRef<IRemoteParticipant> remoteParticipant,
		const Commands &commands) :
		iCore::MsgObject(thread),
		m_timer(this, &T::OnTimeout),
		m_log(logCreator.CreateSession(CallName(), true)),
		m_infoTag(m_log->RegisterRecordKind(L"Info", true)),
		m_deleter(deleter),
		m_callDeleted(false),
		m_commands(commands),
		m_remoteParticipant(remoteParticipant)
	{
		// Incoming call

		ESS_ASSERT(!m_commands.empty());

		if (m_log->LogActive(m_infoTag))
		{
			*m_log << m_infoTag << "Created." << iLogW::EndRecord;
		}

		m_remoteParticipant->LinkUser(this);
		
		CreateMedia();

		PutMsg(this, &T::OnCommand);
	}
예제 #2
0
void HistoryMessage::setMedia(const MTPMessageMedia &media) {
	_media = CreateMedia(this, media);
	if (const auto invoice = _media ? _media->invoice() : nullptr) {
		if (invoice->receiptMsgId) {
			replaceBuyWithReceiptInMarkup();
		}
	}
}
PVMFNodeInterface* PV2WayDummyInputMIONodeFactory::Create(LipSyncDummyMIOSettings& aSettings)
{
    CreateMedia(aSettings);
    PVMFNodeInterface* mioNode = NULL;
    int error = 0;
    OSCL_TRY(error, mioNode = PvmfMediaInputNodeFactory::Create(iMediaControl));
    return mioNode;
}
예제 #4
0
static Comp::Media* CreateMedia(const char* fpath, TempObjs& t_opts)
{
    bool is_movie;
    Comp::Media* md = CreateMedia(fpath, is_movie);
    if( is_movie )
        t_opts.SetBaseMovie(static_cast<Comp::MovieMedia*>(md));

    if( !md )
        Error("Cant open one of source files!");
    return md;
}