#include "xsounddriverglobals.h"

XSoundDriverGlobals::XSoundDriverGlobals()
    : XAsset()
    , mAudioReverbSettings(new XAudioReverbSettings())
    , mName(new XString())
{
    SetType(ASSET_TYPE_SNDDRIVER_GLOBALS);
    SetName("Sound Globals");
}

XSoundDriverGlobals::~XSoundDriverGlobals()
{
    delete mAudioReverbSettings;
    delete mName;
}

void XSoundDriverGlobals::Clear()
{
    mAudioReverbSettings->Clear();
    mName->Clear();
}

void XSoundDriverGlobals::ParseData(QDataStream* aStream)
{
    if (GetPtr())
    {
        mAudioReverbSettings->ParsePtr(aStream, false);
        mName->ParsePtr(aStream, false);

        mAudioReverbSettings->ParseData(aStream);
        mName->ParseData(aStream);
    }
}
