|Microsoft DirectX 9.0|
Creates a new stream sample that shares the same backing object as the existing sample.
HRESULT CreateSharedSample( IStreamSample *pExistingSample, DWORD dwFlags , IStreamSample **ppNewSample );
[in] Pointer to the existing sample.
[in] Reserved for flag data. Must be zero.
[out] Address of a pointer to an IStreamSample interface that will point to the newly created shared sample.
Returns one of the following values.
|E_OUTOFMEMORY||There isn't enough memory available to create the sample.|
|E_POINTER||One of the parameters is invalid.|
|MS_E_INCOMPATIBLE||The existing sample isn't compatible with the specified media stream.|
|S_OK||Success; ppNewSample points to the newly created sample.|
This method calls IUnknown::QueryInterface on the existing sample to retrieve the media type-specific information, which it uses to create the shared sample.