HydrogenAudio

Hosted Forums => foobar2000 => 3rd Party Plugins - (fb2k) => Topic started by: deus-ex on 2018-01-14 16:14:00

Title: OpenMPT Module Decoder
Post by: deus-ex on 2018-01-14 16:14:00
Hi kode54,

I just compared foo_openmpt54 (https://www.foobar2000.org/components/view/foo_openmpt54) with its predecessor foo_dumb (https://kode54.net/fb2k/), so far the experience in terms of speed and quality is quite satisfying. However I found a couple features missing:


Would you mind adding these to foo_openmpt as well? That would be great.

As always, thank you very much for your time, dedication and efforts, it's highly appreciated.
Title: Re: OpenMPT Module Decoder
Post by: kode54 on 2018-01-15 21:29:01
1. Can be fixed by changing the configuration option to "1", but I added a workaround for setting it to "0".
2. Fixed.
3. Fixed.
4. Fixed.
Title: Re: OpenMPT Module Decoder
Post by: mudlord on 2018-01-16 07:38:49
How accurate is this compared to say bubsy's shenanigans when it comes to XM/S3M/MOD?
Title: Re: OpenMPT Module Decoder
Post by: deus-ex on 2018-01-16 11:47:58
Thank you for adding the requested features.

1. Can be fixed by changing the configuration option to "1", but I added a workaround for setting it to "0".
That was the first thing I tried before posting. According to the description 1 = nearest, 2 = linear, 4 = cubic, 8 = sync, but there is no setting for "interpolation OFF" available. Your mentioned workaround for v0.4.0-pre.3+1 does not work, i.e. the setting does NOT accept value "0".

I just noticed that the interpolation setting also accepts values 3, 5 and 7 which are supposed to be rejected.
Title: Re: OpenMPT Module Decoder
Post by: deus-ex on 2018-01-16 18:59:19
Just checked the update v0.4.0-pre.3+2, which now sports its own configuration dialog, like foo_dumb.

A binary comparison of the output of v0.4.0-pre.3+1 (interpolation = 1) with v0.4.0-pre.3+2 (interpolation = 0) provides bit-identical results. Turns out the interpolation term "nearest" was just a little misleading, IMHO "none" is definitely the better choice.

Thank you very much for your swift response. (virtual hat off)
Title: Re: OpenMPT Module Decoder
Post by: kode54 on 2018-01-17 00:01:36
Enjoy the real configuration dialog (you'll need to change your settings from defaults again), and enjoy the new pattern visualization, whose renderer was carefully ported from the official OpenMPT XMPlay plugin, to a UI Element of my own design, based on the foo_gep SPC visualization's design. It takes system colors, or foobar2000 Default UI colors, based on background, selection, and text colors.
Title: Re: OpenMPT Module Decoder
Post by: Slender on 2018-01-17 09:48:55
More a general OpenMPt question than anything, but I've noticed that modules that have short, chippy samples, such as dunderklumpen.xm by Loonie, have a bit of an attack added on to their samples, which can sound yucky with some modules, something that DUMB didn't do before. I'm curious why? Is it something the original tracker did? Additionally, the attack seems to be module dependent, chip 7.xm by Saxxonpike doesn't do it.
Title: Re: OpenMPT Module Decoder
Post by: kode54 on 2018-01-17 10:36:13
Try reducing or turning off volume ramping, but note that many XMs will sound bad without it, since the tracker implemented it and many composers assume it will be featured in the player.
Title: Re: OpenMPT Module Decoder
Post by: deus-ex on 2018-01-17 10:50:22
Enjoy the real configuration dialog (you'll need to change your settings from defaults again) [...]
I did not had to update the settings, those were transferred from v0.4.0-pre.3+1 to v0.4.0-pre.3+2. It might be noteworthy that I update foobar2000 and user components manually only, except for the initial installation of foobar2000 which probably makes a difference regarding the preservation of the settings.

[...] enjoy the new pattern visualization [...]
Awesome! After all these years we get to have a live pattern viewer. That's a neat surprise. Thank you very much!
Unfortunately I have to report a bug regarding the pattern visualization right away:



I'd like to suggest a couple items regarding the pattern visualization. I leave it to your expertise and motivation whether these are feasible, of course:

Title: Re: OpenMPT Module Decoder
Post by: Sergey77 on 2018-01-17 16:32:25
Hi kode54,

Thank You for your work!
I have the following comments:

1. In the attachment the MOD file that DUMB and OpenMPT opens incorrectly in the number of 64 separate modules.
XMPlay opens it correctly like one module. Check, please.

2. Could you make pattern visualization for Columns UI ?

Best regards.
Title: Re: OpenMPT Module Decoder
Post by: kode54 on 2018-01-18 02:00:46
Quick Note: My foo_openmpt has been renamed to foo_openmpt54. You'll need to uninstall the previous one and install the new one separately to get future changes. The update checker cannot do this for you.

Enjoy the real configuration dialog (you'll need to change your settings from defaults again) [...]
I did not had to update the settings, those were transferred from v0.4.0-pre.3+1 to v0.4.0-pre.3+2. It might be noteworthy that I update foobar2000 and user components manually only, except for the initial installation of foobar2000 which probably makes a difference regarding the preservation of the settings.
You may need to reset the filter setting, since it's probably the only default you changed.

[...] enjoy the new pattern visualization [...]
Awesome! After all these years we get to have a live pattern viewer. That's a neat surprise. Thank you very much!
Unfortunately I have to report a bug regarding the pattern visualization right away:

  • foobar2000 crashes upon attempt to advance the playlist when reaching the end of any module AND if the next playlist item is a module OR if the current module is going to be repeated
  • The crash does NOT occur if the next playlist item is not a module OR if the user forces to advance to the next/previous playlist item OR if the user creates/loads a new playlist before the currently played module reaches its natural end.
This crash bug has been fixed by shifting to use of proper STL shared_ptr for the module instances that are shared with the pattern viewer, rather than attempting to use my own piss-poor reference counting mess.

I'd like to suggest a couple items regarding the pattern visualization. I leave it to your expertise and motivation whether these are feasible, of course:

1. Color customization for the highlight bar
Currently, the highlight bar is just an InvRect. I could add more color customization, or even change it so it's a custom inverse that only inverts the brightness and not the hue, or so the alpha level can be customized.

2. Font, style and size customization (foobar2000 default UI settings seem not to apply)
It needs to be a fixed width font, for obvious reasons. Style and size can be customized, I guess. They're currently inherited from the dialog defaults. I need to make them inherit from the panel settings.

3. Option for continuous pattern display
Currently, it only renders one pattern at a time, and it can only know what the current pattern is. Knowing future or past patterns would require charting out the entire song, and I don't know if there's a fast way to do that with libmodplug. I could ask their developers if there's a way to do that easily. Considering that there are modules that progress in a non-linear fashion, and even progress backwards.
4. Display presets for 4/8/16/32/64 channels with varying detail (similar to Impulse Tracker UI)
It currently changes detail automatically, depending on how many channels the song has, and how wide you make the window.

5. Context menu allowing for quick change of continuous pattern display and channel presets
Yeah, I could add a context menu, but then I'd need to add the settings you mentioned. I'd also need to add font settings, and restrict that dialog to displaying fixed width fonts, defaulting to what it currently has hard coded, Lucida Console.

Hi kode54,

Thank You for your work!
I have the following comments:

1. In the attachment the MOD file that DUMB and OpenMPT opens incorrectly in the number of 64 separate modules.
XMPlay opens it correctly like one module. Check, please.
This is up to libmodplug and its subsong detection capability. I could discard short subsongs, but then what if someone actually does want short subsongs? Please report this one to the OpenMPT project, as it is an issue in their library. I can report it for you, though.

2. Could you make pattern visualization for Columns UI ?
I make no guarantees, as I don't use Columns UI, and I have no components on hand to base a Columns UI dockable panel on.
Title: Re: OpenMPT Module Decoder
Post by: deus-ex on 2018-01-18 11:32:48
This crash bug has been fixed [...]
Many thanks.

Currently, the highlight bar is just an InvRect. I could add more color customization, or even change it so it's a custom inverse that only inverts the brightness and not the hue, or so the alpha level can be customized.
Well, whatever you think suits the purpose best. If I can assist you in testing various solutions or get another opinion I'm glad to help you out.

It needs to be a fixed width font, for obvious reasons.
There should be a couple system fonts available sufficient for the task. Perhaps you can add support for a fixed set of system fonts that meet the requirements? Again, I'm happy to assist and provide feedback if required.

I could ask their developers if there's a way to do that easily. Considering that there are modules that progress in a non-linear fashion, and even progress backwards.
Yes, please do ask. For example Milky Tracker (http://milkytracker.titandemo.org/downloads/) has optional support for continuous pattern display. Its source code should provide some clues if required.

It currently changes detail automatically, depending on how many channels the song has, and how wide you make the window.
Yes, I noticed. I would like to be able to use the available space of a fixed size window efficiently. Displaying pattern data of a 4-channel module leaves a lot space of a fixed size window unused.

Yeah, I could add a context menu, but then I'd need to add the settings you mentioned.
No problem, if you don't see fit for it then just leave it be. I just threw some ideas for discussion, I'm aware that not every suggestion gets realized for one reason or another.

I make no guarantees, as I don't use Columns UI, and I have no components on hand to base a Columns UI dockable panel on.
I can point you to some Columns UI plugins that I regularly use since many years without any issues:

Title: Re: OpenMPT Module Decoder
Post by: Sergey77 on 2018-01-18 14:29:08
This is up to libmodplug and its subsong detection capability. I could discard short subsongs, but then what if someone actually does want short subsongs? Please report this one to the OpenMPT project, as it is an issue in their library. I can report it for you, though.
Dear kode54,
I suggest to solve this problem, I think it is actual.
For example, there are several such MODs in my collection. I think others people also have such.
If you think that will help, please report to OpenMPT project about the issue.
By the way ZXTune Player http://www.foobar2000.org/components/view/foo_input_zxtune (http://www.foobar2000.org/components/view/foo_input_zxtune) works correctly.

I can point you to some Columns UI plugins that I regularly use since many years without any issues:
Dear deus-ex, thanks for the support )

Best regards.
Title: Re: OpenMPT Module Decoder
Post by: deus-ex on 2018-01-18 15:19:02
Almost forgot another essential Default/Columns UI plugin that I use. A lighter version was created by Case:

Title: Re: OpenMPT Module Decoder
Post by: kode54 on 2018-01-18 19:28:37
ZXTune doesn't use DUMB or OpenMPT, it uses XMP (not to be confused with XMPlay) for some module support. How fast does it scan for subsongs? This should be fast.

E: Added back the muting control, now with pitch and tempo.

Before anyone asks, I did not intend to override the official component, or to stealthily upgrade people using the stable version. In fact, I don't intend to continue using the SVN / prerelease version of libopenmpt. I only wanted it for the J2B quick fix that was added late in the game. As soon as a stable release is out, hopefully also with fixes for these spurious subsong detection issues, assuming I don't have to add a length threshold and possibly lose wanted short subsongs, I'll forcibly deprecate this whole 0.40-pre.* line, and link against a stable release.
Title: Re: OpenMPT Module Decoder
Post by: deus-ex on 2018-01-20 12:53:30
Will you continue to compile and release updates of foo_openmpt via the foobar2000 components page, or will you retreat from contributing altogether and leave it with the OpenMPT developers (https://lib.openmpt.org/libopenmpt)?
Title: Re: OpenMPT Module Decoder
Post by: kode54 on 2018-01-21 04:30:24
No, I'll release updates to my fork as foo_openmpt54, as I have been for several releases now. I was asked to rename my component, because they got pissed off that the auto updater replaced their component with mine, especially since it's based on "unstable" "pre-release" code. I tend to think that bleeding edge is sufficient for daily use, but will be force-deprecating these 0.40-pre plugins when a new stable release appears.
Title: Re: OpenMPT Module Decoder
Post by: mudlord on 2018-01-21 06:07:30
17:02 <+mudlord> i found a tagging bug
17:02 <+mudlord> with titleformat syntax
17:03 <+mudlord> i thought anything in [ ] is to be cleared if its not present
17:03 <+mudlord> so adding a - in there makes the - present even when it shouldnt be
17:05 <+mudlord> no
17:05 <+mudlord> its a openmpt bug


Simple repro : [%artist% -] %title%
The "-" is present when that field should be completely NULL.
Title: Re: OpenMPT Module Decoder
Post by: deus-ex on 2018-01-21 06:11:42
I was asked to rename my component, because they got pissed off that the auto updater replaced their component with mine, especially since it's based on "unstable" "pre-release" code. I tend to think that bleeding edge is sufficient for daily use, but will be force-deprecating these 0.40-pre plugins when a new stable release appears.
Are you telling us you wouldn't be pissed off if it was the other way around? I was under the impression that this is a amicable coop between you and the OpenMPT developers, but apparently that assumption was wrong. If so I recommend you to take a step back and rethink your point of view.
Title: Re: OpenMPT Module Decoder
Post by: kode54 on 2018-01-22 01:36:38
Apparently, it would have been an amicable form of cooperation if I had kindly asked first and waited a few months to release anything with their blessing. I also have a friend who doesn't even know that I marked foo_dumb as obsolete on the components repository, so he doesn't know that every component update will attempt to delete it from his system, nor does he know why I did that.

It makes me think that I'm a hypocrite, because I want to tell others what software they can use on their systems, but not have others do the same to me.
Title: Re: OpenMPT Module Decoder
Post by: arch21 on 2018-02-27 17:09:09
I can't play compressed module (.gz and .lha which I happened to know from un4seen forum) with foo_openmpt54. I can play it with foo_dumb. I wonder if it's the limitation of libopenmpt as official component (foo_openmpt) doesn't seem handle these files. Thanks. Regards.
Title: Re: OpenMPT Module Decoder
Post by: kode54 on 2018-02-28 01:03:46
You need a .gz or a .lha archive component to read those. foo_dumb requires the same. Please upload a non-working file so I may examine it.
Title: Re: OpenMPT Module Decoder
Post by: arch21 on 2018-02-28 03:57:48
The samples are here (http://www.amp.dascene.net/downmod.php?index=135717) and here (http://aminet.net/package/mods/xceed/Sensuality). Originally got from this forum (http://www.un4seen.com/forum/?topic=15425.550). Yes, I'm aware about the required archive reader components. Regards.
Title: Re: OpenMPT Module Decoder
Post by: kode54 on 2018-02-28 23:44:44
Ah, right, I don't support Amiga style filenames with this plugin. I wasn't even aware I supported them with foo_dumb. I guess I can work around that.
Title: Re: OpenMPT Module Decoder
Post by: kode54 on 2018-06-19 03:44:47
Updated again, to match the official plugin, and now with minimum subsong length threshold, so you don't get spammed if you don't want to.
Title: Re: OpenMPT Module Decoder
Post by: Sergey77 on 2018-06-19 05:25:21
Hi!
@kode54, in the attached some mod files still more than one item at the playlist.
please notice.
Thanks.
Title: Re: OpenMPT Module Decoder
Post by: no9 on 2018-06-19 10:37:15
Yeah, let us disable them without time limit too.

And ability to 'loop track X times if its duration is less than Y seconds' would be nice for some chiptunes.
Title: Re: OpenMPT Module Decoder
Post by: kode54 on 2018-06-20 01:35:42
Really? You want to disable subsongs altogether? Just because of a handful of buggy songs? Fine, but I'm leaving them enabled by default. And my other player, Cog, is going to be hardcoded to enable them.

e: These look like legitimate subsongs, unplayed songs you wouldn't know about otherwise without a tracker. Did you even bother to play them?
Title: Re: OpenMPT Module Decoder
Post by: Sergey77 on 2018-06-20 06:14:04
Really? You want to disable subsongs altogether? Just because of a handful of buggy songs? Fine, but I'm leaving them enabled by default.
I think to add the option enable/disable support for subsongs would be a good solution (enabled by default).
Thanks.
Title: Re: OpenMPT Module Decoder
Post by: no9 on 2018-06-20 07:27:35
Really? You want to disable subsongs altogether? Just because of a handful of buggy songs?

Sure. It was a 'hack'. Usually used in game music/jingles or hidden pranks. I have playlist with 4000+ .mod files and I'm not sure if there is a single song part I really need to access that way. Don't need to be default, but being able to get rid of them would be nice and... why not?
Title: Re: OpenMPT Module Decoder
Post by: kode54 on 2018-06-20 22:09:26
I'll consider it.
Title: Re: OpenMPT Module Decoder
Post by: no9 on 2018-06-23 08:22:09
Additional issue subsongs create are File Operations. Let's say I sort playlist by size to delete all songs from disk (physically) that are shorter than certain length and it includes subsongs. Then the whole file disappears.
Title: Re: OpenMPT Module Decoder
Post by: kode54 on 2018-06-24 09:27:53
Either lodge a feature request for fileops, or don't actually delete your files if they're short. I can still disable the subsong matching, but there will be different behavior once libopenmpt 0.4.0 is released.
Title: Re: OpenMPT Module Decoder
Post by: Sergey77 on 2019-01-08 05:03:49
I can still disable the subsong matching, but there will be different behavior once libopenmpt 0.4.0 is released.
Hi! @kode54,
Please consider when releasing the component update the implementation of the following:
1. Pattern visualization for Columns UI The Columns UI SDK (https://yuo.be/columns_ui)
2. Add the option enable/disable support for subsongs
Thanks in advance!

Title: Re: OpenMPT Module Decoder
Post by: kode54 on 2019-01-08 10:09:53
@Sergey77

1. I'll look into it, but it really shouldn't be any harder than implementing something to host a resizable child window to fit into any dialog. I have no idea how to make a CUI visualization pop out or pop in.
2. I don't really know why this is a problem any more, the detection algorithm is way more relaxed and less likely to screw up, as of 0.4.0. Even if I disable reporting any subsongs other than the first, it will never play the "entire" module without subsongs. Note that you need to completely remake all your manual playlists for these changes to take effect.
Title: Re: OpenMPT Module Decoder
Post by: Sergey77 on 2019-01-08 13:38:21
@Sergey77
1. I'll look into it, but it really shouldn't be any harder than implementing something to host a resizable child window to fit into any dialog. I have no idea how to make a CUI visualization pop out or pop in.
Nothing more than the standard contents of the openmpt123 window with the ability to select the background and font color.
It would be quite enough as in the pic.
Title: Re: OpenMPT Module Decoder
Post by: kode54 on 2019-01-09 02:17:24
Not doing that. I'll do what I already do for the Default UI. Except I won't have the benefit of regularly using it as a test platform, since I don't use Columns UI.
Title: Re: OpenMPT Module Decoder
Post by: Rollin on 2019-01-10 16:07:47
It seems that new version 0.4.0+2 makes fb2k to crash. Not always, but under certain conditions. In combinations with some other plugins maybe. But i already removed plugins that were reported by troobleshooter as problematic.
Sometimes crash report is generated and sometimes it is just "Runtime error", so even no crash report is generated.
After manually removing foo_openmpt54 - no more crashes.
It is combination of foo_openmpt54 and foo_whatsnew that makes fb2k crash
Example of crash report is attached.
Title: Re: OpenMPT Module Decoder
Post by: kode54 on 2019-01-11 04:03:52
I already debugged this thanks to someone else. It apparently could crash if Columns UI was not installed, due to how the CUI panel service is instantiated, and my use of static_api_ptr_t on some CUI services. I have added a try/catch block around that, and blocked off the destructor from doing the same thing if the constructor didn't succeed at it. This should prevent the crashes. Unfortunately, you'll have to delete the component or replace it with a fresh download from foobar2000's Safe Mode.
Title: Re: OpenMPT Module Decoder
Post by: Sergey77 on 2019-01-11 17:29:46
@kode54, thank you so much for implementing the Module Visualizer panel for Columns UI. This is a very good and long-awaited addition!
We hope you will not leave it without modifications and improvements.
The only point, please allow users to choose the background and font color. The proposed default color may be someone not comfortable for the eyes.
Thank you again!
Title: Re: OpenMPT Module Decoder
Post by: kode54 on 2019-01-12 00:37:43
It currently uses system default colors, as the CUI SDK did not really make it clear to me how it would be able to query for any colors by any other means. It does have a listener to monitor for settings changes, but apparently I don't know how to query for arbitrary colors. Open Source example code, or Pull Requests with changes, either one or both are welcome.
Title: Re: OpenMPT Module Decoder
Post by: Slender on 2019-01-12 20:35:33
Looks like the component is yours as of 0.5, kode54. :) https://lib.openmpt.org/libopenmpt/2019/01/12/future-of-foo_openmpt/
With that being said, if possible I'd like a place where prerelease builds of libopenmpt are built if they're intention is to pass the component on to you, I liked trying them out which was partially why I stuck with the official component.
Title: Re: OpenMPT Module Decoder
Post by: kode54 on 2019-01-14 03:02:15
I'd need a buildbot configuration for Appveyor to do that.
Title: Re: OpenMPT Module Decoder
Post by: Slender on 2019-01-21 12:08:45
Feature request. Would it be possible to restore the expose file info as multi value tag setting from foo_dumb? That setting made sample and instrument texts much nicer to read, for me at least.
Title: Re: OpenMPT Module Decoder
Post by: kode54 on 2019-01-23 01:08:20
How? There were no tag dialogs in the default configuration which displayed that information in a meaningful way in a normal dialog. You had to open a second dialog from the first one to see the instrument and sample names in a list.
Title: Re: OpenMPT Module Decoder
Post by: Slender on 2019-01-23 06:51:07
Expose file info as multi value tag displayed instrument and sample texts in one large tag called instrument or sample, rather than several individual tags for each sample or instrument text.
Title: Re: OpenMPT Module Decoder
Post by: kode54 on 2019-01-24 09:21:45
I'll think about it.
Title: Re: OpenMPT Module Decoder
Post by: Slender on 2019-05-28 04:37:35
It looks like I've found a glitch that seems to be oddly specific to foo_openmpt54, foo_openmpt isn't doing this. In bahgdad boogie.it, http://modland.com/pub/modules/Impulsetracker/Yannis%20Brown/bahgdad%20boogie.it, a cymbal in the module seems to get held down forever when it shouldn't. The glitch starts around 0:32.
Title: Re: OpenMPT Module Decoder
Post by: kode54 on 2019-05-29 04:44:01
And you're sure you've updated? And as you can update and install them both independently, you're sure you've tested both plugins correctly?
Title: Re: OpenMPT Module Decoder
Post by: Slender on 2019-05-29 08:12:55
Yes. My copies of foo_openmpt and foo_openmpt54 are both on 0.4.5. I used the decoding panel to disable foo_openmpt54 and played the module with foo_openmpt, the glitch didn't occur there. I then did the reverse, disabling foo_openmpt and using foo_openmpt54, and the glitch occurred. Though I did notice that the version of the components repository got bumped but there was no commit to the Bitbucket repository, could that be related?
Title: Re: OpenMPT Module Decoder
Post by: kode54 on 2019-05-29 08:47:14
*shrug* They use the same library, and are audibly identical to my ears. Are you sure you don't have DUMB installed somehow?
Title: Re: OpenMPT Module Decoder
Post by: Slender on 2019-05-29 17:51:58
Yes, I do, but it's disabled. I tried removing it, and the glitch is still occurring in openmpt54 only. This is what the glitch sounds like.
Title: Re: OpenMPT Module Decoder
Post by: kode54 on 2019-05-30 00:42:49
And I'm saying that particular issue doesn't happen here. In fact, it sounds like it should be caused by a bug that was just fixed by 0.4.5 of the upstream library. Please verify from the Components page of Preferences that both "OpenMPT component" and "OpenMPT component (kode54 fork)" list version of 0.4.5.
Title: Re: OpenMPT Module Decoder
Post by: Slender on 2019-05-30 01:49:16
Yes, both say 0.4.5.
foo_openmpt.dll (2019-05-29 07:05:31 UTC)
    OpenMPT component 0.4.5
foo_openmpt54.dll (2019-05-29 07:05:16 UTC)
    OpenMPT component (kode54 fork) 0.4.5
Title: Re: OpenMPT Module Decoder
Post by: kode54 on 2019-05-30 03:03:53
What about your settings for my component?

Also, to be sure we're using the same test file, a sha256 sum.

6e5bedb948b710af0d0f305301379057bef10877d08d856bb646d17fa35fd2e8  bahgdad boogie.it

E: Also, a screen shot of your Preferences -> Decoders page, showing the order of components listed and enabled.
Title: Re: OpenMPT Module Decoder
Post by: Slender on 2019-05-30 04:09:31
SHA256 hash is the same, 6E5BEDB948B710AF0D0F305301379057BEF10877D08D856BB646D17FA35FD2E8.
Component settings.
Sample rate: 48000 Hz.
Channels: Stereo.
Interpolation: linear.
Loops: infinite.
Fade time: 0.
Gain: +10.00 DB.
Separation: 100%.
Volume ramping: Default.
Use Amiga Resampler for Amiga modules: enabled. Here is a screenshot of my decoding preferences page.
Title: Re: OpenMPT Module Decoder
Post by: kode54 on 2019-05-30 04:25:38
Can't reproduce. Please replicate with a portable installation.
Title: Re: OpenMPT Module Decoder
Post by: Slender on 2019-05-30 04:52:00
This is strange. I tried resetting the component's configuration by deleting the .cfg file in the foobar2000 configuration folder. That seems to have resolved the issue for some reason and the file plays normally now. Would love to know what caused that but either way, it's working.
Title: Re: OpenMPT Module Decoder
Post by: Slender on 2019-05-31 04:35:00
I've found what causes the issue. It seems that it only happens when enable playback override in view>OpenMPT control is checked. If the setting isn't enabled, the issue doesn't occur and the file plays normally.
Title: Re: OpenMPT Module Decoder
Post by: kode54 on 2019-06-01 03:12:50
Thanks for helping me find this rather obscure bug. It has to do with the fact that the override was unmuting all channels on startup by default. Now the control, in interactive mode, will probe the interactive instance for which channels should be muted on startup, and will make the override control invert those channels, so they start as muted, and may be manually unmuted.

Yes, this song has a bunch of channels that are ordinarily muted, and apparently contain unwanted or later unused notes.

Big difference between DUMB and OpenMPT here: I don't think DUMB and the muting system I implemented ever allowed unmuting channels specified as muted by the file itself, whereas OpenMPT does allow that.
Title: Re: OpenMPT Module Decoder
Post by: iridescentaudio on 2019-08-22 10:34:14
Quick question,
I have looping enabled (set to "1") and a fade time of 10000ms. I'm curious as to why the fades sound erratic, with an unusual 'fluttering' sound and speed increase? I can live with it, just that it's unexpected vs. a natural/smooth fadeout, and thought it could be a bug/maybe unintentional? Cheers.
Title: Re: OpenMPT Module Decoder
Post by: Norkkom on 2019-08-24 11:52:57
Perhaps this does not belong here, but I need to ask: is there any solution regarding metadata tagging for tracker files that are read by this component? Plenty of tracker files don't have metadata for even basic info like an artist's name, but this information is of course quite useful when organizing music or sifting through a collection in foobar.
Is there any kind of workaround for this issue, or is it simply a limitation of the formats that must be accepted?
Title: Re: OpenMPT Module Decoder
Post by: iridescentaudio on 2019-08-24 14:02:39
Perhaps this does not belong here, but I need to ask: is there any solution regarding metadata tagging for tracker files that are read by this component? Plenty of tracker files don't have metadata for even basic info like an artist's name, but this information is of course quite useful when organizing music or sifting through a collection in foobar.
Is there any kind of workaround for this issue, or is it simply a limitation of the formats that must be accepted?

It's a limitation that I tolerated with esoteric audio formats for a long time. Then External Tags (http://www.foobar2000.org/components/view/foo_external_tags) came along, and now I use those for everything, even for conventional audio formats that don't require them. Definitely recommend you do the same! I'm just waiting and hoping for foobar2000 mobile to support them, so that ie. tracker formats can have filled-out artist, album, title, cover art etc. there too.
Title: Re: OpenMPT Module Decoder
Post by: Norkkom on 2019-08-24 14:40:04
It's a limitation that I tolerated with esoteric audio formats for a long time. Then External Tags (http://www.foobar2000.org/components/view/foo_external_tags) came along, and now I use those for everything, even for conventional audio formats that don't require them. Definitely recommend you do the same! I'm just waiting and hoping for foobar2000 mobile to support them, so that ie. tracker formats can have filled-out artist, album, title, cover art etc. there too.

Wow! I had no idea such a component existed, this is fantastic! This will absolutely solve my hurdles in organization with my tracker collection  :)
Title: Re: OpenMPT Module Decoder
Post by: kode54 on 2019-08-24 23:07:42
Quick question,
I have looping enabled (set to "1") and a fade time of 10000ms. I'm curious as to why the fades sound erratic, with an unusual 'fluttering' sound and speed increase? I can live with it, just that it's unexpected vs. a natural/smooth fadeout, and thought it could be a bug/maybe unintentional? Cheers.
This is fixed now.
Title: Re: OpenMPT Module Decoder
Post by: arch21 on 2019-11-07 06:42:56
I see the latest foo_openmpt54 supports Amiga style filenames. nice.
could you fix info than displayed on the Codec column? thanks
Title: Re: OpenMPT Module Decoder
Post by: kode54 on 2019-11-08 02:22:50
I don't even set the codec field, the player does that. That means I have to run a second extension check on the file, to see if it has a matching prefix, before assigning that to the "codec" info field. I don't even know if OpenMPT has a simple format detection, I'd shove that in codec instead.
Title: Re: OpenMPT Module Decoder
Post by: Sergey77 on 2020-01-03 16:37:03
Hi there!
@kode54, I really enjoy using your version of the component. I especially like the feature “Dynamic info fields” and of course the "Pattern Display" (as DUI element). But in the case of a limited window size, not all channels are placed in the window of the visualization element "Pattern Display" (see picture).
Could you implement a scrollbar so that we can see all the channels in the limited window size?
Thanks in advance!
Title: Re: OpenMPT Module Decoder
Post by: le_bro on 2020-08-22 11:43:56
@kode54 thanks for this plugin! Can you please fix this issue: %channels% variable is not available while playing tracked music with OpenMPT.
Title: Re: OpenMPT Module Decoder
Post by: deus-ex on 2020-08-22 20:14:41
There's nothing to fix for Kode54. You need to use OpenMPT Module Decoders internal variable %__mod_channels%.
Title: Re: OpenMPT Module Decoder
Post by: le_bro on 2020-08-22 22:27:26
There's nothing to fix for Kode54. You need to use OpenMPT Module Decoders internal variable %__mod_channels%.
which returns quantity of instrument channels, and I mean speaker channels. Oh well, got this fixed with $if(%channels%,%channels%,stereo)
Title: Re: OpenMPT Module Decoder
Post by: kode54 on 2020-08-23 00:45:57
Um, channels is supposed to be reported dynamically too, since it's also user configurable.

EDIT: It already does report channels, as dynamic info. You won't get a static channels info field from my component, because channel count is user configurable, and can be changed any time, while static fields are cached until the file itself is modified.
Title: Re: OpenMPT Module Decoder
Post by: le_bro on 2020-08-23 00:53:04
Um, channels is supposed to be reported dynamically too, since it's also user configurable. I'll add that shortly.
Thanks! :)
Title: Re: OpenMPT Module Decoder
Post by: tonez on 2021-09-08 14:28:37
@kode54, thank you for your work!

I've noticed that sample rate setting doesn't work in some of your plugins including foo_openmpt54. In openmpt54 it is always 48000 Hz regardless of setting value.

The following plugins doesn't change sample rate as well:
Title: Re: OpenMPT Module Decoder
Post by: kode54 on 2021-09-09 02:15:50
That's because your sound output device is outputting 48 kHz. If I output anything else, foobar2000 will just transparently resample it to that anyway.
Title: Re: OpenMPT Module Decoder
Post by: tonez on 2021-09-09 06:43:28
Can it be made to output in sample rate that is specified in plugin settings?
Title: Re: OpenMPT Module Decoder
Post by: tonez on 2021-09-09 16:54:04
Unfortunately I can't make sample rate of my audio device higher. It's limited to 48000 Hz in settings.

But I want to output OpenMPT in 96000 Hz then downsample it to 48000 Hz (sample rate of my audio device). At first glance It may sound as a bad idea. But it depends. For some synthesized audio formats, outputting in higher sample rate may give higher quality. Even if it is downsampled next. Specifically for OpenMPT it depends on how good antialiasing filter works in it. If it works well then output in higher sample rate, of course, is not needed.

As for downsampling to 48000 Hz, good resampler doesn't make any significant quality loss. I programmed simple sinc filter based resampler by myself. I tried to resample 16 bit WAV file to 48000 Hz and then back to 44100 Hz. It was bit to bit exact after resampling.

As far as I know dBpoweramp/SSRC resampler is good enough. So I don't afraid of downsampling to 48000 Hz.
Title: Re: OpenMPT Module Decoder
Post by: kode54 on 2021-09-10 04:49:59
But there is literally no point to doing that, as it already uses a sinc resampler on the modules when synthesizing them. You gain literally nothing useful by oversampling.
Title: Re: OpenMPT Module Decoder
Post by: tonez on 2021-09-10 07:09:42
But what is the point having this setting then?
Title: Re: OpenMPT Module Decoder
Post by: tonez on 2021-09-10 19:40:55
What about 2SF Decoder? It doesn't have sinc filtering. The best you can get from it is linear interpolation. Downsampling makes sense for it. But sample rate can't be changed.

BTW, why was vio2sf replaced by 2sf2wav? vio2sf had sinc resampling. Although sample rate was low (32768) and couldn't be reconfigured.
Title: Re: OpenMPT Module Decoder
Post by: Rollin on 2021-09-10 21:01:54
@tonez you can use WASAPI exlusive output mode (it is built-in in 1.6.7 and available with component for older versions). Then kode54's decoders will respect their samplertae settings and then you can use resampler in DSP to resample to samplerate that is supported by your device.
If you don't want to use WASAPI exclusive output, you can use normal WASPI shared with this component (https://www.foobar2000.org/components/view/foo_out_wasapis). In this case, kode54's decoders will respect their samplertae settings too and resampling to supported  samplerate will be done automatically, but not within decoder.
Edit: corrected link to WASAPI shared output component
Title: Re: OpenMPT Module Decoder
Post by: tonez on 2021-09-10 22:45:30
@Rollin, thank you very much! It works!

Another way is to use older foobar2000 version (v1.6) which doesn't support forcing sample rate.

But it would be better if "use audio device sample rate" was one of the sample rate options in plugin. It can be enabled by default. But if someone wanted to change sample rate, it could do it by changing the settings.
Title: Re: OpenMPT Module Decoder
Post by: kode54 on 2021-09-11 22:30:55
The sample rate option does affect conversion. Just stick to your old version forever.
Title: Re: OpenMPT Module Decoder
Post by: tonez on 2021-09-12 08:07:23
 :'(
Title: Re: OpenMPT Module Decoder
Post by: kode54 on 2021-09-13 00:17:29
Fine, I'll make the default 96k and get rid of this output rate syncing feature.
Title: Re: OpenMPT Module Decoder
Post by: tonez on 2021-09-13 16:05:30
Thank you!
Title: Re: OpenMPT Module Decoder
Post by: Slender on 2022-01-29 13:23:36
Hi, I found a playback override issue recently. It seems that as of libopenmpt 0.6,, this file plays too fast when enable playback override is checked, but when it's disabled it plays normally. http://ftp.modland.com/pub/modules/Screamtracker%203/Mystical/in%20a%20world%20of%20crystals.s3m
Title: Re: OpenMPT Module Decoder
Post by: kode54 on 2022-01-29 22:27:10
Reported upstream. I do nothing unusual with the interface, except use the interactive extended interface for changing the tempo factor. Are you sure you haven't set tempo to greater than 100%?

Edit: Okay, sorry. I didn't realize you'd have to be interfacing the dialog with a screen reader. Apparently it's not doing a very good job of indicating that the tempo is above 100%. There's also a handy reset button to restore 100% to both sliders. At least, I hope the button is handy to someone using a screen reader. I haven't actually tested any of my code with screen readers, unfortunately.
Title: Re: OpenMPT Module Decoder
Post by: Slender on 2022-01-30 02:45:59
Yes, I have pressed the reset button and the issue persists. Looking at this further, it looks like it seems that it may have something to do with the muting issue I found some time ago being reintroduced. bahgdad boogie.it is broken again, unmuting channels specified as muted when the playback override is enabled, resulting in hanging notes. Regarding screen reader accessibility, the OpenMPT control is usable but could use some improvements. The two issues I've noticed are that the controls for the dialog are hidden from keyboard navigation and can't be accessed using tab and shift+tab, and the checkboxes for the channels are all labelled as "check1," rather than channel 1, channel 2, etc. Labeling them with channel names if the module specifies them would be nice as well.
Title: Re: OpenMPT Module Decoder
Post by: kode54 on 2022-01-31 07:14:55
Sorry, there was a bug in new OpenMPT regarding the channel mutes on startup. I have fixed it. A new release will be uploaded shortly.
Title: Re: OpenMPT Module Decoder
Post by: Slender on 2022-01-31 11:47:22
Both files are working now, thanks for the fix and the channel labels. :)
Title: Re: OpenMPT Module Decoder
Post by: iycgtptyarvg on 2023-06-02 07:57:45
I saw that lib.openmpt is at v0.7.1. Will this component be updated?
Title: Re: OpenMPT Module Decoder
Post by: n99 on 2023-06-06 14:15:57
Weird bug, but since the components are outdated, not really worthy of a bug report:
Updating this component led to foo_keep_queue's contents to be emptied (on foobar2000 v.1.6.16).
Title: Re: OpenMPT Module Decoder
Post by: marc2k3 on 2023-06-06 15:54:54
I saw that lib.openmpt is at v0.7.1. Will this component be updated?

Yep, https://www.foobar2000.org/components/view/foo_openmpt54
Title: Re: OpenMPT Module Decoder
Post by: Fungo2 on 2023-06-14 16:52:37
I now regret updating foobar2000 and OpenMPT. In the latest version half of the tracks don't even work properly because of some "invalid subsong" error. They all work fine on VLC and the Modo music player that hasn't been updated in years. And they worked fine in the previous version.
Title: Re: OpenMPT Module Decoder
Post by: marc2k3 on 2023-06-14 17:13:58
You can grab old versions from the download page, click View version history.
Title: Re: OpenMPT Module Decoder
Post by: mudlord on 2023-06-14 22:16:53
It would help if, you know, people report bugs rather than moaning. Kinda hard to fix things when people just moan without reporting the bug in the right spots.
Title: Re: OpenMPT Module Decoder
Post by: Case on 2023-06-16 05:39:48
I now regret updating foobar2000 and OpenMPT. In the latest version half of the tracks don't even work properly because of some "invalid subsong" error. They all work fine on VLC and the Modo music player that hasn't been updated in years. And they worked fine in the previous version.
Subsong issue points to logic difference in how a component represents tracks for files where a single module file shows up as multiple tracks in the playlist. I'm quite confident that behavior hasn't changed in foo_openmpt54.
Did you perhaps use something else like foo_dumb for module playback earlier and now when you updated the player you switched to a different module decoder? That would leave at least some old multitrack-enabled tracks in existing playlists inoperational. You can fix that by re-adding the files to the playlist.
Title: Re: OpenMPT Module Decoder
Post by: Sergey77 on 2023-06-22 15:30:18
Hi there!
My current layout for listening tracker music.
-------------------------------------------------
Additional info:

Maybe useful to someone...
Title: Re: OpenMPT Module Decoder
Post by: Perseid on 2023-12-19 21:24:10
Is it possible to get a stereo separation slider added? Listening to 4 channel MODs with headphones has always hurt the ears.
Title: Re: OpenMPT Module Decoder
Post by: LigH on 2024-04-24 21:09:03
Today I noticed a post in the Discord server of the "Nectarine Demoscene Radio", they mentioned a YouTube video: Amazing AMIGA Multichannel Music - MoSeZ - NNZ Collection #1 (https://www.youtube.com/watch?v=o9eVrMP8wEY) - there is an archive of SymMOD modules as well as MP3 versions of the same tracks linked in its description.

Playing the first file (Gloomyness.SymMOD) I noticed that foobar2000 with OpenMPT module decoder 0.7.1 / 0.7.3 plays this song in mono. But the MP3 has a stereo panorama.

I don't know anything about this module format; might it be that its support is incomplete, and the decoder is unable to retrieve the position of instruments in an audio panorama? When I watch the YouTube video of an Amiga tracker it has an analyzer in the center of the screen, displaying dots on concentric rings, which looks like they should present a relation to instrument positions, I guess?