Home of the Squeezebox™ & Transporter® network music players.
Page 2 of 2 FirstFirst 12
Results 11 to 15 of 15
  1. #11
    Senior Member JoeMuc2009's Avatar
    Join Date
    Jan 2009
    Location
    Marktoberdorf, Germany
    Posts
    105
    Quote Originally Posted by bpa View Post
    For LMS to "know"about a file - it needs to be scanned and that means updating the LMS scanner about MOD. I think you'd be better off converting the MOD files to a know format such as Flac.
    Okay, so this means the scanner is not extensible, right? I think I underestimated the task a bit. Proper support imho means:


    • a directory full of .MOD files can be added just as easily as any other directory containing MP3, OGG, FLAC, whatever
    • MOD files are identified in player devices by their title or file name in the library
    • MOD files are converted in-line as they are selected to be played. Permanent conversion into a different format is not required / not desirable to keep hard disk consumption low and to enable dynamic adding of files to the directory without the need to convert them for making them available
    • tagging functionality is reduced of course but it should be possible to assign a common tag like composer = Amiga or something to make all modules easily selectable
    • it is possible to add MOD files to a playlist just like any other media file
    • while a MOD file is being played, it is possible to jump back and forth in the "timeline"
    • some settings like spatial audio, filters etc. can be adjusted through a dedicated LMS plugin page


    If that's not possible, I can live with it - eventually did so for years now. Listening to the good old modules on my main Hi-Fi set today was kind of gorgeous despite the bad support in the UI.

    Another very stony way out of this mess might be a "virtual" MP3 directory shell extension, similar to many backup solutions which allow to mount their backup archives as a file system in which the user can browse down to any single file. It would present a lot of tagged MP3 files which never actually exist, each of which mirrors a respective .MOD file. The mounted structure could be scanned like a normal directory and LMS's scanner would never know the difference... Okay, this is getting crazy.

    Anyway, thanks anyone for your input.

    Cheers,
    Joe


    PN me if your Boom / Classic / Transporter display has issues!

    LMS 7.9.0 on Windows Server 2012
    1x Squezeebox Classic SB2
    7x Squeezebox Classic SB3 (one waiting for repair)
    7x Squeezebox Boom (two waiting for repair)
    1x Transporter
    2x Controller (one waiting for repair)
    3x Touch (two waiting for repair)
    1x Radio

  2. #12
    Senior Member
    Join Date
    Oct 2005
    Location
    Ireland
    Posts
    15,384
    Roland0's link provides more detail.

    To do most of what you asked - scanner needs to support MOD format. I have never looked at scanner in detail but I believe it cannot be extended by the presence of files of custom code like plugins - it needs the Scan::Audio Perl module to be updated part of which is written in C.

    Conversion of MOD file to a known format would provide the same features with no development effort.

    The "some settings like spatial audio, filters etc. can be adjusted through a dedicated LMS plugin page". I don't know what is special about MOD files - if these are just settings for the MOD transcoder command line - if so then a special plugin/handler is needed. IIRC There have been plugin s which modified the audio stream for all sources (e.g. RC) such as BruteFir or Inguz, these could be alternative starting points.

  3. #13
    Senior Member JoeMuc2009's Avatar
    Join Date
    Jan 2009
    Location
    Marktoberdorf, Germany
    Posts
    105
    Thanks again, it's cool that there are people around willing to share their expertise. Really appreciated!
    I should emphasize that this is purely sentimental. MOD is the format used for trackers, or sequencers, back in the days of 16-bit home computers which had very limited RAM and disk space. A MOD is basically a collection of so-called patterns which contain the sequence of samples (~instruments) to be played in up to four channels, the note values for each entry, plus special commands like volume changes, vibrato, volume / tone slide, arpeggio, play speed etc.
    Patterns are arranged in a list so it is possible to play the same pattern or sequence of patterns multiple times with just one additional byte needed per pattern in the pattern list. So far it is similar to MIDI.
    Eventually the samples, which typically occupy most of the payload, follow one after another in the same file, basically a list of 8-bit (!) waveforms with size info and optional loop info to enable a sample to repeat itself at a given point and restart at another given point to play indefinitely. This is where MOD is fundamentally different from MIDI which relies on samples being stored in the playback machinery, and configured externally such that the right instruments are patched. A MOD would bring its own instruments at all times, ensuring the experience is the same no matter what.
    All this is very economic. A MOD is not a linear audio stream but relies on repetition and saves lots of space by enabling playback of samples at arbitrary frequencies so the same sample can be played in three octaves. Just a few kilobytes of input could give you hours of playback. Plus, it supported creativity a big deal because one could "steal" samples from existing modules to use in one's own, and learn pattern arrangements, effect commands and their overall use from others easily. Associated programs like SoundTracker, ProTracker, StarTrekker etc. made it easy to work with modules. Their results were used in the entire demo scene and most of the games back in the day.
    Amiga computers introduced this technique as far as I remember, and added some "artifacts" like the low-pass filter that was usually engaged on power-up to suppress digital noise interference in the analog outputs, but would also cause the sound to appear pretty muffled. It could be switched off by a command in the MOD file, which is what virtually any composer did in the first step, or even be toggled for effects if needed. Another problem with basically any home computer was that the stereo separation was nearly 100%, i.e. the tracker channels 1 and 4 would play strictly on the left channel, 2 and 3 exclusively on the right. This is almost painful when using headphones. While some of that separation was desirable, the arrangement kind of falls apart. To bring it all closer together, I used to help myself with a resistor placed between the positive terminals of both audio outputs. The sound field got narrower this way of course but with the right resistor value the results were pretty good.
    The same would have to be done in software now because I don't want this permanent resistor in my signal path. Transcoders like XMP handle filter and stereo separation through command line parameters as you stated.

    But I see that I underestimated the effort needed to make it work in LMS as desired. Not a big deal, this is kind of a low-level enthusiast matter, and as hard disk space is no longer a big concern these days, I may convert at least the top 100 modules of my collection to whatever replicates them best at a good compression rate.


    PN me if your Boom / Classic / Transporter display has issues!

    LMS 7.9.0 on Windows Server 2012
    1x Squezeebox Classic SB2
    7x Squeezebox Classic SB3 (one waiting for repair)
    7x Squeezebox Boom (two waiting for repair)
    1x Transporter
    2x Controller (one waiting for repair)
    3x Touch (two waiting for repair)
    1x Radio

  4. #14
    Senior Member
    Join Date
    Oct 2005
    Location
    Ireland
    Posts
    15,384
    Quote Originally Posted by JoeMuc2009 View Post
    But I see that I underestimated the effort needed to make it work in LMS as desired. Not a big deal, this is kind of a low-level enthusiast matter, and as hard disk space is no longer a big concern these days, I may convert at least the top 100 modules of my collection to whatever replicates them best at a good compression rate.
    Thanks for the more detailed explanation of the audio stream and how it is not "usual".

    If you wanted to modify the scanner, you should send a PM to andyg (Andy Grundman) - when he worked for Slimdevices he wrote the Scan Audio module which then got put into CPAN. He has good knowledge in audio formats area. Since there seems to be a decent library "libopenmpt" obtaining the metadata should not be difficult (i.e. no parsing ).

    Not sure how time index to jump to specific time points in the file will work ( IIRC MP3 & Flac it is estimated, MP4 has an index table) but this is normally a command line parameter passed to transcoder.

  5. #15
    Senior Member JoeMuc2009's Avatar
    Join Date
    Jan 2009
    Location
    Marktoberdorf, Germany
    Posts
    105
    Quote Originally Posted by bpa View Post
    ...
    Not sure how time index to jump to specific time points in the file will work ( IIRC MP3 & Flac it is estimated, MP4 has an index table) but this is normally a command line parameter passed to transcoder.
    It's a demanding task to get this right, especially as a track can loop indefinitely. So if the user desires to go to, say, 75%, where is the code supposed to jump then? I really don't know but Winamp (with Oldsk00l plugin) and Modplug can do this rather smoothly and with expected results. Probably they do not respect any loops and just use the slider to navigate to the respective point in the pattern list to start playing right there.
    The special challenge here is that an instrument may keep playing from a previous pattern (the self-looped samples I mentioned earlier), but if you jump to the pattern at the selected position, the instrument is not triggered to play again because that was done in the pattern before. So the code has to look back a little, too, to make this perfect. Also the playback speed (bpm) may be varied in the course of a pattern sequence and if you skip to a pattern that relies on a set speed instead of setting its own, you may find the part of the module playing too fast or too slow.

    Anyway, I'll see when I have more time for this matter.


    PN me if your Boom / Classic / Transporter display has issues!

    LMS 7.9.0 on Windows Server 2012
    1x Squezeebox Classic SB2
    7x Squeezebox Classic SB3 (one waiting for repair)
    7x Squeezebox Boom (two waiting for repair)
    1x Transporter
    2x Controller (one waiting for repair)
    3x Touch (two waiting for repair)
    1x Radio

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •