Kara-Moon Forum
November 25, 2020, 06:45:23 PM *
Welcome, Guest. Please login or register.

Login with username, password and session length
News: You can go back to the main site here: Kara-Moon site
 
   Home   Help Search Login Register  
Pages: [1]
  Print  
Author Topic: MIDIInc  (Read 1117 times)
sciurius
Sr. Member
****
Posts: 364



« on: August 02, 2019, 09:54:13 AM »

According to the docs, MIDIInc requires a complete filename (whatever that may mean).

The midi-inc examples use a simple, relative filename. E.g. egs/midi-inc/frankie2.mma has "MidiInc File=rec1.mid ...".

If this is acceptible, it should be documented. Also, shouldn't the filename be interpreted relative to the including mma file?
Logged
bvdp
Kara-Moon Master
****
Posts: 1271


WWW
« Reply #1 on: August 02, 2019, 03:59:29 PM »

I *think* it means that you need the filename extension. But, memory cells ... etc.

I think the path is relative to that of the shell path starting mma in the first place.

Doc update in the next version Smiley
Logged

My online life: http://www.mellowood.ca
bvdp
Kara-Moon Master
****
Posts: 1271


WWW
« Reply #2 on: August 05, 2019, 02:17:12 AM »

Just had a look at code and did some tests Smiley Yes, the docs are confusing. I think just taking the words "This must be a
  complete filename" out will make it more clear. And adding "If the filename starts with a tilde, the name will be expanded ...". Also, add just plain "test.mid" to the examples.

Good?

Logged

My online life: http://www.mellowood.ca
sciurius
Sr. Member
****
Posts: 364



« Reply #3 on: August 07, 2019, 12:11:33 PM »

So if relative filenames are allowed, should they be interpreted relative to the current directory? $_LibPath? The name of the including file?

Currently it is not possible to run e.g.

   mma $MMAPATH/egs/midi-inc/frankie3.mma

since it cannot find rec1.mid .

Note that this is not very important, however, the behaviour should be documented.
« Last Edit: August 07, 2019, 12:32:52 PM by sciurius » Logged
bvdp
Kara-Moon Master
****
Posts: 1271


WWW
« Reply #4 on: August 07, 2019, 04:12:57 PM »

I don't think so. In the case of MidiInc the current directory is where the file you are processing is, nothing to do with libpath, etc. If you are using midiinc to include a midi file into a library file ... I'd suggest you'd be much better off to do it by processing the midi into some riffs and then insert them into the lib file.

I'll look at the docs again.
Logged

My online life: http://www.mellowood.ca
Pages: [1]
  Print  
 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.21 | SMF © 2015, Simple Machines Valid XHTML 1.0! Valid CSS!
Page created in 0.051 seconds with 20 queries.