Commit Graph
166 Commits
Author SHA1 Message Date
Torbjörn Andersson 623514df01 Cleanup: output0x388(0xABCD) is now writeOPL(0xAB, 0xCD), which is slightly
more easy to read.

svn-id: r21081
2006-03-04 20:27:51 +00:00
Johannes Schickel 491cbcec5b Changed timeing related variables to unsigned.
Also changed the callback interval.

svn-id: r21012
2006-03-02 16:14:46 +00:00
Johannes Schickel ce63f2bc38 Oops forgot to enable music again.
svn-id: r20993
2006-03-01 18:18:16 +00:00
Johannes Schickel 730eaf2dca Added debug calls to the adlib functions, also uses mixer samplerate now.
Fixed a bug in updateCallback41.

svn-id: r20992
2006-03-01 16:44:32 +00:00
Torbjörn Andersson 8a60a99140 Fixed updateCallback11() according to LordHoto's directions, and renamed it
update_writeAdlib(). (The "update_" prefix will probably be changed later, but
for now I want it to remain obvious that the functions belong to the other
updateCallback*() functions.)

svn-id: r20990
2006-03-01 13:57:32 +00:00
Torbjörn Andersson 5734717f8e Renamed 'unk9' to a slightly more descriptive 'repeatCounter'. (I should have
done that in the previous commit.)

svn-id: r20987
2006-03-01 08:13:38 +00:00
Torbjörn Andersson 272a19cf5b Use signed integers for jump offsets, so that the jump opcodes can jump both
forward and backward. This seems to fix the looping of the Black forest music
(and probably others as well), and might fix the invalid pointer crashes and
wrong music that would sometimes play after a song had finished. Changed the
names of the jump opcode functions, and added "update_" prefixes to the
previously cleaned-up opcode functions.

svn-id: r20986
2006-03-01 08:06:54 +00:00
Torbjörn Andersson 3a38721d02 Cleaned up updateCallback36() and renamed it setVibratoDepth().
svn-id: r20985
2006-03-01 07:27:35 +00:00
Torbjörn Andersson 55739f1715 Cleaned up updateCallback35() and renamed it setAMDepth(). It looks like the
_unkOutputByte2 variable is there to keep track of the current value of the
BD register (AM Depth / Vibrato Depth / Rhythm)

svn-id: r20984
2006-03-01 07:21:51 +00:00
Torbjörn Andersson 90cbe402b2 Minor cleanup and comments.
svn-id: r20983
2006-03-01 06:56:53 +00:00
Johannes Schickel 1e2aa59bcb Added lock() and unlock() again to readBuffer.
Implemented stateCallback1_1.
Fix some small bugs here and there (can't say what the fixed but it should be correct now)
Also set's the correct timer call value (with the other the music was too fast)

svn-id: r20973
2006-02-28 17:02:14 +00:00
Torbjörn Andersson 6ee443f316 Added some basic comments, along with some very, very minor cleanup.
svn-id: r20972
2006-02-28 15:44:39 +00:00
Torbjörn Andersson f03958be01 Removed unnecessary line.
svn-id: r20971
2006-02-28 09:54:09 +00:00
Torbjörn Andersson 005861cb14 This may be needless paranoia, but I always get nervous about order of
evaluation when there are multiple side-effects on the same variable (in this
case the internal state modified by va_arg()) in the same expression. So let's
just humor me and do the va_arg() calls one at a time.

svn-id: r20970
2006-02-28 08:49:51 +00:00
Johannes Schickel 2bcd6bb95e Fixes hangs in the "Pool of Sorrow" scene (at least I don't get them anymore).
svn-id: r20964
2006-02-27 23:41:27 +00:00
Johannes Schickel f3106feaf5 Added WIP Adlib sound playing code to kyra.
It needs some checks since it doesn't work correctly in every case at the moment.

svn-id: r20960
2006-02-27 22:39:55 +00:00