AminetAminet
Search:
84799 packages online
About
Recent
Browse
Search
Upload
Setup
Services

util/dtype/PlayMidi.lha

Mirror:Random
Showing: m68k-amigaos iconppc-amigaos iconppc-morphos iconi386-aros iconi386-amithlon iconppc-warpup iconppc-powerup icongeneric icon
No screenshot available
Short:V1.0b Plays MIDI Files via GMPlay & cli.datatype
Author: dbusse at debitel.net (Dirk Busse)
Uploader:dbusse debitel net (Dirk Busse)
Type:util/dtype
Architecture:m68k-amigaos
Date:2000-01-01
Requires:GMPlay and cli.datatype
Download:util/dtype/PlayMidi.lha - View contents
Readme:util/dtype/PlayMidi.readme
Downloads:936

Pre-History & Description:
   Did you ever wonder why IBrowse never plays Midi background sounds?
   You could setup a external viewer audio/midi
   with the command  $GMDIR/GMPlay
   and the arguments <>CON:100/80/500/120/GMPlay "%f" V=400 B=2 PRI=21
   If you load a Midi file via the URL, IBrowse plays it. But when you load
   a web page with a Midi background sound, IBrowse doesn't plays it.
   The reason is: IBrowse loads background sound only via datatypes.
   So my idee was to write a datatype which forwards the file to GMplay.
   My knowledges of programming datatypes and of programming in C are nearly
   zero. I didn't found an example datatype in assembler, but I found the
   cli.datatype.
   The first solution (starting directly GMPlay via cli.datatype) wasn't
   very well.
   The second solution (starting GMplay via a shell script via cli.datatype)
   was a little better. But it doen't works "clean".
   So I wrote a little assembler program "PlayMidi", which gives a little
   note to the caller (for example MultiView), breaks the actually GMPlay
   (you couldn't start GMPlay twice) and runs GMPlay with the new file.

Installation:
   - You need a successfully installed GMPlay.
     (Aminet:mus/midi/GMPlay13.lha)
   - You need a successfully installed cli.datatype.
     (AMinet:util/dtype/cli_dtc.lha)
     For using with AMIGA OS 3.5 you need the latest cli.datatypes V39.7
     which is included in this archive.
   - copy "c/PlayMidi" somewhere in your path (for example in c:)
   - copy "datatypes/MIDI" and "datatypes/XPKMIDI" to devs:datatypes
   - create a env variable GMDIR with the path of GMPlay.
     for example with:
     setenv envarc:GMDIR "DH0:MIDI/GMPlay"
   - create a env variable PlayMidiGMopts with your options which you want
     to use for GMPlay.
     for example with:
  setenv envarc:PlayMidiGMopts ">CON:100/80/510/120/GMPlay V=400 B=2 PRI=21"
     (You could use there all GMPlay options. Now you could simple use
      PlayMidi instead of GMPlay for playing your Midi files.)
   - add to the file envarc:datatypes/cli.prefs the following lines:

     MIDI     COMMAND=PlayMidi "%s"
     XPKMIDI  COMMAND=PlayMidi "%s"

   - That's all! Now IBrowse should play Midi background sounds!
     Now also every datatype viewer like MultiView should play midi files.


   (- Setting up IBrowse External Viewers for Midi support:
      Type:      audio/midi     and    audio/x-midi
      Mime:      midi mid kar
      Action:    Ext. viewer
      Viewer:    PlayMidi
      Arguments: "%f"                                       )



Example envarc-files and the source code of PlayMidi is also in the archive.


Author:
   Dirk Busse
   Kropsburgstraße 8
   D-67141 Neuhofen
   Germany
   <dbusse@debitel.net>
   <dbusse@germanynet.de>


Questions&Answers:

   Q: Where are pages on the Internet with Midi background sounds?
   A: For example at:
      http://www.elaborate-bytes.com/deutsch/firma/index.htm
      http://www.brenner-sievritts.com/hauptmenu.htm
      http://www.dlrg.de/Gliederung/Rheinland-Pfalz/Vorderpfalz/Ludwigshafen-Oggersheim/index.html

   Q: IBrowse doesn't plays Midi-Files from the GMPlay archive as
      background sound.
   A: IBrowse plays only background sounds with the datatype class sound.
      The Midi-Files from the GMPlay archive are xpk-packed. Xpk isn't a
      sound datatype class.
      But this shouldn't be a problem. If you open the Midi file directly,
      IBrowse should play it. And as background sound you must not use
      packed Midi files. Because xpk isn't a standard in the Internet. It's
      only a standard on the Amiga.
      With devs:Datatypes/XPKMIDI IBrowse will also play xpk packed midi
      files as background sound. But don't use xpk packed midi files on
      webpages, because xpk is only on the AMIGA a standard.

   Q: IBrowse 2.1 doesn't plays background sounds  :-(  :-(  :-(  :-(
   A: I don't know why. Maybe the Authors of IBrowse knows the answer.

   Q: MultiView crashes with an GURU on AMIGA OS 3.5.
   A: Please use the recompiled cli.datatype V39.7. This should fix this
      problem.
      (The cli.datatype V39.7 archive is included in this PlayMidi archive.)

   If you have some other questions or problems, you could send me a EMail
   or letter.


History:
   1.0  (07.May 1999)
        - First version.
   1.0a (04.Dec 1999)
        - The Datatype doesn't work under AMIGA OS 3.5
          To fix this Problem you have to do the following:
          **** Lines killed, because the reason wasn't PlayMidi. ****
          **** The problem was cli.datatype V39.6                ****
   1.0b (27.Dec 1999)
        - The reason for the problem with AMIGA OS3.5 is not PlayMidi.
          It's the cli.datatype V39.6. Also viewing lha files crashes
          under OS3.5. 
          I have recompiled the cli.datatype (now V39.7) which now works
          also under AMIGA OS3.5.
          Please use this cli.datatype V39.7.
        - Added the cli.datatype V39.7 archive, which now works under
          AMIGA OS3.5.
        - Playing xpk packed Midi files with MultiView under AMIGA OS3.5
          crashes, when they are unpacked by the xpk.datatype V39.1.
          But GMPlay could decrunch xpk packed Midi files by itself.
          Therefor I created a second datatypes descriptor "XPKMIDI" which
          doesn't use the xpk.datatype for midi files.
        - Added example envarc:Datatypes/cli.prefs file


Contents of util/dtype/PlayMidi.lha
 PERMSSN    UID  GID    PACKED    SIZE  RATIO     CRC       STAMP          NAME
---------- ----------- ------- ------- ------ ---------- ------------ -------------
[generic]                 5988    5988 100.0% -lh0- 3f92 Dec 27  1999 cli_dtc39_7.lha
[generic]                 2240    5660  39.6% -lh5- 68bf Dec 27  1999 PlayMidi.readme
[generic]                  284     608  46.7% -lh5- 7093 May  8  1999 c/PlayMidi
[generic]                   84     112  75.0% -lh5- 9160 May  4  1999 devs/DataTypes/MIDI
[generic]                  278     467  59.5% -lh5- 9acf May  4  1999 devs/DataTypes/MIDI.info
[generic]                  105     156  67.3% -lh5- 5cdc Dec 27  1999 devs/DataTypes/XPKMIDI
[generic]                  281     467  60.2% -lh5- 12a0 Dec 27  1999 devs/DataTypes/XPKMIDI.info
[generic]                   16      16 100.0% -lh0- e935 Dec 27  1999 envarc/GMDIR
[generic]                   44      44 100.0% -lh0- 2dcf May  7  1999 envarc/PlayMidiGMopts
[generic]                  278     780  35.6% -lh5- 6f4c Dec 27  1999 envarc/Datatypes/Cli.prefs
[generic]                  791    2201  35.9% -lh5- 53bd May  8  1999 Source/PlayMidi.s
---------- ----------- ------- ------- ------ ---------- ------------ -------------
 Total        11 files   10389   16499  63.0%            Jan  1  2000
Page generated in 0.03 seconds
Aminet © 1992-2024 Urban Müller and the Aminet team. Aminet contact address: <aminetaminet net>