Skip to main content

Sounds again

12 replies [Last post]
francoislionet
Offline
Joined: 2008-01-13

Hello,

Bjoern (who comes to this forum often) has sent me a sound sample file, and he says that this file plays under PowerDVD using a HSound with the usual method to open and play the sound.
It crashes under WinDVD Platinum.
The sound sample is a .PCM file.
So I sent this sound sample to my associate Yves, who he good at low level things. He tells me that this sound sample is just the raw data of the sound, with no header whatsoever.
But I am wondering : as when you start a sound, this sound can be either mono or stereo, and you do NOT tell Java what kind of sound this is, so there MUST be a header somewhere in the sound...
So I guess that the sound works under PowerDVD by chance only.

So my question is : what is the exact format of the sounds accepted by BDJ? au? wav? raw?

Thanks for enlightning me!

Francois

Reply viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.
2themax
Offline
Joined: 2008-01-22

Ratatouille uses a mixture of BDMV and PCM.

raserex
Offline
Joined: 2007-12-04

Bill,

Thanks for all previous help.

I'm working at a company in Burbank developing BD-J apps. I previously developed mobile apps using J2ME.
I just started and I need some ideas to point me in the right direction.
We use IntelliJ ide for development and Blu-Print as our BDJ software. I am currently going through an inhouse course for this but I'm not sure how it all fits together between the IntelliJ and Blu-print.
Can you clarify for me, or have you heard of this combo before? Thanks in advance for any ideas from you or anyone else who may have the same setup.

Joel

Message was edited by: raserex

Bill Foote

Hi Joel,

That's a pretty open question!

In my understanding, with Blu-print (or with Scenarist),
you basically import a JAR file containing a fully written
BD-J app. Blu-print signs it and integrates it into a disc
image. So, in your case you'd develop a BD-J app using your
tool of choice, compile it (e.g. with javac -target 1.3),
build a JAR, and then import that into Blu-print.

This answer sweeps a rather massive amount of detail under
the carpet, like "how do you develop a BD-J app using an IDE
or other tool?" That's a big question, and there are a lot of
possible answers, including higher-level tools.

Cheers,

Bill

bd-j-dev@mobileandembedded.org wrote:
> Bill,
>
> Thanks for all previous help.
>
> I'm working at a company in Burbank developing BD-J apps. I previously developed mobile apps using J2ME.
> I just started and I need some ideas to point me in the right direction.
> We use IntelliJ ide for development and Blu-Print as our BDJ software. I am currently going through an inhouse course for this but I'm not sure how it all fits together between the IntelliJ and Blu-print.
> Can you clarify for me?
> [Message sent by forum member 'raserex' (raserex)]
>
> http://forums.java.net/jive/thread.jspa?messageID=264449
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: bd-j-dev-unsubscribe@hdcookbook.dev.java.net
> For additional commands, e-mail: bd-j-dev-help@hdcookbook.dev.java.net
>

---------------------------------------------------------------------
To unsubscribe, e-mail: bd-j-dev-unsubscribe@hdcookbook.dev.java.net
For additional commands, e-mail: bd-j-dev-help@hdcookbook.dev.java.net

raserex
Offline
Joined: 2007-12-04

Bill,

Thanks. You actually answered my question exactly. The other part of building an xlet in IntelliJ into a BD-J app, I'm already somewhat familiar with and I'm learning more about it every day. Like making the main xlet as an entry point and then building the other classes out depending upon the type of project or the project request parameters.

I'm still going through the course until the end of April.

Thanks again Bill,

Joel

bjoern_minkmar
Offline
Joined: 2007-06-11

Hi Francois, hi Denny,

using a tool like audio-converter is only the first step, but it is not sufficient.
PowerDVD can play a raw *.pcm sound-file without any problems, but the
hardware-players won't.
The hardware-players need header-informations to know if the sound is mono or stereo
for example.
These infos as well as the audio data itself are stored in the sound.bdmv file.

So to me it seems, that sounds can only be played from a sound.bdmv file.
At the moment there is no free tool for creating sound.bdmv file.
But i guess it shouldn't be too hard to create one.

Cheers,
Björn

dbreitenfeld
Offline
Joined: 2007-03-18

Hey Björn,

We'll dig up the details on the pcm audio. At NetBlender we are really going to promote sound.bdmv as the method of choice because we've built this in but would like to see people use pcm files.

I believe there are a couple of Hollywood titles that use pcm files for menus and for games. Can anyone confirm this?

Cheers,

Denny B.
------------------------------------------------------------------------------------------------------------
[i]NetBlender DoStudio MX Team - NDS - http://dostudio.netblender.com[/i]

clinic
Offline
Joined: 2008-02-14

I believe "The Guardian" uses pcm audio.

dbreitenfeld
Offline
Joined: 2007-03-18

Hi francoislionet,

The sound files you are interested in are part of the Interactive Audio specification and the only file formats supported are LPCM which are "Uncompressed Wave" 48Khz 16bit mono or stereo files.

If you are looking for a tool to convert mp3, .wav (windows audio) files to pcm files you can use this tool here:

http://www.audioi.com/audio-converter.htm

Hope this helps,

Denny B.
------------------------------------------------------------------------------------------------------------
[i]NetBlender DoStudio MX Team - NDS - http://dostudio.netblender.com [/i]

francoislionet
Offline
Joined: 2008-01-13

So actually, the only solution to play sounds on a BluRay platform, is to include the sounds in a sound.bdmv file. You cannot load the sound directly from the JAR file as it does not include header information.

Bill Foote

François wrote:
> So actually, the only solution to play sounds on a BluRay platform, is to include the sounds in a sound.bdmv file. You cannot load the sound directly from the JAR file as it does not include header information.

You definitely do need a sound.bdmv file, yes.

I think that you can put the sound.bdmv file inside a JAR file
and access it with a JMF player, e.g. by going URL -> MediaLocator
-> createPlayer(). I've never tried this; in most cases I'd
recommend putting the sound.bdmv straight in the AUXDATA
directory.

For creating the sound.bdmv file -- we've taken a look, and
a lot of the pieces are available. Would anyone like to volunteer
to make a little utility that does this? [cue music from
http://youtube.com/watch?v=SZZxubx-kpA ] The lucky contestant
stands to win from among these fabulous prizes:

* The heartfelt thanks of the cookbook community
* Immortality, fame and recognition in the form of
an @author tag
* Recognition at our JavaOne talk
* Thirty-seven quatloos if the one with the
pointed ears prevails in combat

OK, so I'm mixing The Dating Game and Star Trek, but anyone game?

We have source code that will take WMV files in the right format
and apply the meta-information needed for a sound.bdmv file.
It looks like the JDK APIs in javax.sound.clip would work to
convert other formats into the input needed by our source code
fragment, that is, into a linear PCM encoding with a sampling
frequency of 48 kHz, 16 bits per sample (MSB first) with
one or two channels. If someone would be willing to write
a little wrapper and put it back to the hdcookbook project,
we'll provide our source fragment. The wrapper would:

* Accept sound clips (e.g. on the command line)
* Convert them to LPCM as above
* Format the clips into a sound.bdmv file using the code we've got

If someone wants to volunteer, please coordinate with Chihiro.
I'm going to be off in Texas on semi-vacation for the next week
(through the Texas primary/caucus).

Cheers,

Bill

---------------------------------------------------------------------
To unsubscribe, e-mail: bd-j-dev-unsubscribe@hdcookbook.dev.java.net
For additional commands, e-mail: bd-j-dev-help@hdcookbook.dev.java.net

Joe Rice

This is an interesting discussion.

sound.bdmv in AUXDATA is limited to 2MB, whereas the spec allows for
an additional 5MB of sound data to be loaded by BD-J applications, so
it can be useful to have access to both.

We've seen mono PCM files work on most, if not all, of the HW players.

Cheers,
Joe

On Feb 28, 2008, at 9:37 AM, Bill Foote wrote:

> François wrote:
>> So actually, the only solution to play sounds on a BluRay platform,
>> is to include the sounds in a sound.bdmv file. You cannot load the
>> sound directly from the JAR file as it does not include header
>> information.
>
> You definitely do need a sound.bdmv file, yes.
>
> I think that you can put the sound.bdmv file inside a JAR file
> and access it with a JMF player, e.g. by going URL -> MediaLocator
> -> createPlayer(). I've never tried this; in most cases I'd
> recommend putting the sound.bdmv straight in the AUXDATA
> directory.
>
>
> For creating the sound.bdmv file -- we've taken a look, and
> a lot of the pieces are available. Would anyone like to volunteer
> to make a little utility that does this? [cue music from
> http://youtube.com/watch?v=SZZxubx-kpA] The lucky contestant
> stands to win from among these fabulous prizes:
>
> * The heartfelt thanks of the cookbook community
> * Immortality, fame and recognition in the form of
> a @author tag
> * Recognition at our JavaOne talk
> * Thirty-seven quatloos if the one with the
> pointed ears prevails in combat
>
> OK, so I'm mixing The Dating Game and Star Trek, but anyone game?
>
> We have source code that will take WMV files in the right format
> and apply the meta-information needed for a sound.bdmv file.
> It looks like the JDK APIs in javax.sound.clip would work to
> convert other formats into the input needed by our source code
> fragment, that is, into a linear PCM encoding with a sampling
> frequency of 48 kHz, 16 bits per sample (MSB first) with
> one or two channels. If someone would be willing to write
> a little wrapper and put it back to the hdcookbook project,
> we'll provide our source fragment. The wrapper would:
>
> * Accept sound clips (e.g. on the command line)
> * Convert them to LPCM as above
> * Format the clips into a sound.bdmv file using the code we've got
>
> If someone wants to volunteer, please coordinate with Chihiro.
> I'm going to be off in Texas on semi-vacation for the next week
> (through the Texas primary/caucus).
>
> Cheers,
>
> Bill
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: bd-j-dev-unsubscribe@hdcookbook.dev.java.net
> For additional commands, e-mail: bd-j-dev-help@hdcookbook.dev.java.net
>

---------------------------------------------------------------------
To unsubscribe, e-mail: bd-j-dev-unsubscribe@hdcookbook.dev.java.net
For additional commands, e-mail: bd-j-dev-help@hdcookbook.dev.java.net

dbreitenfeld
Offline
Joined: 2007-03-18

Hey Joe,

That is a good point you bring up with the size limitations. It is important to keep in mind both methods have been designed to be the auxiliary audio such as "sound effects" and are not designed to be the primary audio. This could be an issue if you are building a complex game and would like to have complex dynamic audio playback. I think so far everyone here is trying to use it as sound effects for games and menus.

Cheers,

Denny B.
------------------------------------------------------------------------------------------------------------
[i]NetBlender DoStudio MX Team - NDS - http://dostudio.netblender.com[/i]