/// <summary> /// Creates a new Resampler based on the DMO Resampler /// </summary> public WindowsMediaMp3Decoder() { mediaComObject = new WindowsMediaMp3DecoderComObject(); mediaObject = new MediaObject((IMediaObject)mediaComObject); propertyStoreInterface = (IPropertyStore)mediaComObject; //resamplerPropsInterface = (IWMResamplerProps)mediaComObject; }
public void Dispose() { if (this.propertyStoreInterface != null) { Marshal.ReleaseComObject(this.propertyStoreInterface); this.propertyStoreInterface = null; } if (this.mediaObject != null) { this.mediaObject.Dispose(); this.mediaObject = null; } if (this.mediaComObject != null) { Marshal.ReleaseComObject(this.mediaComObject); this.mediaComObject = null; } }
/// <summary> /// Dispose code - experimental at the moment /// Was added trying to track down why Resampler crashes NUnit /// This code not currently being called by ResamplerDmoStream /// </summary> public void Dispose() { if(propertyStoreInterface != null) { Marshal.ReleaseComObject(propertyStoreInterface); propertyStoreInterface = null; } /*if(resamplerPropsInterface != null) { Marshal.ReleaseComObject(resamplerPropsInterface); resamplerPropsInterface = null; }*/ if (mediaObject != null) { mediaObject.Dispose(); mediaObject = null; } if (mediaComObject != null) { Marshal.ReleaseComObject(mediaComObject); mediaComObject = null; } }
/// <summary> /// Dispose code - experimental at the moment /// Was added trying to track down why Resampler crashes NUnit /// This code not currently being called by ResamplerDmoStream /// </summary> public void Dispose() { if (propertyStoreInterface != null) { Marshal.ReleaseComObject(propertyStoreInterface); propertyStoreInterface = null; } /*if(resamplerPropsInterface != null) * { * Marshal.ReleaseComObject(resamplerPropsInterface); * resamplerPropsInterface = null; * }*/ if (mediaObject != null) { mediaObject.Dispose(); mediaObject = null; } if (mediaComObject != null) { Marshal.ReleaseComObject(mediaComObject); mediaComObject = null; } }
public WindowsMediaMp3Decoder() { this.mediaComObject = new WindowsMediaMp3DecoderComObject(); this.mediaObject = new MediaObject((IMediaObject)this.mediaComObject); this.propertyStoreInterface = (IPropertyStore)this.mediaComObject; }