Difference between revisions of "MythMusic"
(→Visualizations) |
(→MythMusic Install) |
||
Line 2: | Line 2: | ||
− | + | See the section on [[MythMusic Installation]] if you are having problems getting MythMusic to work | |
− | |||
− | |||
− | |||
− | |||
− | |||
− | [[ | ||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
== Configuring MythMusic == | == Configuring MythMusic == |
Revision as of 15:20, 16 December 2007
MythMusic is a simple mythtv plugin that allows the system to play audio files .i.e MP3, Ogg, FLAC, wav etc using the MythTV GUI and remote.
See the section on MythMusic Installation if you are having problems getting MythMusic to work
Contents
Configuring MythMusic
Configuration of MythMusic occurs in two places. The main mythfrontend Setup is for global MythMusic configuration. Go to the Setup/MythMusic/General Setup screen and adjust it for your particular configuration.
The second configuration screen is within the MythMusic program and will allow you rescan your music library, etc.
Here's some explanation about the Ignore_ID3 and The NonID3FileNameFormat:
If Ignore_ID3 is set to TRUE, MythMusic will try to determine the Genre, Artist, Album, Track Number, and Title from the filename of the mp3 file. The NonID3FileNameFormat variable should be set to the directory/file format where the mp3 files are stored. For instance, I store mine in the above shown Genre/Artist/Album/Track format. MythMusic will then use this information to fill in the proper fields when it populates the musicmetadata table rather than searching for an ID3 tag in the mp3 file.
The files can be laid out in any format, such as:
Genre/Artist/Album/Title Artist/Genre/Album/Title Artist/Album/Title (with Genre left as Unknown)
The track number is optional but can be specified with the title by using the TRACK_TITLE keyword instead of TITLE. If TRACK_TITLE is used, then the filename can have a space, hyphen, or underscore separating the track number from the track title. Keywords are case insensitive, so if you specify GENRE it's the same as Genre in the format field.
The Ignore_ID3 option does not disable the code that determines the track length, just the portion that tries to read ID3 info.
Note that if the structure of the directories is different than that as described in the NonID3FileNameFormat field, newly placed music will simply not show up when you select "Scan for New Music".
Linking Pre-Existing Audio Archive with MythMusic
I use RubyRipper to rip my CD Music library. I also prefer a much different directory and file layout then MythMusic uses. The RubyRipped files are my 'master'. MythMusic 'Scan for new music' will NOT successfully identify music files that are themselves symbolic links. Scanned files, for now, must be hard links. As space is a consideration though, I don't want to manage two sets of directories with duplicate copies of the same data. So, the solution is to do a HARD LINK from the master audio archive directory to the target mythtv/music directory. NOTE: Hard links must exist on the same file system. So, this only works if your audio library directory and mythtv director are on the same volume/partition.
This little perl script when run will find the all files under audioarchive/vorbis. It then splits the path. This script array elements 4,6,7 of that path align with genre/artist/album. Directories are created under /mythtv/music and a second HARD LINK is created to the master audio file. You'll need to adjust the array element numbering to match your archive path structure and also adjust the order for your MythMusic path.
I also modify the permissions of the '/mythtv/music' directory and files to be 'read-only' because I don't rip from MythMusic setup. While the built in ripper is very flexible and includes all the elements for creating a complex and unique hiearchy -- it doesn't support ripping multiple formats at once like RubyRipper, or swaping out the default ripper with a command reference to a ripper of choice.
So, note that if you use the permission settings in the perl script, all attempts to rip from the MythMusic interface should/will fail since the mythtv user has no write permissions under /mythtv/music.
#!/usr/bin/perl $audioArchive = '/audioarchive/vorbis'; $mythMusic = '/mythtv/music'; @fileList = `find $audioArchive -type f -print`; foreach $file (@fileList) { chomp($file); # The RubyRip setup is format/genre/year/artist/album/title # Constructing for MythMusic in genre/artist/album/title @rubyRip = split('/', $file); $mythMusicPath = join('/', ($mythMusic, $rubyRip[4], $rubyRip[6], $rubyRip[7])); next if ($rubyRip[8] == 'ripping.log'); # Make first the directory structure genre/artist/album under mythMusic # and the symbolic link to the song titles. `mkdir -p "$mythMusicPath"`; # -p no error on existing. Save Cyles with first -x check? if ($@) { print "ERROR Making Directory: $@\n"; exit (1); } # Now link the file.. [HARD LINKS] `ln "$file" "$mythMusicPath/$rubyRip[8]"`; if ($@) { print "ERROR Linking: $@\n"; exit (1); } } # Update perms `chown -R mythtv.mythtv "$mythMusic"`; `find "$mythMusic" -type d -exec chmod 555 {} \\;`; `find "$mythMusic" -type f -exec chmod 444 {} \\;`;
Using MythMusic
MythMusic is fairly simple to use. It is recommended that you insert the CD before selecting "Import CD". You should also ensure that your system doesn't try to automount the CD and begin playing it automatically.
Playlist Management
Create/Saving a playlist.
You may enter the playlist management screen by pressing 3 from the "Play Music" screen or by selecting the "Select Music" option from the Music Tools menu.
Browse the entire collection from "All My Music". Add tracks to the current queue by pressing 'Select' to toggle the checkbox next to it's name. Entire Albums, Genres or Artists may be added in one go.
When you are happy with the selection you have chosen, scroll down to "Active Play Queue" and press any key. Type in the playlist name and then select "Copy to New Playlist".
Edit an existing playlist.
From the playlist management screen, browse existing playlists from "All My Playlists". Highlight the playlist and press the I/Menu key. Select "Move to Active Play Queue" from the menu. You can now modify the "Active Play Queue" like normal, adding songs and playlists by selecting them from the song tree.
When you are done, highlight the "Active Play Queue" in the selection tree and press the I/Menu then select "Save Back to Playlist Tree".
- Rearrange the songs in a playlist. Highlight a song and hit the "space" bar, the song will now have pair of red arrows in front of it. Use the up and down arrow keys to move it around in the playlist. When you have it where you want it, hit the "space" bar again.
- Delete an item from a playlist. Highlight the item in the selection tree and hit the "d" key.
- Edit a text field without a keyboard. Press ENTER in the empty line edit control. A keyboard will pop up; you can use this keyboard to enter characters.
- Delete a playlist. Highlight the playlist in the selection tree and hit the I/Menu key then select "Delete this Playlist" from the popup.
Visualizations
There are currently a number of visualizations for MythMusic that will be displayed in a small window when while the playlist is visible, but will be displayed full-screen when you change the visualization mode with by pressing '6'. Which of these visualizations are to be used can be specified as a space-separated list in the Setup menu for MythMusic.
- Random - Switches to a different visualization for each song.
- MonoScope - Standard spectrum analyzer, as found on many MP3 players such as XMMS and WinAmp.
- StereoScope - Another spectrum analyzer. Left and right channels are drawn separately.
- BumpScope - Similar to Monoscope above, but drawn as a "raised relief" on a flat surface (3D visualization)
- Goom - The classic visualization of crazy lines and patterns.
- Synaesthesia - A more amorphous visualization similar to plasma clouds displays
- Spectrum -
- Squares -
- AlbumArt - This displays the album art for the currently playing music. Basically, any image in the same directory as the music file currently playing is treated as if it might be album art, and one is selected randomly for display.
- Gears - It's the GLXgears demo.
- Blank - Just a blank screen (not very exciting, but very CPU-efficient).
Missing Visualizations after upgrading from 0.19 to latest SVN? The visualizations are now selectable via the Setup menus and by default you won't have any selected. Navigate to Setup > Media Settings > Music Settings > Player Settings and on the third page you'll find the Edit Visualizations button where you can select which visualizations you'd like to show up as options.
Looking for more? If you're running 0.21 or higher you can use libvisual visualizations. An easy way to get some is to install the amarok-visualisation package which will add quite a few good ones to your Available Visualizations list.
You might find it helpful to see the page on ProjectM visualisations
Shuffle Modes
- None - plays songs in sequential order
- Rand - plays songs in random order
- Smart - plays songs in smart order. Smart order is calculated using following components, each component weight can be configured in MythMusic Player settings:
- Rating - songs with greater rating are played more
- Play Count - songs with smaller play count are player more
- Last Play - songs not heard recently are played more
- Random - random component
- Album - plays songs from the current album in random order
- Artist - plays songs from the current artist in random order
Useful keys to know
- some keyboard commands that might come in handy..
- Change Visualisation mode - 6
- Change Shuffle mode - 1
- Change Repeat mode - 2
- Edit Playlist menu - 3
- Blank Screen - 5
- Increase track rating - 9
- Decrease track rating - 7
- Refresh music tree - 8
- Filter all my music - f or m
- Show incremental search dialog - CTRL + S
- Incremental search find next match - CTRL + N
- Edit Track Information(mp3 tags) - i
- Pause/unPause - p
- Stop - o
- Next - z
- Mute - | (shift-\ also called "pipe")
- Volume Up - ] or F11
- Volume Down - [ or F10)
- > and < for next and previous track in a playlist. This is especially helpful if you use random track selection -- it will jump to the next (or previous) track in the random list.
- (note these are based on the default key mappings)
Troubleshooting
You may run into errors when running MythMusic.
When I run MythMusic and try and look up a CD, I get an error message
The full text of the message will say:
databasebox.o: Couldn't find your CD. It may not be in the freedb database. More likely, however, is that you need to delete /.cddb and /.cdserverrc and restart mythmusic. Have a nice day.
If you get this message, you should go to the home directory of whatever user MythMusic is running as and type:
rm .cdserverrc rm -rf .cddb/
These files aren't automatically deleted because of a conscious design decision by the author that programs that automatically delete things are bad.
The files are used to locally cache CD lookups. If you are re-inserting CDs, your machine will not actually have to go out to the Internet to determine what is on them. However, the URL used to access the freedb database has recently changed, so the stale information in the files from previous runs of MythMusic would cause the error above. Once the files have been deleted the stale information will be gone and your local database will be rebuilt as you use CDs.
The default cddb server in .cdserverrc doesn't seem to be working very well all the time, here's a list of servers you can add:
SERVER=cddbp://freedb.freedb.org:8880/ CDDB SERVER=http://freedb.freedb.org:80/~cddb/cddb.cgi CDDB SERVER=cddbp://at.freedb.org:8880/ CDDB SERVER=http://at.freedb.org:80/~cddb/cddb.cgi CDDB SERVER=cddbp://ca.freedb.org:8880/ CDDB SERVER=http://ca.freedb.org:80/~cddb/cddb.cgi CDDB SERVER=cddbp://cz.freedb.org:8880/ CDDB SERVER=http://cz.freedb.org:80/~cddb/cddb.cgi CDDB SERVER=cddbp://no.freedb.org:8880/ CDDB SERVER=http://no.freedb.org:80/~cddb/cddb.cgi CDDB SERVER=cddbp://uk.freedb.org:8880/ CDDB SERVER=http://uk.freedb.org:80/~cddb/cddb.cgi CDDB SERVER=cddbp://us.freedb.org:8880/ CDDB SERVER=http://us.freedb.org:80/~cddb/cddb.cgi CDDB