unit nik;
interface
uses
Windows, Messages, SysUtils, Classes, Graphics, Controls, Forms, Dialogs,
Bass, StdCtrls, ExtCtrls, Buttons, Menus;
type
TForm1 =
class(TForm)
Button1: TButton;
Button2: TButton;
ListBox1: TListBox;
OpenDialog1: TOpenDialog;
procedure Button1Click(Sender: TObject);
procedure Button2Click(Sender: TObject);
private
mods:
array[0..128]
of HMUSIC;
modc: Integer;
sams:
array[0..128]
of HSAMPLE;
samc: Integer;
strs:
array[0..128]
of HSTREAM;
strc: Integer;
public
end;
var
Form1: TForm1;
implementation
{$R *.dfm}
procedure TForm1.Button1Click(Sender: TObject);
begin
if OpenDialog1.Execute
then
Listbox1.Items.Add(OpenDialog1.Filename);
end;
procedure TForm1.Button2Click(Sender: TObject);
var
i: Integer;
begin
i := ListBox1.ItemIndex;
// Play the stream (continuing from current position)
if i >= 0
then
if not BASS_ChannelPlay(strs[i], False)
then
end;
end.