예제 #1
0
파일: WavLoader.cs 프로젝트: pchote/OpenRA
        bool ISoundLoader.TryParseSound(Stream stream, out ISoundFormat sound)
        {
            try
            {
                if (IsWave(stream))
                {
                    sound = new WavFormat(stream);
                    return true;
                }
            }
            catch
            {
                // Not a (supported) WAV
            }

            sound = null;
            return false;
        }
예제 #2
0
파일: AudLoader.cs 프로젝트: pchote/OpenRA
        bool ISoundLoader.TryParseSound(Stream stream, out ISoundFormat sound)
        {
            try
            {
                if (IsAud(stream))
                {
                    sound = new AudFormat(stream);
                    return true;
                }
            }
            catch
            {
                // Not a supported AUD
            }

            sound = null;
            return false;
        }