| View previous topic :: View next topic |
| Author |
Message |
JRoza Contributor


Joined: 17 Aug 2003 Posts: 182 Location: Netherlands
|
Posted: Sun Apr 23, 2006 7:46 pm Post subject: VDSMedia - Am I missing something? |
|
|
Hi,
I'm trying to integrate VDSMedia in my program, but everytime I hit the Play button in my program all I hear is silence.
I tried the demo program provided with VDSMedia and the sounds works fine even on the same WAV- and MID-files as I tried in my program.
I thought I had everything in my program that the demo program had so where am I going wrong?
Here's an abbreviating of my code:
| Code: |
EXTERNAL @PATH(%0)vdsmedia.dll,invalidserial|140731113249
#DEFINE COMMAND,media
#DEFINE FUNCTION,media
DIALOG CREATE,xxxx,-1,0,477,422,CLASS TSURFX
MEDIA WINDOW,#TSURFX
MEDIA ADD,MusicMedium,1,1,1,1
MEDIA VOLUME,MusicMedium,0
MEDIA HIDE,MusicMedium
........
........
DIALOG SHOW
:BtnPlayBUTTON
MEDIA LOAD,MusicMedium,%%MusicFile
MEDIA PLAY,MusicMedium
GOTO evloop
|
Hope anyone can spot what I'm doing wrong because it starts to drive me nuts.
Jan |
|
| Back to top |
|
 |
Skit3000 Admin Team

Joined: 11 May 2002 Posts: 2166 Location: The Netherlands
|
|
| Back to top |
|
 |
JRoza Contributor


Joined: 17 Aug 2003 Posts: 182 Location: Netherlands
|
Posted: Mon Apr 24, 2006 8:28 am Post subject: |
|
|
Thanks for your reaction Skit.
According the documentation volume zero means full volume.
I also tried it without this line and still only silence.
I've gone over the VdsMedia example source time and time again and as far as I can see there nothing left out that should be needed.
Maybe Marty can shine a light on this one.
Kind of frustrating when you load the example and all goes well and when you load your own program with the same construction nothing happens.
Well that's life ....... full of surprises and challenges.
Jan |
|
| Back to top |
|
 |
JRoza Contributor


Joined: 17 Aug 2003 Posts: 182 Location: Netherlands
|
Posted: Mon Apr 24, 2006 8:34 am Post subject: |
|
|
Dumb, dumb, dumb!!!
I found it.
The variable %%MusicFile contained the filename of the musicfile but not the path so VdsMedia couldn't find it and play.
I changed that line to
| Code: |
MEDIA LOAD,mMedium,@PATH(%0)Working\%%MusicFile
|
and all is well.
Shame on me!
Jan |
|
| Back to top |
|
 |
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum You can attach files in this forum You can download files in this forum
|
|