- Changed FMOD_INIT_ENABLE_DSPNET use to its replacement from 4.14.00,

FMOD_INIT_ENABLE_PROFILE. Renamed the corresponding cvar to snd_profile.
- Removed the normalize parameter from SoundStream::Play().
- Disabled the chorus and reverb effects added to SDL_mixer's Timidity,
  because they were probably never tested well, either. Thanks to the bug
  in vc_alloc(), they were never even activated.
- Restored the exact frequency range search that was missing from SDL_mixer's
  verion of select_sample().
- Fixed: vc_alloc(), kill_others(), and note_on() treated Voice::status as a
  bit mask, when it's not. These were changes made to SDL_mixer's Timidity.
- Restored the original Timidity volume equation. The other louder one was
  put in when I didn't realize all channels were mono and many notes sounded
  too quiet because they never completed their attack phase.
- Fixed: FileReader::Gets() acted as if fgets() always read the maximum
  number of characters.
- Fixed: FileReader::Open() did not set FilePos and StartPos to 0.


SVN r908 (trunk)
This commit is contained in:
Randy Heit 2008-04-13 03:23:33 +00:00
commit e7ff22457e
13 changed files with 70 additions and 42 deletions

View file

@ -90,6 +90,8 @@ bool FileReader::Open (const char *filename)
{
File = fopen (filename, "rb");
if (File == NULL) return false;
FilePos = 0;
StartPos = 0;
CloseOnDestruct = true;
Length = CalcFileLen();
return true;
@ -141,13 +143,12 @@ long FileReader::Read (void *buffer, long len)
char *FileReader::Gets(char *strbuf, int len)
{
if (FilePos + len > StartPos + Length)
{
len = Length - FilePos + StartPos;
}
if (len <= 0) return 0;
char *p = fgets(strbuf, len, File);
FilePos += len;
if (p != NULL)
{
FilePos = ftell(File) - StartPos;
}
return p;
}