FMOD problem (playing MP3)

B

Balint Toth

Hi all,

I got FMOD from www.fmod.org. I wrote the following simple code, but
unfortunately nothing happens:

[DllImport("fmodce.dll")]

public static extern bool FSOUND_Init(

int mixrate,

int maxsoftwarechannels,

uint flags);

[DllImport("fmodce.dll") ]

public static extern IntPtr FSOUND_Stream_Open(

string name_or_data,

uint mode, int offset, int length);

[DllImport("fmodce.dll") ]

public static extern int FSOUND_Stream_Play(

int channel,

IntPtr stream

);

.....

if (!FSOUND_Init(44100, 32, 0)) {ApplicationEx.Exit(); }

IntPtr a = new IntPtr();

a = FSOUND_Stream_Open("\\Storage\a.mp3",304,0,0);

MessageBox.Show(a.ToString());

int i = FSOUND_Stream_Play(-1,a);

MessageBox.Show(i.ToString());

----

The first messagebox displays 0, the secund -1.

What can be the problem, I cannot figure it out.



Thanks in advance,

Bálint Tóth
 
B

Balint Toth

Thank you very much, it is a great class. Unfortunately it makes the same as
I did, and doesnt work either.
I dont know what can be the problem.

Now I would like to simply play my file with the help of wmplayer (Windows
Media Player) on smartphone, but unfortunately I cannot find the .exe file.
Where can it be? Or is there Windows Media Player SDK for Smartphone?

Please, help me!

Thanks,
Bálint Tóth
 
A

Alex Yakhnin [MVP]

Thank you very much, it is a great class. Unfortunately it makes the same
as
I did, and doesnt work either.
I dont know what can be the problem.

Sorry, haven't tried it yet myself.
Now I would like to simply play my file with the help of wmplayer (Windows
Media Player) on smartphone, but unfortunately I cannot find the .exe file.
Where can it be?

It should be in \Windows\wmplayer.exe
Or is there Windows Media Player SDK for Smartphone?

There's none exist yet.


--
Alex Yakhnin .NET CF MVP
www.intelliprog.com | www.opennetcf.org

Balint Toth said:
Thank you very much, it is a great class. Unfortunately it makes the same as
I did, and doesnt work either.
I dont know what can be the problem.

Now I would like to simply play my file with the help of wmplayer (Windows
Media Player) on smartphone, but unfortunately I cannot find the .exe file.
Where can it be? Or is there Windows Media Player SDK for Smartphone?

Please, help me!

Thanks,
Bálint Tóth
 
B

Balint Toth

Thanks for the answares.

On the phone the Media Player can be started, but I cannot see it in the
explorer... I dont understand.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top