Patch: MusicImport/mp3: Small fixes and enhancements (1 Viewer)

scoop

Retired Team Member
  • Premium Supporter
  • November 14, 2004
    614
    7
    Country flag
    Hi,

    I know it's not even a 24 hours ago since the music import feature has been added to current CVS, but since I'm in need of this functionality I started testing with it right away :)

    The file names and directory names created by the music import feature are derived from the album info / metadata from the inserted CD. Some times, the album information may contain characters which cannot be used as file and directory names. If this is the case, then nothing happens. Nothing happens, because the try/catch block which saves a track to MP3 doesn't do anything with a generated exception.

    To work around this problem, I've added a function to MusicImport.cs which filters out those invalid characters from the variables used to created the file names and directory names. During debugging I also added a Log.Write() in the catch-part for saving a track.

    The patch is submitted @ sourceforge here.

    Kind regards,
    Michel
     

    mzemina

    Retired Team Member
  • Premium Supporter
  • February 23, 2005
    2,065
    14
    Tulsa, OK
    United States of America United States of America
    Re: Patch: MusicImport/mp3: remove invalid chars from Album

    scoop said:
    ... doesn't do anything with a generated exception.
    That is GREAT that you are working to get the best out of the plugin. I clap my hands to you. Good job!

    Mike
     

    scoop

    Retired Team Member
  • Premium Supporter
  • November 14, 2004
    614
    7
    Country flag
    Hi,

    I just added another small fix, which should solve the issue that the CD drive isn't unlocked if you cancel the import process.

    I also added the possibility to control the CD Import feature with the remote or mouse by adding the actions to the context menu. The additions to the context menu are dynamic in a sense that they only show up if the current drive is a CD-ROM drive and the current selected item isn't a folder. The option to cancel the ripping appears only in the context menu when ripping.

    I had to add 3 new strings to the language strings.xml file for the texts in the context menu. Those are:
    Code:
    <string><id>3101</id><value>Import CD</value></string>
    <string><id>3102</id><value>Import Track</value></string>
    <string><id>3103</id><value>Cancel Import</value></string>
    The updated patch is available at the same place. For those who are on current CVS and want to give it a try, the modified windowplugins.dll plus required language update is available here.

    Kind regards,
    Michel
     

    SiLenTYL

    Retired Team Member
  • Premium Supporter
  • April 23, 2004
    1,144
    159
    Melbourne
    Australia Australia
    Country flag
    hi there

    great work mPod and scoop !

    i understand it runs with hardware error correction, but if a track isnt picked up (ie. scratched disc, whatever) ....it will just keep trying to read the track forever....except if i press "c" (cancel), which results in an exception and MP to crash to desktop.....so can we force a "skip" if it takes too long?

    also a "completed" or "completed - 1 track skipped" dialogue popup(or something like that), would be great
     

    egonspengleruk

    Retired Team Member
  • Premium Supporter
  • June 30, 2005
    250
    0
    Thought I might try out the competition :)

    How do I select the tracks to import? I saw from the website note that you have to
    "mark a track, hit "i" to import track, "d" to import whole disc, "c" to cancel import."
    How do I mark a track?
    And after looking through the code, I saw that a context menu option has been added to remove the need for a keyboard.....but how do I bring that up?
    I have clicked on PlayCD and then on Playlist to show all the files on the CD...but if I right click on any of these tracks then nothing happens....I would expect the context menu to appear here.

    Also, as far as my attempt at the ripping plugin went, the only thing mPod's is missing is a Rip CD button under the Play CD. This gives the user a very simple one click way to rip an entire CD. From a GUI perspective the user should only (IMHO) have to worry about selecting tracks if they only want to rip particular tracks.
     

    scoop

    Retired Team Member
  • Premium Supporter
  • November 14, 2004
    614
    7
    Country flag
    Hi,
    egonspengleruk said:
    How do I select the tracks to import? I saw from the website note that you have to
    "mark a track, hit "i" to import track, "d" to import whole disc, "c" to cancel import."
    How do I mark a track?
    After entering My Music, you see the configured folders on the right. Click on your CD-ROM to enter the drive. Next, it'll do an artist/album/track lookup. After that, you're presented with all the tracks on the CD. There, just highlight the desired track with the arrow keys. Next, press F9 or the button that brings up the context menu on the remote. You can also right click with the mouse to bring up the context menu. From the context menu, you can choose to rip the highlighted track, or the entire CD.

    The context menu changes to only contain "Cancel Import" if ripping is in progress.

    egonspengleruk said:
    Also, as far as my attempt at the ripping plugin went, the only thing mPod's is missing is a Rip CD button under the Play CD. This gives the user a very simple one click way to rip an entire CD. From a GUI perspective the user should only (IMHO) have to worry about selecting tracks if they only want to rip particular tracks.
    I avoided adding a button on the left, since that would require a change to all the skins. I chose the easy way out: the context menu. ;)

    Kind regards,
    Michel
     

    egonspengleruk

    Retired Team Member
  • Premium Supporter
  • June 30, 2005
    250
    0
    Cheers for that Scoop. Have it ripping a CD now.
    Personally I would prefer a Rip CD button....:p :p
    Also, there is no progress bar or anyway to letting the user know how the ripping is going. Thats the only other thing I had done differently to mPod's version.
    Also got a bug report for yer :) Jack Johnson's "In Between Dreams" album has a hidden track that doesnt appear via the FreeDB lookup. It just calls the track "?". When this is ripped, because you cant have "?" in a filename, your code replaces it with a space. Might be worth adding a check to see if the string of the track title = " "...and if so then force the title to be "unknown"

    Egon
     

    Smirnuff

    Portal Pro
    December 7, 2004
    630
    3
    United Kingdom
    Guys you do realize that mPod isn't done with this yet? I feel as though you are critiquing something way before the developer has finished. Maybe I'm wrong but wanted my $0.02...
     

    egonspengleruk

    Retired Team Member
  • Premium Supporter
  • June 30, 2005
    250
    0
    Smirnuff said:
    Guys you do realize that mPod isn't done with this yet? I feel as though you are critiquing something way before the developer has finished. Maybe I'm wrong but wanted my $0.02...
    In my defence there isnt anything to say this on any forum post I could find....so we werent to know :)
     

    scoop

    Retired Team Member
  • Premium Supporter
  • November 14, 2004
    614
    7
    Country flag
    Hi Smirnuff,

    I understand submitting patches within 24 hours after something has been added to CVS can be seen by the developer as interfering with his/her work. If that's the case then I apologise and blame my enthusiasm for this feature. By no means it is meant as criticizing mPod's work.

    Kind regards,
    Michel
     

    Users Who Are Viewing This Thread (Users: 0, Guests: 1)

    Top Bottom