www.delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/1998/09/23/11:51:34

Reply-To: <arfa AT clara DOT net>
From: "Arthur" <arfa AT clara DOT net>
To: "DJGPP Mailing List" <djgpp AT delorie DOT com>, <lawrencej AT ufrsd DOT k12 DOT nj DOT us>
Subject: RE: Allegro Datafiles
Date: Wed, 23 Sep 1998 16:49:15 +0100
Message-ID: <000301bde709$b73ea5a0$464d08c3@arthur>
MIME-Version: 1.0
Importance: Normal
In-Reply-To: <6u9hg4$23v$1@nnrp1.dejanews.com>

> Bad code:
>
>   MIDI *the_music;
>   the_music = load_midi(datafile[MUSIC].dat);
>
>   play_midi(the_music, TRUE);


> OK code:
>
>   MIDI *the_music;
>   the_music = load_midi("mysong.mid");
>
>   play_midi(the_music, TRUE);
>
>
>  What am I doing wrong?

You don't need to load anything from a datafile (since it it loaded
already).

Change the second line above to:

the_music = (MIDI*)datafile[MUSIC].dat;

HTH

James Arthur
jaa AT arfa DOT clara DOT net
ICQ#15054819

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019