Пример #1
0
int wf_wasapi_activate(RdpsndServerContext* context)
{
	wchar_t * pattern = L"Stereo Mix";

	wf_wasapi_get_device_string(pattern, &devStr);

	if (devStr == NULL)
	{
		_tprintf(_T("Failed to match for output device! Disabling rdpsnd.\n"));
		return 1;
	}

	printf("RDPSND (WASAPI) Activated\n");

	CreateThread(NULL, 0, wf_rdpsnd_wasapi_thread, latestPeer, 0, NULL);

	return 0;
}
Пример #2
0
int wf_wasapi_activate(RdpsndServerContext* context)
{
	wchar_t * pattern = L"Stereo Mix";
	HANDLE hThread;

	wf_wasapi_get_device_string(pattern, &devStr);

	if (devStr == NULL)
	{
		WLog_ERR(TAG, "Failed to match for output device! Disabling rdpsnd.");
		return 1;
	}

	WLog_DBG(TAG, "RDPSND (WASAPI) Activated");
	if (!(hThread = CreateThread(NULL, 0, wf_rdpsnd_wasapi_thread, latestPeer, 0, NULL)))
	{
		WLog_ERR(TAG, "CreateThread failed");
		return 1;
	}
	CloseHandle(hThread);

	return 0;
}