WiredWorm,
You need the MaxMod Module as well. Redi's site has been down recently, but you may be able to get it from here:
http://www.blitzbasic.com/Community/posts.php?topic=67827
Also note the latest MaxMod changed the use of the sidstream module. The following example should work fine with the current version of both modules:
You need the MaxMod Module as well. Redi's site has been down recently, but you may be able to get it from here:
http://www.blitzbasic.com/Community/posts.php?topic=67827
Also note the latest MaxMod changed the use of the sidstream module. The following example should work fine with the current version of both modules:
' load.bmx Strict Framework BRL.GLMax2D Import REDi.MaxMod Import SID.SIDStream Graphics 800,600,0 ' initialize the MaxMod music system InitMaxModStream() ' use the built-in SIDStream loader Local Stream:SIDStream = New SIDStream Stream.Load(RequestFile("Load a sid file")) ' start sid Stream.Play() Local Pitch# = 1 Repeat Cls DrawText " ESCAPE = Exit",5,5 DrawText " SPACE = Play",5,20 DrawText " S = Stop",5,35 DrawText " P = Pause",5,50 DrawText " UP/DOWN = Pitch",5,65 DrawText " PITCH = "+Pitch,5,125 DrawText "TOTAL TRACKS = "+Stream.GetTrackCount(),5,170 DrawText " TRACK = "+Stream.CurrentTrack(),5,185 DrawText " LEFT/RIGHT = Select Track",5,200 If KeyHit(KEY_S) Then Stream.Stop() If KeyHit(KEY_SPACE) Then Stream.Play() If KeyHit(KEY_P) Then Stream.Pause() If KeyDown(KEY_UP) Then Pitch:+0.001 ; Stream.SetHertz(Pitch) If KeyDown(KEY_DOWN) Then Pitch:-0.001 ; Stream.SetHertz(Pitch) If KeyHit(KEY_LEFT) Then Stream.SelectTrack(Stream.CurrentTrack()-1) If KeyHit(KEY_RIGHT) Then Stream.SelectTrack(Stream.CurrentTrack()+1) Flip True Until KeyDown(KEY_ESCAPE) Stream.Free() End