|
About Andrew Choi
MIDI Programs
MIDI File Player (External Device)
MIDI Destination Pop-Up Button
Other Programs Cocoa Sample Programs Syntax Coloring Using Flex Algorithms Jazz Chord Analysis as Optimization
|
A blog where I will write mostly about programming in Cocoa and CoreMIDI, and experiences from my ports of Emacs and XEmacs to the Mac OS.
I repackaged all the code I have into this GUI version of the MIDI Name Document Utility. It requires the FCM framework I posted yesterday to build and run (the two project directories should reside in the same directory for the relative paths to work). Python modules that implement synthesizer-specific behavior can be put in either of the following directories. ~/Library/Application\ Support/MidNamUtility/ /Library/Application\ Support/MidNamUtility/The user directory will take precedence when two files of the same name appear in both directories. To use the utility, start it up. Select the sysex device from which you wish to fetch patch names in the popup button labeled Sysex Device. Then select the device type from the Device Type popup button. The list of device types correspond to all <devicetype>.py Python module files the program can find in the two Python module directories. Then click the Get Names button and when sysex transfer is complete, youll be presented with a save panel to save the .midnam file.You can of course extend this utility by writing Python modules for you own synthesizers. The JD-990.py and Morpheus.py files in yesterdays project provide examples of what these modules should look like.
Just did a bit of cleaning up in this latest version of the FCM framework. Now the PythonEmbeddingTest uses the FCM framework instead of includes the source files directly. Also, a single Python module is used for each synthesizer: the property list that represents the fixed content of the NSSearchPathForDirectoriesInDomains(NSLibraryDirectory, NSUserDomainMask + NSLocalDomainMask, YES);
The PythonEmbeddingTest target of this revised version of the FCM framework is a functional replacement for the MIDI name document utilities for the E-mu Morpheus and Roland JD-990 I posted earlier. Everything synthesizer-specific is moved into two files for each synthesizer: a Python module that defines the function for fetching patch names from the synth and a property list file that defines the fixed portion of the ./PythonEmbeddingTest <sysexdevicename> <outputxmlfilename>PythonEmbeddingTest expects to find the files <sysexdevicename>.py and <sysexdevicename>.plist in the current directory. The listing below is that of the file JD-990.py. Notice how the Python formatting operator % allows the patch number and checksum to be inserted into the request sysex message easily. The code is much cleaner than its Objective-C/Foundation counterpart. The next step is to write a GUI for this program.import FCM import time
I have revised FCBlog to include a few bug fixes and improvements. A problem is now fixed in the code that didnt determine the following month correctly when a month number rolls over (weve just gone into December!). FCBlog now recognizes the optional arguments
Theres a company on the Internet selling a CD-ROM/downloadable distribution of Gimp 1.2 for OS X. Strangely theyve renamed the product MacGimp (I dont think you have the right to name a software if youve just compiled it!). For a long time, they did not post the method for building the Gimp binary, nor any source code, it seems. People in newsgroups complain how illegal/immoral/sleazy/questionable this is. I believe the way to combat such behavior (apart from legal action) is simply to widely distribute information needed to build the program. Im providing the information below for building Gimp 1.3.23 not because Im a free software advocate. I never was one. But you ported Emacs, you say. Well, thats another story, for another time. To me its such a simple task to configure and build a few libraries that this information should be available freely anyway! Interestingly, neither the people at Fink nor DarwinPorts seem to have figured out how to build this. You see it here first on the entire Web!
./configure --enable-shared make sudo make installHerere notes for building the individual packages. zlib - Configure by typing ./configure --shared. Then edit the file Makefile so that:
libdir =/usr/local/lib includedir =/usr/local/includeThis step is very important because you shouldnt overwrite Apples version 1.1.3 in /usr/lib and /usr/include. Set the environment variable DYLD_LIBRARY_PATH to /usr/local/lib for the rest of this installation and the execution of Gimp.libpng - Dont run configure. Type cp script/makefile.darwn Makefile. Then edit Makefile so that:
ZLIBLIB=/usr/local/lib ZLIBINC=/usr/local/includetiff - Configure by typing ./configure.jpeg - Replace ltmain.sh and ltconfig with ltconfig13 and ltmain13 from http://distfiles.opendarwin.org/. Replace config.guess and config.sub from those in /usr/share/libtool/.pkgconfig - In the glib-1.2.8 subdirectoy, replace the files ltmain.sh, ltconfig, config.guess, and config.sub as described above for jpeg.gettext - Configure by typing ./configure --with-libiconv-prefix=/usr --enable-shared. Ignore warnings about multiple definition of _locale_charset.glib - Apply the following patch. Then run autoconf.
--- configure.in.old Tue Aug 26 10:40:44 2003 +++ configure.in Tue Dec 2 20:18:33 2003 @@ -1408,6 +1408,15 @@gimp - Configure by typing ./configure --with-shm=sysv --enable-shared --without-aa --disable-print. Note that this uses SysV shared memory despite the note in configure.in. But this seems to work fine. After configuration, edit app/Makefile so that the line containing SYMPREFIX reads:
SYMPREFIX = _Thats it. Enjoy the very nice program Gimp! Copyright (c) 2003 Andrew Choi. Permission to reproduce this note unmodified is granted provided that this copyright notice is included.
|
Lists
Less-Known Facts About Emacs
Chinese Restaurants in Calgary
Calgary/Banff Tourist Attractions
Top-10 Reason I Stopped Working on Emacs
Misc
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Copyright © 2003, 2004, 2005 Andrew Choi (Contact Information). | Created with FCBlog |