Welcome, Guest. Please login or register. Did you miss your activation email?

Author Topic: Module music formats  (Read 6490 times)

0 Members and 1 Guest are viewing this topic.

Radnen

  • Newbie
  • *
  • Posts: 17
    • View Profile
Module music formats
« on: July 29, 2013, 01:43:23 am »
I love module music files for their amazing small size to sound quality ratio.

I do propose a solution, not just a request:
I want you to upgrade the sound package of SFML to use audiere since it supports all the current (major) sound types and far, far, far more and it is known to be cross platform and mature, and is opensource/free I think if the license works out for you it would be a great start.

There are other libraries you can use but they have horrendous licensing. I'm using SFML 2.0.Net and I found the supported music/sound types lacking, I can't find any good audio libraries out there. But audiere is great, but no C-sharp bindings exist, plus you'd want to edit the C++ version before you make bindings of it, and so this is again great for that case.

eXpl0it3r

  • SFML Team
  • Hero Member
  • *****
  • Posts: 11034
    • View Profile
    • development blog
    • Email
Re: Module music formats
« Reply #1 on: July 29, 2013, 02:49:10 am »
There are other libraries you can use but they have horrendous licensing. I'm using SFML 2.0.Net and I found the supported music/sound types lacking, I can't find any good audio libraries out there. But audiere is great, but no C-sharp bindings exist, plus you'd want to edit the C++ version before you make bindings of it, and so this is again great for that case.
If SFML were to provide playback for mod formats, it would also use an external library, since it's a rather complex thing to get this done properly and SFML's focus is not on reinventing the wheel all over and over again.

You can take a look at libmodplug (GPL) - see my CMake compatible version - and for combinding it with SFML, you can take a look at sfMod - or as well take a look at my version with support for CMake.
But since you're using C#, I'm not sure how you'll be using things. Maybe you can port sfMod to C# itself.

If you find a good library that has a more open license let me know.
Official FAQ: https://www.sfml-dev.org/faq.php
Official Discord Server: https://discord.gg/nr4X7Fh
——————————————————————
Dev Blog: https://duerrenberger.dev/blog/

Laurent

  • Administrator
  • Hero Member
  • *****
  • Posts: 32498
    • View Profile
    • SFML's website
    • Email
Re: Module music formats
« Reply #2 on: July 29, 2013, 07:34:07 am »
Since Audiere also handles playback, why don't you use it directly? Actually it would be weird to build SFML on top of it, since SFML is more low-level than Audiere.
Laurent Gomila - SFML developer

Radnen

  • Newbie
  • *
  • Posts: 17
    • View Profile
Re: Module music formats
« Reply #3 on: July 30, 2013, 01:54:46 am »
I'm using C sharp, there are no good sound libraries out there for it. I guess I can try to make my own bindings.

zsbzsb

  • Hero Member
  • *****
  • Posts: 1409
  • Active Maintainer of CSFML/SFML.NET
    • View Profile
    • My little corner...
    • Email
Re: Module music formats
« Reply #4 on: July 30, 2013, 02:39:19 pm »
I'm using C sharp, there are no good sound libraries out there for it. I guess I can try to make my own bindings.

I find that statement very hard to believe, just considering FFMPEG alone and what it can do. Look at my signature for the VideoStreamer I made with FFMPEG and I wrote my own simple bindings, but if you do not want to write your bindings there are already a good number of FFMPEG .NET bindings out there.

And getting past FFMPEG there is irrKlang, BASS, NAudio, Alvas.Audio, AudioLab, SoundTouch, and how many others out there. But you say there is no good libraries?
« Last Edit: July 30, 2013, 02:42:24 pm by zsbzsb »
Motion / MotionNET - Complete video / audio playback for SFML / SFML.NET

NetEXT - An SFML.NET Extension Library based on Thor

Radnen

  • Newbie
  • *
  • Posts: 17
    • View Profile
Re: Module music formats
« Reply #5 on: July 31, 2013, 09:06:51 am »
I'm using C sharp, there are no good sound libraries out there for it. I guess I can try to make my own bindings.

I find that statement very hard to believe, just considering FFMPEG alone and what it can do. Look at my signature for the VideoStreamer I made with FFMPEG and I wrote my own simple bindings, but if you do not want to write your bindings there are already a good number of FFMPEG .NET bindings out there.

And getting past FFMPEG there is irrKlang, BASS, NAudio, Alvas.Audio, AudioLab, SoundTouch, and how many others out there. But you say there is no good libraries?

They are not free for commercial use. The latter half lack the types of files I want to play. And anything GPL is a nightmare.

I've been looking around for a free to use; open source; multi-format playback; mono compatible library and I have yet to find one. Now I wonder why SFML has such a limited # of types! Outside of wav and ogg you have virtually nothing that fits the bill.

:/

Laurent

  • Administrator
  • Hero Member
  • *****
  • Posts: 32498
    • View Profile
    • SFML's website
    • Email
Re: Module music formats
« Reply #6 on: July 31, 2013, 09:23:03 am »
Do module files require an external instrument bank, like MIDI?
Laurent Gomila - SFML developer

Radnen

  • Newbie
  • *
  • Posts: 17
    • View Profile
Re: Module music formats
« Reply #7 on: July 31, 2013, 10:07:20 am »
No; they do not. Sometimes you come across large module files since high-quality instruments and other samples were packed in with them. It's a very portable filetype - even though there and hundreds of them. The major players are .it, .mod, .xm, and .s3m

The rest are variations or not often seen.

I mean I'm okay with wav and ogg - you can 'render' midi and module music to those types, but it bloats filesize and I can't force someone to convert their songs if they don't want to - it's not just for me this feature but for a community of game makers.

Laurent

  • Administrator
  • Hero Member
  • *****
  • Posts: 32498
    • View Profile
    • SFML's website
    • Email
Re: Module music formats
« Reply #8 on: July 31, 2013, 10:17:24 am »
If instruments and samples are packed into the music files directly, they can't be shared right? So how do you keep music files small if instruments and samples are duplicated in each of them?
Laurent Gomila - SFML developer

Radnen

  • Newbie
  • *
  • Posts: 17
    • View Profile
Re: Module music formats
« Reply #9 on: July 31, 2013, 10:21:17 am »
If instruments and samples are packed into the music files directly, they can't be shared right? So how do you keep music files small if instruments and samples are duplicated in each of them?

No they can be shared. The files are small since only the instruments needed (no more than 32, say) are stored and the instruments aren't that huge ~a few kb's in space.

If you want to do a bit of light reading here's a wikipedia page: http://en.wikipedia.org/wiki/Module_file

Laurent

  • Administrator
  • Hero Member
  • *****
  • Posts: 32498
    • View Profile
    • SFML's website
    • Email
Re: Module music formats
« Reply #10 on: July 31, 2013, 10:59:09 am »
Ok, thanks for the extra information.

I've added a task in the tracker.
Laurent Gomila - SFML developer

 

anything