本文整理汇总了C++中FAkAudioDevice::SetMaxAuxBus方法的典型用法代码示例。如果您正苦于以下问题:C++ FAkAudioDevice::SetMaxAuxBus方法的具体用法?C++ FAkAudioDevice::SetMaxAuxBus怎么用?C++ FAkAudioDevice::SetMaxAuxBus使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类FAkAudioDevice
的用法示例。
在下文中一共展示了FAkAudioDevice::SetMaxAuxBus方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: PostEditChangeProperty
void UAkSettings::PostEditChangeProperty(FPropertyChangedEvent& PropertyChangedEvent)
{
const FName PropertyName = (PropertyChangedEvent.Property != nullptr) ? PropertyChangedEvent.Property->GetFName() : NAME_None;
const FName MemberPropertyName = (PropertyChangedEvent.Property != nullptr) ? PropertyChangedEvent.MemberProperty->GetFName() : NAME_None;
if ( PropertyName == GET_MEMBER_NAME_CHECKED(UAkSettings, MaxSimultaneousReverbVolumes) )
{
MaxSimultaneousReverbVolumes = FMath::Clamp<uint8>( MaxSimultaneousReverbVolumes, 0, AK_MAX_AUX_PER_OBJ );
FAkAudioDevice* AkAudioDevice = FAkAudioDevice::Get();
if( AkAudioDevice )
{
AkAudioDevice->SetMaxAuxBus(MaxSimultaneousReverbVolumes);
}
}
else if (MemberPropertyName == GET_MEMBER_NAME_CHECKED(UAkSettings, WwiseWindowsInstallationPath))
{
WwiseWindowsInstallationPath.Path = WwiseWindowsInstallationPath.Path.Trim();
WwiseWindowsInstallationPath.Path = WwiseWindowsInstallationPath.Path.TrimTrailing();
FText FailReason;
if (!FPaths::ValidatePath(WwiseWindowsInstallationPath.Path, &FailReason))
{
FMessageDialog::Open(EAppMsgType::Ok, FailReason);
WwiseWindowsInstallationPath.Path = PreviousWwiseWindowsPath;
}
if (!FPaths::DirectoryExists(WwiseWindowsInstallationPath.Path))
{
FMessageDialog::Open(EAppMsgType::Ok, FText::FromString("Please enter a valid Wwise Authoring Windows executable path"));
WwiseWindowsInstallationPath.Path = PreviousWwiseWindowsPath;
}
}
else if (MemberPropertyName == GET_MEMBER_NAME_CHECKED(UAkSettings, WwiseMacInstallationPath))
{
WwiseMacInstallationPath.FilePath = WwiseMacInstallationPath.FilePath.Trim();
WwiseMacInstallationPath.FilePath = WwiseMacInstallationPath.FilePath.TrimTrailing();
FText FailReason;
if (!FPaths::ValidatePath(WwiseMacInstallationPath.FilePath, &FailReason))
{
FMessageDialog::Open(EAppMsgType::Ok, FailReason);
WwiseMacInstallationPath.FilePath = PreviousWwiseMacPath;
}
if (!FPaths::DirectoryExists(WwiseMacInstallationPath.FilePath))
{
FMessageDialog::Open(EAppMsgType::Ok, FText::FromString("Please enter a valid Wwise Authoring Mac executable path"));
WwiseMacInstallationPath.FilePath = PreviousWwiseMacPath;
}
}
else if (MemberPropertyName == GET_MEMBER_NAME_CHECKED(UAkSettings, WwiseProjectPath))
{
WwiseProjectPath.FilePath = WwiseProjectPath.FilePath.Trim();
WwiseProjectPath.FilePath = WwiseProjectPath.FilePath.TrimTrailing();
FString TempPath = IFileManager::Get().ConvertToAbsolutePathForExternalAppForWrite(*WwiseProjectPath.FilePath);
FText FailReason;
if (!FPaths::ValidatePath(TempPath, &FailReason))
{
if(EAppReturnType::Ok == FMessageDialog::Open(EAppMsgType::Ok, FailReason))
{
WwiseProjectPath.FilePath = PreviousWwiseProjectPath;
return;
}
}
if (!FPaths::FileExists(TempPath))
{
// Path might be a valid one (relative to game) entered manually. Check that.
TempPath = FPaths::ConvertRelativePathToFull(FPaths::GameDir(), WwiseProjectPath.FilePath);
if (!FPaths::FileExists(TempPath))
{
if (EAppReturnType::Ok == FMessageDialog::Open(EAppMsgType::Ok, FText::FromString("Please enter a valid Wwise project")))
{
WwiseProjectPath.FilePath = PreviousWwiseProjectPath;
return;
}
}
}
// Make the path relative to the game dir
FPaths::MakePathRelativeTo(TempPath, *FPaths::GameDir());
WwiseProjectPath.FilePath = TempPath;
if (WwiseProjectPath.FilePath != PreviousWwiseProjectPath)
{
TSharedRef<SDockTab> WwisePickerTab = FGlobalTabmanager::Get()->InvokeTab(FName("WwisePicker"));
bRequestRefresh = true;
}
}
Super::PostEditChangeProperty(PropertyChangedEvent);
}