Scrolling Game Development Kit Forum

SGDK Version 2 => General Discussion => Topic started by: 2dgamer on 2008-02-01, 09:10:29 AM

Title: selling games and fmod
Post by: 2dgamer on 2008-02-01, 09:10:29 AM
Hi, i have a question regarding distribution of games made with sgdk2.  Im seeing that sgdk2 is under the gpl, but it also uses the fmod sound library, which is closed and propietary, and maybe I am wrong, but fmod requires a license fee for commercial use.  Does that affect games made with sgdk2? 

thanks in advanced
Title: Re: selling games and fmod
Post by: durnurd on 2008-02-01, 12:34:12 PM
If you plan on making a game using SGDK2 and FMOD and plan on selling it, then yes, it would affect you.  You would presumably have to pay the licensing fee based on whether you were selling it on a website or on store shelves.  However, you can also use other audio libraries.  FMOD is only supplied as a simple solution for the free game developer.  For example, DirectSound, while not currently updated, still exists in the latest version of DirectX, and is completely free.

If, on the other hand, your game is being distributed for free, then FMOD is also free to go along with the game.  When you start charging for your product, then FMOD starts charging you, and hopefully the sales you make are enough to recoup the sales of the game.  I imagine that most if not all SGDK2 games will be distributed freely, at least for now.  Later, other sound libraries may be customized to work with SGDK2 as well, so that the user has the choice of which to use.  For now, however, FMOD is the only built-in solution because SGDK2's author is not expecting too many games to be built soon with it that will be charging a lot of money for their game.
Title: Re: selling games and fmod
Post by: bluemonkmn on 2008-02-02, 10:16:53 AM
And let me re-emphasize/clarify, in order to use an alternative sound solution, no change to the SGDK2IDE is necessary, just updated code within your project.
Title: Re: selling games and fmod
Post by: Tanja on 2008-02-02, 11:42:09 AM
and would someone please give me an example how to do that? (maybe a good new topic for the help files)
Title: Re: selling games and fmod
Post by: 2dgamer on 2008-02-02, 06:45:49 PM
Yea, I second that last post, it'd be great to have a tutorial on implementing another sound library in SGDK.  It's not so much that I would like to sell the games i make with sgdk, it's more of a coherent licensing theme between SGDK itself which is under the GPL, and the games it produces, which in theory arent.  Could another sound library, let's say, SDL, be included as a replacement for fmod?

thanks
Title: Re: selling games and fmod
Post by: bluemonkmn on 2008-02-03, 08:36:18 AM
One thing to consider is the ability of the library to play sounds from a memory buffer rather than from a file.  SGDK2 projects can do either, but it works better to be able to play from a memory buffer if you like having all your data in a single EXE file.  Not being familiar with SDL, I can't give all the details right now, but if someone had a simple C# sample program that played a sound using some sound library, I could tell you how/if that sample could be integrated into an SGDK2 project.
Title: Re: selling games and fmod
Post by: 2dgamer on 2008-02-03, 02:06:25 PM
One thing to consider is the ability of the library to play sounds from a memory buffer rather than from a file.  SGDK2 projects can do either, but it works better to be able to play from a memory buffer if you like having all your data in a single EXE file.  Not being familiar with SDL, I can't give all the details right now, but if someone had a simple C# sample program that played a sound using some sound library, I could tell you how/if that sample could be integrated into an SGDK2 project.

I did some research on the web, and came up with this, I dont know if this is what you mean:

http://trinidad.delphigl.com/index.php?url=openalcs.php&lang=english (http://trinidad.delphigl.com/index.php?url=openalcs.php&lang=english)

It's a program for c# that plays sound using OpenAL.  Please let me know if it's useful.

I found this too:

http://taoframework.com/ (http://taoframework.com/)

It's a .net framework that uses many free libraries, openal included.  Dunno if that one will be useful.
thanks
Title: Re: selling games and fmod
Post by: bluemonkmn on 2008-02-03, 03:55:37 PM
Actually, I believe that OpenTK (the library that I'm using to implement OpenGL in SGDK2) also includes a wrapper for OpenAL, so when I'm done converting SGDK2 to use OpenGL, I may also implement support for OpenAL, since it's included in the same library.  I don't know anything about OpenAL yet, so it's hard to say whether it will eliminate the extra dll (fmod has fmodex.dll).  OpenTK's OpenGL implementation, I assume, relies on System32\opengl.dll, which is part of the operating system, so it doesn't need to be delivered.  However I don't see an OpenAL.dll in System32, so The OpenAL wrapper may be a little different; I'm not sure how that'll work out.  In any case, I will look into it when it seems to be the feature that most people want next (which may be after I release SGDK2 for OpenGL).

It does appear that OpenAL supports buffers, so it should be able to load samples in memory rather than linking directly to a file, but I'm not sure what formats it will support.  (FMOD supports MP3, OGG, MOD, MID -- all my favorite formats.)
Title: Re: selling games and fmod
Post by: 2dgamer on 2008-02-03, 05:12:03 PM
well, openal installs a openal32.dll in c:\winnt\system32, i know that for sure.  And openal does support those file formats too, so no worry there.  I would tend to prefer the ogg format, since it's open, provides better quality than mp3, and, for game developing makes more sense than mp3s. 
Title: Re: selling games and fmod
Post by: Tanja on 2008-02-04, 09:40:45 AM
In any case, I will look into it when it seems to be the feature that most people want next (which may be after I release SGDK2 for OpenGL).

imho this would be a good next step in development.
Title: Re: selling games and fmod
Post by: 2dgamer on 2008-02-04, 10:52:08 AM
Do you have some sort of roadmap as to when would that be?
Title: Re: selling games and fmod
Post by: bluemonkmn on 2008-02-04, 06:22:07 PM
I'm just taking each step as it comes.  I suspect that after the OpenGL stuff is done, I'll want to wrap up some smaller things again before moving on to the next big thing.  Some of the smaller things on the list are:
Title: Re: selling games and fmod
Post by: 2dgamer on 2008-02-04, 09:46:12 PM
I dont see implementing OpenAL in SGDK2 in there   ;D  Well, yea, i guess you have to take it one at a time.  I just hope its not so far down the road.
Title: Re: selling games and fmod
Post by: durnurd on 2008-02-04, 11:04:46 PM
I dont see implementing OpenAL in SGDK2 in there   ;D  Well, yea, i guess you have to take it one at a time.  I just hope its not so far down the road.
Probably because that's not one of the "smaller things on the list".  But remember, he's not the only one who can work on it.
Title: Re: selling games and fmod
Post by: bluemonkmn on 2008-02-05, 05:56:20 AM
But remember, he's not the only one who can work on it.

A fact I myself often forget.  I am rather protective of the SGDK2 code that gets published on my site, but in this case, especially because it doesn't involve changing SGDK2 source code, it should be relatively easy for someone to provide a workable solution that supports OpenAL (in the form of a Source Code object template).

I am, BTW, even open to including others' modifications to SGDK2 itself (in the primary distribution); it's just that they will have to conform to pretty rigorous standards if I'm going to include it in a product I expect to be working with for a long time (and having my name on it) :).  Of course anybody is free to modify SGDK2 because it's open source, but only the best would be included.

Fortunately, it's possible to do a lot of things in version 2 that you couldn't in version 1 without even touching the SGDK2 IDE's primary source code.  This is one of them.
Title: Re: selling games and fmod
Post by: 2dgamer on 2008-02-07, 08:09:53 PM
Well, I would gladly work on the openal implementation if i could do it, but i need to learn c# first. :P  So I'm relying on bluemonkmm at the moment, or on anyone else who might want to do so.