Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

AppGameKit Classic Chat / How to use SoundFont in AGK?

Author
Message
Plystire
21
Years of Service
User Offline
Joined: 18th Feb 2003
Location: Staring into the digital ether
Posted: 10th Aug 2013 06:46
For the current Intel App Innovation contest I'm finding myself in need of utilizing SoundFonts or DLS. SoundFont would work out great if I could only figure out how to use it in AGK. Does anyone know if that's a possibility?


~Plystire

A rose is only a rose until it is held and cherished -- then it becomes a treasure.
JimHawkins
14
Years of Service
User Offline
Joined: 26th Jul 2009
Location: Hull - UK
Posted: 10th Aug 2013 09:43
SoundFonts are pretty old technology.

You would have to use C++ or Pascal to do this, because you will need to use the DirectMusic SDK - this will handle DLS/DLS2 audio banks.

Synchronising this with AppGameKit could be a serious problem because music synthesis requires microsecond timing and can be pretty CPU-intensive. How precise does your program need to be?

-- Jim DO IT FASTER, EASIER AND BETTER WITH AppGameKit FOR PASCAL
Plystire
21
Years of Service
User Offline
Joined: 18th Feb 2003
Location: Staring into the digital ether
Posted: 11th Aug 2013 00:20
Something as simple as playing a note when the user touches the screen.

I had hoped to be able to play several channels at a time for at least 3 instruments.

If soundfonts are going to be a problem, are there any alternatives I should be aware of?


~Plystire

A rose is only a rose until it is held and cherished -- then it becomes a treasure.
World Class Multimedia
15
Years of Service
User Offline
Joined: 15th Aug 2008
Location: Florida, USA
Posted: 11th Aug 2013 00:35 Edited at: 11th Aug 2013 00:42
Quote: "SoundFonts are pretty old technology"


It is used in many current synths and romplers. It may be old, but it is current and used in the mainstream by musicians and composers.

Although the latency on Android is pretty bad (though they are working on it), latency on IOS, Mac and PC is just fine for all music applications (note that there are tons of high end music apps for iPads and iPhones. There are even very good audio apps for Android). Playing soundfonts is a file loading and MIDI playback issue. If a loader and MIDI implementation were written for AppGameKit to load and play soundfonts, they would work just as well as any wav or mp3 file.

To create your app, currently, you would be better off with a visual language such as Synthedit. It allows you to create all manners of synths and editors and can play wav files and soundfonts. This, however, is PC only, so if you're aim is to play on mobile devices, this is NOT the way to go.

I, too, would LOVE to use soundfonts in AGK. It would be, for me, the ultimate command set since I create virtual instruments (www.supersynths.com) and would love to use AppGameKit to get my instruments to the mobile platform.

Mike

YOU DREAM IT - WE CREATE IT!
www.world-class-multimedia.com
For world-class virtual instruments - www.supersynths.com
Plystire
21
Years of Service
User Offline
Joined: 18th Feb 2003
Location: Staring into the digital ether
Posted: 11th Aug 2013 01:23
Thanks for the clarification, WCM.

Synths are what I would like to use, but if it's going to be problematic I need to look for alternatives. Platform isn't an issue right now since the application will be targeting an All-In-One running Windows.


~Plystire

A rose is only a rose until it is held and cherished -- then it becomes a treasure.
World Class Multimedia
15
Years of Service
User Offline
Joined: 15th Aug 2008
Location: Florida, USA
Posted: 11th Aug 2013 03:16
Quote: "Thanks for the clarification, WCM.

Synths are what I would like to use, but if it's going to be problematic I need to look for alternatives. Platform isn't an issue right now since the application will be targeting an All-In-One running Windows.


~Plystire"


Then you should use Synthedit. It is PERFECT for what you want to do. It will compile to a .dll which can be loaded using any host. A good free stand alone host is SAVIHOST (google it for download). It lets you run the exported .dll as a stand-alone executeable, instead of using a DAW or sequencer.

If you need guidance, feel free to ask. Several of my instruments were created with Synthedit.

Mike

YOU DREAM IT - WE CREATE IT!
www.world-class-multimedia.com
For world-class virtual instruments - www.supersynths.com
Plystire
21
Years of Service
User Offline
Joined: 18th Feb 2003
Location: Staring into the digital ether
Posted: 11th Aug 2013 10:13
Hmm, I looked into SynthEdit and I'm not entirely sure what I'm looking at. I'm new to the digital music scene so most of it is all greek to me.

All I'm wanting to do is play musical notes when the user touches the screen... basically low notes on the left of the screen, high notes on the right of the screen. I'm not trying to make anything terribly more complicated than that. I'd use WAVs for the notes if it weren't for the fact that there would be tons of sounds to load in, and it wouldn't be easy to add more instruments.


~Plystire

A rose is only a rose until it is held and cherished -- then it becomes a treasure.
JimHawkins
14
Years of Service
User Offline
Joined: 26th Jul 2009
Location: Hull - UK
Posted: 11th Aug 2013 14:09
Whatever you do you'll have to load the data. Soundfonts can be very big. There's no real problem if you only want to run on a PC or Mac - make it as big as you like.

Actually, you can do amazing things with very small wave-tables if they are well designed. The Apple ][ AlphaCentauri system used 256 byte tables and sounded not at all bad.

Nowadays I have soft-synths that are several gigabytes in size.

Tell us exactly what you want to do and I'm sure we can help.

-- Jim DO IT FASTER, EASIER AND BETTER WITH AppGameKit FOR PASCAL
World Class Multimedia
15
Years of Service
User Offline
Joined: 15th Aug 2008
Location: Florida, USA
Posted: 11th Aug 2013 18:12
Synthedit is a visual language. You connect wires together to make things happen.

There are many, many examples you can use as a starting point. What you want to do may 'sound' easy, but it's not easy at all when multisamples come into play.

If you want to do it in AppGameKit, use wave files and then assign variables for each and every one - even if there are hundreds of them - and then you can just call those variables with the playsound command. Should be rather easy to create that.

Why not start small and just use 8 or 10 samples with 8 or 10 squares on screen and once that is working, expand the number of samples, zones, etc.

Mike

YOU DREAM IT - WE CREATE IT!
www.world-class-multimedia.com
For world-class virtual instruments - www.supersynths.com
Plystire
21
Years of Service
User Offline
Joined: 18th Feb 2003
Location: Staring into the digital ether
Posted: 12th Aug 2013 00:02
Thanks, guys. I think I might have to go the WAV route.

Played around with SynthEdit demo and after about an hour the best thing I was able to make was quite possibly the most annoying sound I've ever heard.

Might be best to put off creating my own sounds until I can get the hang of it. Now I just need to find some place online where I can find (hopefully royalty free) instrument notes in wave format.


~Plystire

A rose is only a rose until it is held and cherished -- then it becomes a treasure.
BatVink
Moderator
21
Years of Service
User Offline
Joined: 4th Apr 2003
Location: Gods own County, UK
Posted: 24th Aug 2013 15:55 Edited at: 24th Aug 2013 15:55
Plystire, have you got your App Innovation entry in order? Kevin Priddle has responded to your entry requesting more input.

I would also make a bigger deal about how successful AppGameKit was in the last competition, it shows that you have the right tools to finish your app. I have an entry in the same competition here. Good luck!

SoftMotion3D
AGK Developer
18
Years of Service
User Offline
Joined: 24th Aug 2005
Location: Calgary,Alberta
Posted: 26th Aug 2013 23:48
If you look at qmidistudio for agk... It utilizes wave files to reproduce tones.... If you have a sampler such as I do, you could just record a set of tones easy enough.

The actual challenge is dealing with having only 100 wave files max that can be loaded in at one time. But I managed to get 5 instruments running at the same time on my blackberry...In sync with timing

Plystire
21
Years of Service
User Offline
Joined: 18th Feb 2003
Location: Staring into the digital ether
Posted: 27th Aug 2013 07:35
@BatVink:

Wow, completely missed the registration form! Thanks for pointing out the comment.


@SMD_3D:

Don't have a sampler handy.
I'm currently using FMod alongside AGK(Tier 2) and it is working out quite well thus far.


~Plystire

A rose is only a rose until it is held and cherished -- then it becomes a treasure.
JimHawkins
14
Years of Service
User Offline
Joined: 26th Jul 2009
Location: Hull - UK
Posted: 27th Aug 2013 09:22
There thousands of free instrument samples available on-line.

-- Jim DO IT FASTER, EASIER AND BETTER WITH AppGameKit FOR PASCAL

Login to post a reply

Server time is: 2024-05-09 20:16:24
Your offset time is: 2024-05-09 20:16:24