[SlimDX] SoundBuffer.Write
Hey SlimDX users/devs... quick couple questions about SoundBuffer.Write.
How exactly does the LockFlags parameter work? ...
- When is the buffer unlocked? Immediately after the write? Manually via some method I don't know about?
- What exactly does LockFlags.FromWriteCursor lock? My guess would be from bufferOffset to the length of the data passed to Write(), but I'd like confirmation.
- What's the best locking practice when using streaming buffers? Presumably LockFlags.EntireBuffer is out of the question since the buffer is being played while it is being written to, but then should I use LockFlags.None or LockFlags.FromWriteCursor?
- What does the CurrentWritePosition property correspond to? Is it just set to Write's bufferOffset parameter?
Thanks!
Write will do a Lock, write from data, and return the result of Unlock. CurrentWritePosition calls IDirectSoundBuffer8::GetCurrentPosition and returns the second parameter. I'm not really sure about the other two, but maybe How to stream an ogg file using DirectSound in SlimDX will help?
This topic is closed to new replies.
Advertisement
Popular Topics
Advertisement