New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support a library (like openmpt or xmp) for Tracker music files playback #967

Closed
Ghabry opened this Issue Aug 2, 2016 · 4 comments

Comments

Projects
None yet
3 participants
@Ghabry
Member

Ghabry commented Aug 2, 2016

This is basicly the only thing that is still handled by SDL mixer.
Some games like AE use them.

Or shall we use libmodplug? I don't really mind, but a non-SDL solution would be great :D

Dependencies:

  • gcc >= 4.3 or clang >= 3.0
  • pkg-config >= 0.24
  • zlib
  • libltdl Hmm :(. Probably not needed when linking static.
  • libogg, libvorbis, libvorbisfile Huu? Why?
  • libmpg123 Huu? Why?
  • doxygen >= 1.8

Basicly all deps can be disabled +1

  --without-zlib          Disable use of zlib.
  --without-mpg123        Disable use of libmpg123.
  --without-ogg           Disable use of libogg.
  --without-vorbis        Disable use of libvorbis.
  --without-vorbisfile    Disable use of libvorbisfile.
  --without-ltdl          Disable the use of libtool libltdl for dynamic
                          loading of third party libraries.
  --without-dl            Disable the use of libdl for dynamic loading of
                          third party libraries.
  --without-pulseaudio    Disable use of libpulse and libpulse-simple.
  --without-portaudio     Disable use of libportaudio.
  --without-portaudiocpp  Disable use of libportaudiocpp.
  --with-sdl2             Enable use of libsdl2.
  --with-sdl              Enable use of libsdl.
  --without-sndfile       Disable use of libsndfile.
  --without-flac          Disable use of libflac.
@fdelapena

This comment has been minimized.

Show comment
Hide comment
@fdelapena

fdelapena Aug 2, 2016

Contributor

+1 to libopenmpt, as it is maintained and more "dead on balls" accurated, but there is a small problem:

  • libmodplug and libopenmpt APIs are different.
  • libopenmpt is not widely packaged on GNU/Linux distros yet.

So, maybe is worth to support both some day. Which one is worth first? Or keep SDL for libmodplug only for selected ports and then consider first libopenmpt for SDL-less ports first?

libltdl is part of libtool for portable dynamic loading (dlopen()) support as documented there.
There are compressed-sampled tracker formats (e.g. for mp3, mod -> mo3) but rare. This got invented some time ago for smaller module files and consumed in the BASS library and XMPlay if I recall correctly. I guess the ogg vorbis dependency is for the same approach. Sincerely, I don't know about any game using them, even probably not supported by audieremony.

Contributor

fdelapena commented Aug 2, 2016

+1 to libopenmpt, as it is maintained and more "dead on balls" accurated, but there is a small problem:

  • libmodplug and libopenmpt APIs are different.
  • libopenmpt is not widely packaged on GNU/Linux distros yet.

So, maybe is worth to support both some day. Which one is worth first? Or keep SDL for libmodplug only for selected ports and then consider first libopenmpt for SDL-less ports first?

libltdl is part of libtool for portable dynamic loading (dlopen()) support as documented there.
There are compressed-sampled tracker formats (e.g. for mp3, mod -> mo3) but rare. This got invented some time ago for smaller module files and consumed in the BASS library and XMPlay if I recall correctly. I guess the ogg vorbis dependency is for the same approach. Sincerely, I don't know about any game using them, even probably not supported by audieremony.

@fdelapena

This comment has been minimized.

Show comment
Hide comment
@fdelapena

fdelapena Aug 2, 2016

Contributor

Update, according to this ticket it says:

libopenmpt is being released under the BSD license and has a libmodplug API compatibility layer, which should make replacing libopenmpt with libmodplug relatively simple

So it could use the legacy API first where possible to support both.

Contributor

fdelapena commented Aug 2, 2016

Update, according to this ticket it says:

libopenmpt is being released under the BSD license and has a libmodplug API compatibility layer, which should make replacing libopenmpt with libmodplug relatively simple

So it could use the legacy API first where possible to support both.

@carstene1ns

This comment has been minimized.

Show comment
Hide comment
@carstene1ns

carstene1ns Aug 2, 2016

Member

I had looked into this a bit further before (after the audio_decoder stuff landed in Player) and have to agree @fdelapena's point that libopenmpt is not really known and used yet. In fact I maintain the AUR package of libopenpmt which has 2 votes yet since beginning of the year.
The libopenmpt api is really simple and useable, so I would not like to use the compatibility layer if possible... No idea if it would be worth to #ifdef the API in the encoder, but instead is it easier (as suggested) to use SDL_mixer in the meantime.

I had another idea back then, but not proposed this before.
The original disharmony and also audioremony support only a very limited set of tracker files.
Disharmony has integrated a modified libmodplug (libdiscord) since 2011, so this changed,
but audioremony still uses DUMB.
This brings us down to only support MOD, S3M, XM and IT and have 99% of all covered.
And fortunately, there is a lib for that: XMP-lite.
The lite version of XMP is available under MIT license, widely portable (works on Wii and PSP 😆) and can be integrated like fmmidi into Player code, to be used whenever there is no openmpt available.

Member

carstene1ns commented Aug 2, 2016

I had looked into this a bit further before (after the audio_decoder stuff landed in Player) and have to agree @fdelapena's point that libopenmpt is not really known and used yet. In fact I maintain the AUR package of libopenpmt which has 2 votes yet since beginning of the year.
The libopenmpt api is really simple and useable, so I would not like to use the compatibility layer if possible... No idea if it would be worth to #ifdef the API in the encoder, but instead is it easier (as suggested) to use SDL_mixer in the meantime.

I had another idea back then, but not proposed this before.
The original disharmony and also audioremony support only a very limited set of tracker files.
Disharmony has integrated a modified libmodplug (libdiscord) since 2011, so this changed,
but audioremony still uses DUMB.
This brings us down to only support MOD, S3M, XM and IT and have 99% of all covered.
And fortunately, there is a lib for that: XMP-lite.
The lite version of XMP is available under MIT license, widely portable (works on Wii and PSP 😆) and can be integrated like fmmidi into Player code, to be used whenever there is no openmpt available.

@carstene1ns carstene1ns self-assigned this Aug 13, 2016

@Ghabry Ghabry changed the title from Support libopenmpt for Tracker music files playback to Support a library (like openmpt or xmp) for Tracker music files playback Sep 4, 2016

@Ghabry

This comment has been minimized.

Show comment
Hide comment
@Ghabry

Ghabry Sep 4, 2016

Member

I reworded the title and close this. Fixed by #1014

Member

Ghabry commented Sep 4, 2016

I reworded the title and close this. Fixed by #1014

@Ghabry Ghabry closed this Sep 4, 2016

@Ghabry Ghabry added this to the 0.5.0 milestone Sep 4, 2016

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment