2
0
mirror of https://github.com/AxioDL/metaforce.git synced 2025-12-08 17:04:55 +00:00

CMoviePlayer G.721 audio implemented

This commit is contained in:
Jack Andersen
2016-03-08 12:51:13 -10:00
parent a1bcd78116
commit 52faf42aaa
5 changed files with 108 additions and 32 deletions

View File

@@ -47,10 +47,11 @@ class ViewManager : public specter::IViewManager
void draw(boo::IGraphicsCommandQueue* gfxQ);
};
std::unique_ptr<ParticleView> m_particleView;
urde::TLockedToken<urde::CGenDescription> m_partGenDesc;
std::unique_ptr<urde::CElementGen> m_partGen;
std::unique_ptr<urde::CLineRenderer> m_lineRenderer;
std::unique_ptr<urde::CMoviePlayer> m_moviePlayer;
urde::TLockedToken<CGenDescription> m_partGenDesc;
std::unique_ptr<CElementGen> m_partGen;
std::unique_ptr<CLineRenderer> m_lineRenderer;
std::unique_ptr<CMoviePlayer> m_moviePlayer;
std::unique_ptr<u8[]> m_rsfBuf;
std::unique_ptr<boo::IAudioVoiceAllocator> m_voiceAllocator;
std::unique_ptr<boo::IAudioVoice> m_videoVoice;
boo::AudioMatrixStereo m_stereoMatrix;
@@ -64,6 +65,7 @@ class ViewManager : public specter::IViewManager
m_stereoBuf.resize(frames * 2);
if (m_vm.m_moviePlayer)
m_vm.m_moviePlayer->MixAudio(m_stereoBuf.data(), nullptr, frames);
CMoviePlayer::MixStaticAudio(m_stereoBuf.data(), m_stereoBuf.data(), frames);
m_vm.m_stereoMatrix.bufferStereoSampleData(voice, m_stereoBuf.data(), frames);
}
AudioVoiceCallback(ViewManager& vm) : m_vm(vm) {}