Fix vc++ compilation
This commit is contained in:
parent
bf03904fb8
commit
bffbae0ed9
7 changed files with 50 additions and 36 deletions
|
@ -124,6 +124,7 @@
|
|||
<ClInclude Include="$(SrcDir)audio_karaoke.h" />
|
||||
<ClInclude Include="$(SrcDir)audio_marker.h" />
|
||||
<ClInclude Include="$(SrcDir)audio_player_portaudio.h" />
|
||||
<ClInclude Include="$(SrcDir)audio_provider_factory.h" />
|
||||
<ClInclude Include="$(SrcDir)audio_renderer.h" />
|
||||
<ClInclude Include="$(SrcDir)audio_renderer_spectrum.h" />
|
||||
<ClInclude Include="$(SrcDir)audio_renderer_waveform.h" />
|
||||
|
@ -163,7 +164,6 @@
|
|||
<ClInclude Include="$(SrcDir)help_button.h" />
|
||||
<ClInclude Include="$(SrcDir)hotkey_data_view_model.h" />
|
||||
<ClInclude Include="$(SrcDir)include\aegisub\audio_player.h" />
|
||||
<ClInclude Include="$(SrcDir)include\aegisub\audio_provider.h" />
|
||||
<ClInclude Include="$(SrcDir)include\aegisub\context.h" />
|
||||
<ClInclude Include="$(SrcDir)include\aegisub\hotkey.h" />
|
||||
<ClInclude Include="$(SrcDir)include\aegisub\menu.h" />
|
||||
|
@ -271,15 +271,9 @@
|
|||
<ClCompile Include="$(SrcDir)audio_player_oss.cpp" />
|
||||
<ClCompile Include="$(SrcDir)audio_player_portaudio.cpp" />
|
||||
<ClCompile Include="$(SrcDir)audio_player_pulse.cpp" />
|
||||
<ClCompile Include="$(SrcDir)audio_provider.cpp" />
|
||||
<ClCompile Include="$(SrcDir)audio_provider_avs.cpp" />
|
||||
<ClCompile Include="$(SrcDir)audio_provider_convert.cpp" />
|
||||
<ClCompile Include="$(SrcDir)audio_provider_dummy.cpp" />
|
||||
<ClCompile Include="$(SrcDir)audio_provider_factory.cpp" />
|
||||
<ClCompile Include="$(SrcDir)audio_provider_ffmpegsource.cpp" />
|
||||
<ClCompile Include="$(SrcDir)audio_provider_hd.cpp" />
|
||||
<ClCompile Include="$(SrcDir)audio_provider_lock.cpp" />
|
||||
<ClCompile Include="$(SrcDir)audio_provider_pcm.cpp" />
|
||||
<ClCompile Include="$(SrcDir)audio_provider_ram.cpp" />
|
||||
<ClCompile Include="$(SrcDir)audio_renderer.cpp" />
|
||||
<ClCompile Include="$(SrcDir)audio_renderer_spectrum.cpp" />
|
||||
<ClCompile Include="$(SrcDir)audio_renderer_waveform.cpp" />
|
||||
|
|
|
@ -417,7 +417,7 @@
|
|||
<ClInclude Include="$(SrcDir)include\aegisub\audio_player.h">
|
||||
<Filter>Audio\Players</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="$(SrcDir)include\aegisub\audio_provider.h">
|
||||
<ClInclude Include="$(SrcDir)audio_provider_factory.h">
|
||||
<Filter>Audio\Providers</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="$(SrcDir)include\aegisub\context.h">
|
||||
|
@ -575,30 +575,15 @@
|
|||
<ClCompile Include="$(SrcDir)ass_style_storage.cpp">
|
||||
<Filter>ASS</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="$(SrcDir)audio_provider_ram.cpp">
|
||||
<Filter>Audio\Providers</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="$(SrcDir)audio_provider.cpp">
|
||||
<ClCompile Include="$(SrcDir)audio_provider_factory.cpp">
|
||||
<Filter>Audio\Providers</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="$(SrcDir)audio_provider_avs.cpp">
|
||||
<Filter>Audio\Providers</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="$(SrcDir)audio_provider_convert.cpp">
|
||||
<Filter>Audio\Providers</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="$(SrcDir)audio_provider_dummy.cpp">
|
||||
<Filter>Audio\Providers</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="$(SrcDir)audio_provider_ffmpegsource.cpp">
|
||||
<Filter>Audio\Providers</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="$(SrcDir)audio_provider_hd.cpp">
|
||||
<Filter>Audio\Providers</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="$(SrcDir)audio_provider_pcm.cpp">
|
||||
<Filter>Audio\Providers</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="$(SrcDir)audio_box.cpp">
|
||||
<Filter>Audio\UI</Filter>
|
||||
</ClCompile>
|
||||
|
|
|
@ -64,6 +64,7 @@
|
|||
<ClInclude Include="$(SrcDir)include\libaegisub\ass\smpte.h" />
|
||||
<ClInclude Include="$(SrcDir)include\libaegisub\ass\time.h" />
|
||||
<ClInclude Include="$(SrcDir)include\libaegisub\ass\uuencode.h" />
|
||||
<ClInclude Include="$(SrcDir)include\libaegisub\audio\provider.h" />
|
||||
<ClInclude Include="$(SrcDir)include\libaegisub\background_runner.h" />
|
||||
<ClInclude Include="$(SrcDir)include\libaegisub\cajun\elements.h" />
|
||||
<ClInclude Include="$(SrcDir)include\libaegisub\cajun\reader.h" />
|
||||
|
@ -121,6 +122,13 @@
|
|||
</ClCompile>
|
||||
<ClCompile Include="$(SrcDir)ass\dialogue_parser.cpp" />
|
||||
<ClCompile Include="$(SrcDir)ass\time.cpp" />
|
||||
<ClCompile Include="$(SrcDir)audio\provider.cpp" />
|
||||
<ClCompile Include="$(SrcDir)audio\provider_convert.cpp" />
|
||||
<ClCompile Include="$(SrcDir)audio\provider_dummy.cpp" />
|
||||
<ClCompile Include="$(SrcDir)audio\provider_hd.cpp" />
|
||||
<ClCompile Include="$(SrcDir)audio\provider_lock.cpp" />
|
||||
<ClCompile Include="$(SrcDir)audio\provider_pcm.cpp" />
|
||||
<ClCompile Include="$(SrcDir)audio\provider_ram.cpp" />
|
||||
<ClCompile Include="$(SrcDir)common\cajun\elements.cpp" />
|
||||
<ClCompile Include="$(SrcDir)common\cajun\reader.cpp" />
|
||||
<ClCompile Include="$(SrcDir)common\cajun\writer.cpp" />
|
||||
|
|
|
@ -12,9 +12,6 @@
|
|||
<Filter Include="Source Files\Common">
|
||||
<UniqueIdentifier>{4084442f-51e9-4c31-8d5a-c825e076c012}</UniqueIdentifier>
|
||||
</Filter>
|
||||
<Filter Include="Source Files\Windows">
|
||||
<UniqueIdentifier>{5af331b5-ea1f-493f-abf9-f5912e2350df}</UniqueIdentifier>
|
||||
</Filter>
|
||||
<Filter Include="cajun">
|
||||
<UniqueIdentifier>{1d2e187a-1681-4c30-8912-a4b5a5d0ab9d}</UniqueIdentifier>
|
||||
</Filter>
|
||||
|
@ -27,6 +24,12 @@
|
|||
<Filter Include="Lua\Modules">
|
||||
<UniqueIdentifier>{2cf3ad94-e8a9-4a89-b47e-29523d90fd08}</UniqueIdentifier>
|
||||
</Filter>
|
||||
<Filter Include="Audio">
|
||||
<UniqueIdentifier>{fce4f3aa-dc34-44fe-9a6a-99b0914e3436}</UniqueIdentifier>
|
||||
</Filter>
|
||||
<Filter Include="Source Files\Windows">
|
||||
<UniqueIdentifier>{5af331b5-ea1f-493f-abf9-f5912e2350df}</UniqueIdentifier>
|
||||
</Filter>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ClInclude Include="$(SrcDir)common\charset_6937.h">
|
||||
|
@ -203,6 +206,9 @@
|
|||
<ClInclude Include="$(SrcDir)include\libaegisub\ycbcr_conv.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="$(SrcDir)include\libaegisub\audio\provider.h">
|
||||
<Filter>Audio</Filter>
|
||||
</ClInclude>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ClCompile Include="$(SrcDir)windows\lagi_pre.cpp">
|
||||
|
@ -340,10 +346,31 @@
|
|||
<ClCompile Include="$(SrcDir)common\ycbcr_conv.cpp">
|
||||
<Filter>Source Files\Common</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="$(SrcDir)audio\provider.cpp">
|
||||
<Filter>Audio</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="$(SrcDir)audio\provider_convert.cpp">
|
||||
<Filter>Audio</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="$(SrcDir)audio\provider_dummy.cpp">
|
||||
<Filter>Audio</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="$(SrcDir)audio\provider_hd.cpp">
|
||||
<Filter>Audio</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="$(SrcDir)audio\provider_lock.cpp">
|
||||
<Filter>Audio</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="$(SrcDir)audio\provider_pcm.cpp">
|
||||
<Filter>Audio</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="$(SrcDir)audio\provider_ram.cpp">
|
||||
<Filter>Audio</Filter>
|
||||
</ClCompile>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<None Include="$(SrcDir)include\libaegisub\charsets.def">
|
||||
<Filter>Header Files</Filter>
|
||||
</None>
|
||||
</ItemGroup>
|
||||
</Project>
|
||||
</Project>
|
|
@ -84,6 +84,6 @@ public:
|
|||
|
||||
namespace agi {
|
||||
std::unique_ptr<AudioProvider> CreateHDAudioProvider(std::unique_ptr<AudioProvider> src, agi::fs::path const& dir) {
|
||||
return make_unique<HDAudioProvider>(std::move(src), dir);
|
||||
return agi::make_unique<HDAudioProvider>(std::move(src), dir);
|
||||
}
|
||||
}
|
||||
|
|
|
@ -91,6 +91,6 @@ void RAMAudioProvider::FillBuffer(void *buf, int64_t start, int64_t count) const
|
|||
|
||||
namespace agi {
|
||||
std::unique_ptr<AudioProvider> CreateRAMAudioProvider(std::unique_ptr<AudioProvider> src) {
|
||||
return make_unique<RAMAudioProvider>(std::move(src));
|
||||
return agi::make_unique<RAMAudioProvider>(std::move(src));
|
||||
}
|
||||
}
|
||||
|
|
|
@ -89,22 +89,22 @@ AvisynthAudioProvider::AvisynthAudioProvider(agi::fs::path const& filename) {
|
|||
LoadFromClip(env->Invoke("DirectShowSource", AVSValue(args, 3), argnames));
|
||||
// Otherwise fail
|
||||
else
|
||||
throw agi::AudioProviderOpenError("No suitable audio source filter found. Try placing DirectShowSource.dll in the Aegisub application directory.");
|
||||
throw agi::AudioProviderError("No suitable audio source filter found. Try placing DirectShowSource.dll in the Aegisub application directory.");
|
||||
}
|
||||
}
|
||||
catch (AvisynthError &err) {
|
||||
std::string errmsg(err.msg);
|
||||
if (errmsg.find("filter graph manager won't talk to me") != errmsg.npos)
|
||||
throw agi::AudioDataNotFoundError("Avisynth error: " + errmsg);
|
||||
throw agi::AudioDataNotFound("Avisynth error: " + errmsg);
|
||||
else
|
||||
throw agi::AudioProviderOpenError("Avisynth error: " + errmsg);
|
||||
throw agi::AudioProviderError("Avisynth error: " + errmsg);
|
||||
}
|
||||
}
|
||||
|
||||
void AvisynthAudioProvider::LoadFromClip(AVSValue clip) {
|
||||
// Check if it has audio
|
||||
VideoInfo vi = clip.AsClip()->GetVideoInfo();
|
||||
if (!vi.HasAudio()) throw agi::AudioDataNotFoundError("No audio found.");
|
||||
if (!vi.HasAudio()) throw agi::AudioDataNotFound("No audio found.");
|
||||
|
||||
IScriptEnvironment *env = avs_wrapper.GetEnv();
|
||||
|
||||
|
@ -143,7 +143,7 @@ void AvisynthAudioProvider::FillBuffer(void *buf, int64_t start, int64_t count)
|
|||
}
|
||||
}
|
||||
|
||||
std::unique_ptr<AudioProvider> CreateAvisynthAudioProvider(agi::fs::path const& file, agi::BackgroundRunner *) {
|
||||
std::unique_ptr<agi::AudioProvider> CreateAvisynthAudioProvider(agi::fs::path const& file, agi::BackgroundRunner *) {
|
||||
return agi::make_unique<AvisynthAudioProvider>(file);
|
||||
}
|
||||
#endif
|
||||
|
|
Loading…
Reference in a new issue