#ifndef _RUFUSION_AUDIOLIBRARY_H_
#define _RUFUSION_AUDIOLIBRARY_H_

// Base types
#include "../Symphony/RuSymphony_Base.h"
#include "../Core/Collection/RuCollectionsTree.h"

#pragma unmanaged

// ************************************************************************************************************************************************************

class CRuFusion_AudioRegistry : public IRuObject
{
	ruRTTI_DECLARE
	ruHEAP_DECLARE
	ruCLASSGUID_DECLARE

protected:
	struct TagDescriptor
	{
		CRuArrayList<CRuString *>							m_associatedAudio;			//!< Associated audio resource paths
	};

	CRuBinaryTree<CRuString, TagDescriptor *>				m_tagDescriptors;

public:
										CRuFusion_AudioRegistry();
	virtual								~CRuFusion_AudioRegistry();

	BOOL								AssociateAudio(const char *tag, const char *audioResource);
	const char*							GetAssociatedAudio(const char *tag);
};

// ************************************************************************************************************************************************************

class CRuFusion_AudioLibrary : public IRuObject
{
	ruRTTI_DECLARE
	ruHEAP_DECLARE
	ruCLASSGUID_DECLARE

protected:
	CRuBinaryTree<CRuString, CRuFusion_AudioRegistry *>		m_audioRegistries;				//!< Tree of sound FX libraries

public:
										CRuFusion_AudioLibrary();
	virtual								~CRuFusion_AudioLibrary();

	const char*							GetAssociatedAudio(const char *audioClass, const char *audioTag);
};

// ************************************************************************************************************************************************************

#pragma managed

#endif
