memorySoundArchive

Overview

Demonstrates how to use the nw::snd::MemorySoundArchive class.

How to Use

Description

Although nw::snd::RomSoundArchive is used in other demos (such as simple), nw::snd::MemorySoundArchive is used in this demo.

Because MemorySoundArchive treats the specified memory region as a sound archive, items do not need to be loaded one-by-one as with RomSoundArchive.

    // Initializes the memory sound archive
    {
        nn::fs::FileReader reader( SOUND_ARC_PATH );
        s32 size = (s32)reader.GetSize();
        m_pMemoryForSoundArchive = MemAlloc( size, 32 );
        s32 readSize = reader.Read( m_pMemoryForSoundArchive, size );
        m_Archive.Initialize( m_pMemoryForSoundArchive );
        reader.Finalize();
    }
      

Although the concept under SoundMaker is to split work up for each separate sound set, use of this features allows you to think in terms of splitting up work for each separate sound archive.

See Also

simple Demo
hioSoundArchive Demo

Revision History

2010/11/15
Added links to the simple and hioSoundArchive demos.
2010/09/27
Initial version.

CONFIDENTIAL