VOIP in SDK...
Trying to get the VOIP working by using some c++ from the SDK sample. I'm not too familiar with c++, so it is just a bit of a hack job. I use blueprint to create and join a session, then I've created a BlueprintCallable function that I call in the player controller. Here is the meat of the .cpp (straight from SDK sample):
<CODE>
<CODE>
void UOSSSessionBP::StartVoip(FName SessionName)
{
auto OculusSessionInterface = Online::GetSessionInterface();
auto OculusVoiceInterface = Online::GetVoiceInterface();
auto OculusIdentityInterface = Online::GetIdentityInterface();
auto Session = OculusSessionInterface->GetNamedSession(SessionName);
auto UserId = OculusIdentityInterface->GetUniquePlayerId(0);
if (Session)
{
OculusSessionInterface->StartSession(SessionName);//
auto RegisteredPlayers = Session->RegisteredPlayers; //get list of players in the session
for (auto RegisteredPlayer : RegisteredPlayers)
{
//don't register the local player, only the remote
if (RegisteredPlayer.Get() != *UserId.Get())
{
OculusVoiceInterface->RegisterRemoteTalker(RegisteredPlayer.Get());
OculusVoiceInterface->StartNetworkedVoice(0);
UE_LOG_ONLINE(Display, TEXT("Registered a Talker: %s"), *RegisteredPlayer.Get().ToString());
}
}
}
}
</CODE>
Problem is, I don't know how to get the SessionName. Since I create the session using blueprints, I don't know what name it is given or how to get at it. Any suggestions in getting the SessionName or alternate ways to get an array of FUniqueNetIdOculus?
</CODE>
Problem is, I don't know how to get the SessionName. Since I create the session using blueprints, I don't know what name it is given or how to get at it. Any suggestions in getting the SessionName or alternate ways to get an array of FUniqueNetIdOculus?
