| 698 | } |
| 699 | |
| 700 | void VST3Wrapper::SavePresetToFile(const wxString& filepath) const |
| 701 | { |
| 702 | using namespace Steinberg; |
| 703 | |
| 704 | auto fileStream = owned(Vst::FileStream::open(filepath.c_str(), "wb")); |
| 705 | if(!fileStream) |
| 706 | throw FileException(FileException::Cause::Open, filepath); |
| 707 | |
| 708 | if(!SavePresetToStream(fileStream)) |
| 709 | throw SimpleMessageBoxException( |
| 710 | ExceptionType::BadEnvironment, |
| 711 | XO("Failed to save VST3 preset to file"), |
| 712 | XO("Error")); |
| 713 | } |
| 714 | |
| 715 | |
| 716 | bool VST3Wrapper::LoadPresetFromStream(Steinberg::IBStream* fileStream) |
no test coverage detected