[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Sat, 12 Jan 2008 22:00:48 +0100
Gnus/5.13 (Gnus v5.13) Emacs/23.0.50 (gnu/linux)
;;; guitarr-tune.el --- Tune your guitarr
;; Copyright (C) 2008 Mathias Dahl
;; Version: 0.1
;; Keywords: convenience, music
;; Author: Mathias Dahl <address@hidden>
;; This file is NOT part of GNU Emacs.
;; GNU Emacs is free software; you can redistribute it and/or modify
;; it under the terms of the GNU General Public License as published by
;; the Free Software Foundation; either version 2, or (at your option)
;; any later version.
;; GNU Emacs is distributed in the hope that it will be useful,
;; but WITHOUT ANY WARRANTY; without even the implied warranty of
;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
;; along with GNU Emacs; see the file COPYING. If not, write to the
;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
;; Boston, MA 02110-1301, USA.
;; This is a small hack to help you tune your guitarr. To use, first
;; you need some sound files, which can be downloaded as per
;; below. Save each URL as the file name described in the table:
;; Save as URL
;; ======= ===
;; E1.wav http://www.box.net/shared/xgeh7yqskg
;; A2.wav http://www.box.net/shared/lvlcuyvkso
;; D3.wav http://www.box.net/shared/u7hg1tg8cg
;; G4.wav http://www.box.net/shared/yfzha20g8s
;; B5.wav http://www.box.net/shared/nlitky58gg
;; E6.wav http://www.box.net/shared/x12ksgj4sk
;; browser, it seems (I don't want to host the files on my web server
;; so I had to use the Box.net account, if you know about any better
;; free sound hosting, please tell me.)
;; Next, do M-x eval-buffer RET
;; Now you need to define the place where you saved the sound
;; files. Do that by customizing `guitarr-sound-dir'.
;; Finally, type M-x guitarr-tune RET and follow the instructions
;; on the screen.
;; - EMMS
;; - The sound files mentioned above
(defun guitarr-tune ()
"Tune your guitarr."
(pop-to-buffer (get-buffer-create "*guitarr-tune*"))
(insert "*** Guitarr Tune ***\n\nType e, a, d, g, b, or E (uppercase\
e, for the high e note) to play.\nThe numbers 1
through 6 are also bound to the six strings on the guitarr.\n")
(defcustom guitarr-sound-dir "~/gfx/sound"
"Path to where the sound files are."
(defun guitarr-tune-play (note)
(emms-play-file (concat (file-name-as-directory guitarr-sound-dir)
"Mode for playing guitarr"
(defvar guitarr-tune-mode-map (make-sparse-keymap)
"Keymap for `guitarr-tune-mode'.")
(defun guitarr-tune-define-mode-keymap ()
"Define keymap for `guitarr-tune-mode'."
(define-key guitarr-tune-mode-map (car x)
`(lambda () (interactive) (guitarr-tune-play ',(cdr x)))))
'(("e" . E1)
("a" . A2)
("d" . D3)
("g" . G4)
("b" . B5)
("E" . E6)
("1" . E1)
("2" . A2)
("3" . D3)
("4" . G4)
("5" . B5)
("6" . E6))))
;;; guitarr-tune.el ends here
Message not available
- guitarr-tune.el 0.1,
Mathias Dahl <=