Commit Graph

37 Commits

Author SHA1 Message Date
James Brown
9756a420a3 Use extrapath in Sword1 engine (from 0.6.0 branch). More verbose errors to go with the forthcoming new manual. Sword1 CD swapping doesn't work as expected HERE, either :)
svn-id: r14188
2004-07-11 04:41:48 +00:00
Paweł Kołodziejski
c7133de879 getFreeSpace() is not longer used
svn-id: r14136
2004-07-01 04:43:32 +00:00
Max Horn
e0eab01e63 Make use of new File refcount code; also fixed long standing bug in vorbis code (ov_clear was not being called, resulting in a file not being closed)
svn-id: r14107
2004-06-28 22:35:22 +00:00
Paweł Kołodziejski
43979c9012 delete CustomProcInputStream and add getFreeSpace for appendable audiostream
svn-id: r13629
2004-04-25 18:43:46 +00:00
Paweł Kołodziejski
6680c5368d added CustomProcInputStream
svn-id: r13570
2004-04-13 05:57:52 +00:00
Max Horn
aa6ec62e9d Patch #885904 (Flac Support) with some tweaks by me
svn-id: r12984
2004-02-22 14:11:16 +00:00
Torbjörn Andersson
a8f8ceee0f Removed now obsolete getSamplesPlayed() function. It was only ever used for
the Broken Sword cutscenes, where it didn't work very well, and was never
fully implemented.

svn-id: r12832
2004-02-12 17:31:33 +00:00
James Brown
04f2bc0276 Update BS2 cutscene player with changes from roever: overlay support (default, 8bit backends should define BACKEND_8BIT for fast colour remapping) and sound syncronisation.
svn-id: r12456
2004-01-17 14:20:32 +00:00
Max Horn
033ff78ae9 updated copyright notice
svn-id: r12176
2004-01-06 12:45:34 +00:00
Max Horn
bfea71b0c4 renamed AudioInputStream -> AudioStream
svn-id: r12110
2004-01-03 14:10:13 +00:00
Max Horn
91f5f1687c logic fix: we must do wrap around *before* read, not after. otherwise eosIntern will in some border cases return wrong results; some cleanup
svn-id: r11932
2003-12-26 01:32:29 +00:00
Max Horn
c55652d4a6 Rewrote make*Stream factory functions to work around bug in MSVC6 (see bug report #860067); added some comments; LinearMemoryStream now can auto-dispose the data passed to it
svn-id: r11798
2003-12-21 00:26:36 +00:00
Max Horn
d8903123b0 distinguish between end of stream and end of data
svn-id: r11756
2003-12-19 01:30:19 +00:00
Max Horn
d21fc5845d o Moved MP3 and Vorbis input streams to mp3.* resp. vorbis.*
o Added SoundMixer::playInputStream and made some of the other play* methods use it
o Added ProcInputStream stub (not working yet) which one day may allow us to replace the premix code, and allow other fancy stuff
o Remove AudioInputStream::readBuffer default implementation (subclasses should always provide it for max. performance)
o Some minor cleanup

svn-id: r11754
2003-12-19 00:32:47 +00:00
Max Horn
e7bf167428 Made sure that *all* AudioInputStream 'know' their sample rate; removed pointless MusicStream class; removed various specific Channel subclasses and instead generalized the base class some more
svn-id: r11699
2003-12-17 02:19:24 +00:00
Max Horn
4343567458 changed the way 'streams' are handled: the finalization logic is now in the WrappedAudioInputStream; this allows further streamlining of the channel/mixer code (can you already guess what I am working towards? :-)
svn-id: r11696
2003-12-17 01:50:50 +00:00
Max Horn
4c833ba23e fix invalid typo fixes ;-) (BTW did anybody get comit mails for khalek's changes? I didn't)
svn-id: r11183
2003-11-07 09:38:06 +00:00
Jonathan Gray
b2e9b73c4c spelling fixes
svn-id: r11180
2003-11-07 02:43:47 +00:00
Bertrand Augereau
0d54ac09c1 ZeroInputStream::readBuffer didn't have the same signature as the base class version, making VC.NET 2K3 complain
svn-id: r9668
2003-08-13 22:01:34 +00:00
Max Horn
f67b126f1d replace code in readBuffer by slightly less efficient but hopefully working code (at least it fixes an endless loop in COMI for me). I did fix the originaly bug in my optimization, and right now I clueless as to why that code isn't working as it should <sigh>. Need sleep
svn-id: r9588
2003-08-07 22:19:55 +00:00
Max Horn
d280258e09 renamed eof -> eos (end of stream); hid MP3/Vorbis stream classes completly (by providing factory methods); new readBuffer method for AudioInputStream for improved speed of the mixer; new MusicStream class (subclassed for MP3/Vorbis sound) which offers a getRate method; some other tweaks
svn-id: r9467
2003-08-04 22:15:16 +00:00
Max Horn
c373ca107d slightly optimized MP3InputStream::eof, and some cleanup
svn-id: r9422
2003-08-02 18:13:37 +00:00
Max Horn
1f58fea232 converted ChannelMP3 to use new rate conversion scheme, too. Only thing missing now is FLAG_REVERSE_STEREO support (and of course fixing regressions, and the long term goal is to make resample.cpp usable, too)
svn-id: r9395
2003-08-02 02:41:31 +00:00
Max Horn
1cfa9d9029 let the input stream handle the looping (by pretending to be of infinite size -> this fixes a problem which cause 'gaps' at loop turn-over points)
svn-id: r9379
2003-08-01 16:32:11 +00:00
Max Horn
d9bd77032a implemented raw sound looping; some debug output enabled temporarily
svn-id: r9360
2003-08-01 12:49:24 +00:00
Max Horn
0df319e952 #include cleanup (explicityl specify the location for headers from common/, so that we at some point can get rid of -Icommon; exception is made for stdafx.h, since a) we might want to rename it and b) might want to move it to the top level)
svn-id: r9359
2003-08-01 12:21:04 +00:00
Max Horn
9b2d4f92aa removed the AudioInputStream::size method -> only eof() is really needed, and this can be implemented more efficiently stand-alone; implemented MP3InputStream (work in progress)
svn-id: r9313
2003-07-31 01:21:38 +00:00
Max Horn
77eb284062 added VorbisInputStream
svn-id: r9271
2003-07-29 01:37:03 +00:00
Max Horn
c6a4a1d37d make wrapped stream work (I can hear some music in CoMI now before it segfaults :-)
svn-id: r9258
2003-07-28 18:01:56 +00:00
Max Horn
13eee4b06f rewrote the input streams, this should be more straightforward and inline slightly better (the fact that the main AudioInputStream methods are virtual still means that no inlining can take place there; but of course, if we did change that, all the rate converters would have to exist in 8, instead of currently 2, compiled versions)
svn-id: r9256
2003-07-28 17:28:29 +00:00
Max Horn
7ea67048c1 more work on WrappedMemoryStream (not yet tested)
svn-id: r9253
2003-07-28 16:55:43 +00:00
Max Horn
9e051fa507 instead of 'int channels', use 'bool stereo' (less extensible, but then I don't think we'll ever support 5.1 sound :-)); fixed a bug in st_rate_flow where it sometimes would overflow the output buffer; made CopyRateConverter a template, too, increasing efficency
svn-id: r9239
2003-07-28 11:13:01 +00:00
Max Horn
e87bc6d89e use a single converter for both channels (if input data is stereo), for improved efficency; renamed MemoryAudioInputStream -> LinearMemoryStream and use some template voodoo to make the baseclass of Input8bitSignedStream etc. variable; added (commented out) draf of WrappedMemoryStream
svn-id: r9209
2003-07-28 01:13:31 +00:00
Max Horn
c520d2d423 move AudioInputStream implementations & makeInputStream into separate .cpp file
svn-id: r9190
2003-07-25 13:42:05 +00:00
Max Horn
2ae3e45aea reduced source code duplication
svn-id: r9189
2003-07-25 13:34:25 +00:00
Max Horn
1622ac31da added RateConverter classes as thin wrappers around st_* functions; renamed InputStream -> AudioInputStream and cleaned up the hierarchy of its subclasses; added makeInputStream() auxillary function
svn-id: r9179
2003-07-24 18:20:12 +00:00
Max Horn
b9d380bba4 new files, based on SoX (http://sox.sf.net): better resampling code. Note that my mixer.cpp changes are on purpose not yet in CVS since they are not complete. Only reasons I checkin these files is that it's much more comfortable to have CVS, since I need to rewrite parts of resample.cpp now (I already have lots of modifications in). Also expect more OO in the future
svn-id: r9176
2003-07-24 17:46:38 +00:00