RFE: add getKeyRange() method to Patch

XMLWordPrintable

    • Fix Understood
    • generic
    • generic



      Name: fb126949 Date: 02/07/2003


      Programs in banks may have a key range, or may only be playable on certain keys at all (percussion instruments). Currently, the Java Sound Engine returns the key number as the program in Patch, which is wrong. This proposal aims add 2 new methods:

      /**
       * Returns the first key number that this patch
       * is responding to.
       * <p>
       * Percussion instruments
       * are typically bound to one key, and
       * <code>getKeyRangeBegin()</code> and
       * <code>getKeyRangeEnd()</code> will return
       * the same key number.
       * <p>
       * If this instrument does not have a limited
       * key range, this method returns -1.
       */
      int getKeyRangeBegin();

      /**
       * Returns the last key number that this patch
       * is responding to.
       * <p>
       * Percussion instruments
       * are typically bound to one key, and
       * <code>getKeyRangeBegin()</code> and
       * <code>getKeyRangeEnd()</code> will return
       * the same key number.
       * <p>
       * If this instrument does not have a limited
       * key range, this method returns -1.
       */
      int getKeyRangeEnd();


      ======================================================================

            Assignee:
            Unassigned
            Reporter:
            Florian Bomers (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Created:
              Updated:
              Imported:
              Indexed: