Jump to content

View more

Image of the Day

#ld38 #screenshotsaturday Mimosa Fizz action gif #2 https://t.co/TUzdppvfUL
IOTD | Top Screenshots

The latest, straight to your Inbox.

Subscribe to GameDev.net Direct to receive the latest updates and exclusive content.


Sign up now

Changing CD volume

4: Adsense

Old topic!

Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.


  • You cannot reply to this topic
2 replies to this topic

#1 Anonymous Poster_Anonymous Poster_*   Guests   

Likes

Posted 28 September 1999 - 07:38 AM

Hi,

I'd like to change the volume of CD audio from within a game I'm working on. The tracks are played using MCI commands but I haven't been able to work out how to change the cd volume. Should I be looking at the mixer and line function from the Win32 SDK?

Can anybody point me in the right direction?

Thanks,

Martin


#2 Jim Adams   Members   

440
Like
Likes
Like

Posted 27 September 1999 - 03:51 AM

This was answered a couple of days ago, but here it is again:

// assumming using mciSendString methods
char command[64];
char buffer[16];
UINT cdaudio_id;
DWORD volume_level;

strcpy(command,"open cdaudio wait");
mciSendString(command, buffer, 16, NULL);
buffer[15] = 0;
cdaudio_id = (UINT)atoi(buffer);

volume_level = volume | (volume << 16);
auxSetVolume(cdaudio_id, volume_level);


------------------
Jim Adams
Co-Designer 'The Light Befallen'
tcm@pobox.com
http://www.lightbefallen.com


#3 Seyedof   Members   

123
Like
Likes
Like

Posted 28 September 1999 - 07:38 AM

hi,
Oh no !!! i had such problem but i did it
using the Win32 mixer functions !
They are not well documented in Win32 SDK,
i have written a class library in C++ for
changing the cd volume
tnx guy





Old topic!

Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.