Hi :)
Is there a way to set the playing duration of a DirectSound Buffer within the API or do i have to use threads/timers to keep track of when to stop playing myself?
(I am using C# and MDX)
Thanks in advance.
DirectSound audio buffer playing duration?
Started by Dias, Dec 31 2006 12:48 PM
2 replies to this topic
#1
Posted 31 December 2006 - 12:48 PM
#2
Posted 31 December 2006 - 02:43 PM
Hello.. i am new here... Following basic should work and show you how to calculate the playtime. hope its help you.
lSizeInBytes.l / lBitrate.l = lLengthInSeconds.l 3,882,423 bytes = 31,059,384 bits 128 kbit/s = 131,072 bits/s 31,059,384 / 131,072 = 237 seconds.
#3
Posted 31 December 2006 - 02:58 PM
Hi, and thanks for you reply.
I dont think i was clear enough though.
What i mean is that i already know the length of the clip and any position within it as it plays.
What i wonder is if there is any support in DirectSound to just play a partion of the sound. I know you can set a starting position within the buffer, but i havent found where/how to set an ending position, which means it always plays to the end of the buffer.
I dont think i was clear enough though.
What i mean is that i already know the length of the clip and any position within it as it plays.
What i wonder is if there is any support in DirectSound to just play a partion of the sound. I know you can set a starting position within the buffer, but i havent found where/how to set an ending position, which means it always plays to the end of the buffer.
1 user(s) are reading this topic
0 members, 1 guests, 0 anonymous users












