djr33
01-31-2010, 05:03 AM
I need what seems like a very basic setup, but has turned out to be a complete problem in every way. I have been working on this (now and then) for well over a month and now nonstop for about 2 days. I have found nothing that works in a real cross-browser environment.
There are only two requirements:
1. Users can go to a page on my site and hit a record button and click upload.
2. Those files can be played back also on my site.
I found a Java applet that records audio and submits it to the website. This is good and works for what I need.
It can submit in a few formats, but basically it's going to be a standard codec in .wav [even uncompressed if that is necessary]
I then need to find a way to play it back to the user (with controls).
As we all know this can be difficult to make fully cross browser, so I have tried the following:
1. Quicktime:
Though this used to be a standard method for embedding, the mac vs. pc war has now reached a state of complete idiocy:
On Windows 64 bit machines, the play controls for embedded QT plugins are black. Yes, that's right-- apple has not fixed this (it's a known issue) and so quicktime is out, unless you have an alternate solution for any Windows 64bit user.
2. Flash:
This seems like the answer. But flash only supports mp3 (and aac?). Theoretically other formats are possible (especially with the newest versions of flash), but there are no players available for them.
Of course we could convert it with a program, but this needs to be dynamic: they upload, then they can play it. Done.
3. The only flash wav player I could find:
http://blog.datacompboy.ru/2009/11/29/asterisk-records-flash-player-wavplayer-1-6-1/
Sorry, it's in Russian.
http://blog.datacompboy.ru/u/WavPlayer/sample.html
There's a demo.
This actually WORKS! but for some reason it crashes Internet Explorer. I don't know how to fix it.
So, back to where we started. Nothing.
4. Convert uploaded .wav to .mp3?
LAME is a library that does just that: but it appears to be a legal gray area and it also requires a dedicated server to install (assuming everything does go well).
5. Upload using Flash?
But of course there's something wrong with this too: the only way flash will upload is to a streaming server, for which the software costs $4500 from Adobe. Of course there is an open source version floating around out there, but it requires also a dedicated server, and some sort of front end that I can't code (and seems to be at least $100 to buy).
Then there are format issues with this and playing it back means being stuck in the proprietary codec within flash (nellymoser) which costs over $7000 to get a license to use. There are again open source workarounds, but this seems messy.
Then there's still the issue of playing it back, but at this point I suppose we'd have something that would work in flash.
The goals:
While not every user necessarily needs to be able to upload using the website, because they can just upload a pre-recorded wav file, every user needs to be able to listen to the file.
For this reason a Java applet (which is not perfect, but works at least) is ok, because there are alternatives.
But I don't want something that messy for the playback.
In fact, the Java applet has a player option, but I'd like to not require Java for users who are just playing back the audio.
Note: the reason I need this is to setup a site where users can have voice messages in their profile. (It's a bit more complex than that, but from there I can figure out the rest once PHP can start doing it's job.)
I've looked at this from every angle (I think), and I can't find any good solutions, so just suggest somewhere to start if you know.
I'd be willing to pay something for this, but I don't have a $1000+ budget like is required for the professional solutions.
If someone wants to create something (for example, a flash player) that will serve my purposes, we could negotiate a fee (something like $100?) if it covers everything.
The most basic solution would be a working flash player (or debugging the Russian one above) that plays wav files.
There may be a "best" solution to this (perhaps paying a lot of money for something) for the future, but for the launch of the site I just want it to work for everyone. After that, we can move on to figuring out the best approach and keeping filesize down, etc.
Again, the current status is that using the Russian flash player above I can play uncompressed wavs using the Java uploader in every browser except internet explorer, which either crashes or just does nothing.
Note: these sound files will not be long. I would like at least 1 minute (maximum), and certainly never anything more than 3-5 minutes.
There are only two requirements:
1. Users can go to a page on my site and hit a record button and click upload.
2. Those files can be played back also on my site.
I found a Java applet that records audio and submits it to the website. This is good and works for what I need.
It can submit in a few formats, but basically it's going to be a standard codec in .wav [even uncompressed if that is necessary]
I then need to find a way to play it back to the user (with controls).
As we all know this can be difficult to make fully cross browser, so I have tried the following:
1. Quicktime:
Though this used to be a standard method for embedding, the mac vs. pc war has now reached a state of complete idiocy:
On Windows 64 bit machines, the play controls for embedded QT plugins are black. Yes, that's right-- apple has not fixed this (it's a known issue) and so quicktime is out, unless you have an alternate solution for any Windows 64bit user.
2. Flash:
This seems like the answer. But flash only supports mp3 (and aac?). Theoretically other formats are possible (especially with the newest versions of flash), but there are no players available for them.
Of course we could convert it with a program, but this needs to be dynamic: they upload, then they can play it. Done.
3. The only flash wav player I could find:
http://blog.datacompboy.ru/2009/11/29/asterisk-records-flash-player-wavplayer-1-6-1/
Sorry, it's in Russian.
http://blog.datacompboy.ru/u/WavPlayer/sample.html
There's a demo.
This actually WORKS! but for some reason it crashes Internet Explorer. I don't know how to fix it.
So, back to where we started. Nothing.
4. Convert uploaded .wav to .mp3?
LAME is a library that does just that: but it appears to be a legal gray area and it also requires a dedicated server to install (assuming everything does go well).
5. Upload using Flash?
But of course there's something wrong with this too: the only way flash will upload is to a streaming server, for which the software costs $4500 from Adobe. Of course there is an open source version floating around out there, but it requires also a dedicated server, and some sort of front end that I can't code (and seems to be at least $100 to buy).
Then there are format issues with this and playing it back means being stuck in the proprietary codec within flash (nellymoser) which costs over $7000 to get a license to use. There are again open source workarounds, but this seems messy.
Then there's still the issue of playing it back, but at this point I suppose we'd have something that would work in flash.
The goals:
While not every user necessarily needs to be able to upload using the website, because they can just upload a pre-recorded wav file, every user needs to be able to listen to the file.
For this reason a Java applet (which is not perfect, but works at least) is ok, because there are alternatives.
But I don't want something that messy for the playback.
In fact, the Java applet has a player option, but I'd like to not require Java for users who are just playing back the audio.
Note: the reason I need this is to setup a site where users can have voice messages in their profile. (It's a bit more complex than that, but from there I can figure out the rest once PHP can start doing it's job.)
I've looked at this from every angle (I think), and I can't find any good solutions, so just suggest somewhere to start if you know.
I'd be willing to pay something for this, but I don't have a $1000+ budget like is required for the professional solutions.
If someone wants to create something (for example, a flash player) that will serve my purposes, we could negotiate a fee (something like $100?) if it covers everything.
The most basic solution would be a working flash player (or debugging the Russian one above) that plays wav files.
There may be a "best" solution to this (perhaps paying a lot of money for something) for the future, but for the launch of the site I just want it to work for everyone. After that, we can move on to figuring out the best approach and keeping filesize down, etc.
Again, the current status is that using the Russian flash player above I can play uncompressed wavs using the Java uploader in every browser except internet explorer, which either crashes or just does nothing.
Note: these sound files will not be long. I would like at least 1 minute (maximum), and certainly never anything more than 3-5 minutes.