SecondaryBuffer.Clone Method

Language:

Duplicates the SecondaryBuffer object.

Definition

Visual Basic Public Shadows Function Clone( _
    ByVal parent As Device _
) As SecondaryBuffer
C# public new SecondaryBuffer Clone(
    Device parent
);
C++ public:
SecondaryBufferClone(
    Deviceparent
);
JScript public hide function Clone(
    parent : Device
) : SecondaryBuffer;

Parameters

parent Microsoft.DirectX.DirectSound.Device
The Device object associated with the SecondaryBuffer object.

Return Value

Microsoft.DirectX.DirectSound.SecondaryBuffer
A SecondaryBuffer object that represents the cloned SecondaryBuffer object.

Remarks

This method is not valid for buffers created with BufferCaps.ControlEffects set to true.

Initially, the duplicate buffer will have the same parameters as the original buffer. However, the application can change the parameters of each buffer independently, and each can be played or stopped without affecting the other.

Exceptions
AllocatedException The request failed because resources, such as a priority level, were already in use by another caller.
ArgumentException Leave Site An invalid parameter was passed to the method.
ArgumentNullException Leave Site The parent parameter is null.
InvalidCallException The method call is invalid for the current state of this object.


Send comments about this topic to Microsoft. © Microsoft Corporation. All rights reserved.

Feedback? Please provide us with your comments on this topic.