📄 axcore.cs
字号:
[PreserveSig]
int SetTime(
[In, MarshalAs(UnmanagedType.LPStruct)] DsLong pTimeStart,
[In, MarshalAs(UnmanagedType.LPStruct)] DsLong pTimeEnd
);
[PreserveSig]
int IsSyncPoint();
[PreserveSig]
int SetSyncPoint([In, MarshalAs(UnmanagedType.Bool)] bool bIsSyncPoint);
[PreserveSig]
int IsPreroll();
[PreserveSig]
int SetPreroll([In, MarshalAs(UnmanagedType.Bool)] bool bIsPreroll);
[PreserveSig]
int GetActualDataLength();
[PreserveSig]
int SetActualDataLength([In] int len);
/// <summary>
/// Returned object must be released with DsUtils.FreeAMMediaType()
/// </summary>
[PreserveSig]
int GetMediaType([Out, MarshalAs(UnmanagedType.LPStruct)] out AMMediaType ppMediaType);
[PreserveSig]
int SetMediaType([In, MarshalAs(UnmanagedType.LPStruct)] AMMediaType pMediaType);
[PreserveSig]
int IsDiscontinuity();
[PreserveSig]
int SetDiscontinuity([In, MarshalAs(UnmanagedType.Bool)] bool bDiscontinuity);
[PreserveSig]
int GetMediaTime(
[Out] out long pTimeStart,
[Out] out long pTimeEnd
);
[PreserveSig]
int SetMediaTime(
[In, MarshalAs(UnmanagedType.LPStruct)] DsLong pTimeStart,
[In, MarshalAs(UnmanagedType.LPStruct)] DsLong pTimeEnd
);
}
[ComImport,
Guid("56a86899-0ad4-11ce-b03a-0020af0ba770"),
InterfaceType(ComInterfaceType.InterfaceIsIUnknown)]
public interface IMediaFilter : IPersist
{
#region IPersist Methods
[PreserveSig]
new int GetClassID(
[Out] out Guid pClassID);
#endregion
[PreserveSig]
int Stop();
[PreserveSig]
int Pause();
[PreserveSig]
int Run([In] long tStart);
[PreserveSig]
int GetState(
[In] int dwMilliSecsTimeout,
[Out] out FilterState filtState
);
[PreserveSig]
int SetSyncSource([In] IReferenceClock pClock);
[PreserveSig]
int GetSyncSource([Out] out IReferenceClock pClock);
}
[ComImport,
Guid("56a86895-0ad4-11ce-b03a-0020af0ba770"),
InterfaceType(ComInterfaceType.InterfaceIsIUnknown)]
public interface IBaseFilter : IMediaFilter
{
#region IPersist Methods
[PreserveSig]
new int GetClassID(
[Out] out Guid pClassID);
#endregion
#region IMediaFilter Methods
[PreserveSig]
new int Stop();
[PreserveSig]
new int Pause();
[PreserveSig]
new int Run(long tStart);
[PreserveSig]
new int GetState([In] int dwMilliSecsTimeout, [Out] out FilterState filtState);
[PreserveSig]
new int SetSyncSource([In] IReferenceClock pClock);
[PreserveSig]
new int GetSyncSource([Out] out IReferenceClock pClock);
#endregion
[PreserveSig]
int EnumPins([Out] out IEnumPins ppEnum);
[PreserveSig]
int FindPin(
[In, MarshalAs(UnmanagedType.LPWStr)] string Id,
[Out] out IPin ppPin
);
[PreserveSig]
int QueryFilterInfo([Out] out FilterInfo pInfo);
[PreserveSig]
int JoinFilterGraph(
[In] IFilterGraph pGraph,
[In, MarshalAs(UnmanagedType.LPWStr)] string pName
);
[PreserveSig]
int QueryVendorInfo([Out, MarshalAs(UnmanagedType.LPWStr)] out string pVendorInfo);
}
[ComImport,
Guid("56a8689f-0ad4-11ce-b03a-0020af0ba770"),
InterfaceType(ComInterfaceType.InterfaceIsIUnknown)]
public interface IFilterGraph
{
[PreserveSig]
int AddFilter(
[In] IBaseFilter pFilter,
[In, MarshalAs(UnmanagedType.LPWStr)] string pName
);
[PreserveSig]
int RemoveFilter([In] IBaseFilter pFilter);
[PreserveSig]
int EnumFilters([Out] out IEnumFilters ppEnum);
[PreserveSig]
int FindFilterByName(
[In, MarshalAs(UnmanagedType.LPWStr)] string pName,
[Out] out IBaseFilter ppFilter
);
[PreserveSig]
int ConnectDirect(
[In] IPin ppinOut,
[In] IPin ppinIn,
[In, MarshalAs(UnmanagedType.LPStruct)] AMMediaType pmt
);
[PreserveSig]
[Obsolete("This method is obsolete; use the IFilterGraph2.ReconnectEx method instead.")]
int Reconnect([In] IPin ppin);
[PreserveSig]
int Disconnect([In] IPin ppin);
[PreserveSig]
int SetDefaultSyncSource();
}
[ComImport,
Guid("56a86893-0ad4-11ce-b03a-0020af0ba770"),
InterfaceType(ComInterfaceType.InterfaceIsIUnknown)]
public interface IEnumFilters
{
[PreserveSig]
int Next(
[In] int cFilters,
[Out, MarshalAs(UnmanagedType.LPArray, SizeParamIndex=0)] IBaseFilter[] ppFilter,
[Out] out int pcFetched
);
[PreserveSig]
int Skip([In] int cFilters);
[PreserveSig]
int Reset();
[PreserveSig]
int Clone([Out] out IEnumFilters ppEnum);
}
[ComImport,
Guid("56a86892-0ad4-11ce-b03a-0020af0ba770"),
InterfaceType(ComInterfaceType.InterfaceIsIUnknown)]
public interface IEnumPins
{
[PreserveSig]
int Next(
[In] int cPins,
[Out, MarshalAs(UnmanagedType.LPArray, SizeParamIndex=0)] IPin[] ppPins,
[Out] out int pcFetched
);
[PreserveSig]
int Skip([In] int cPins);
[PreserveSig]
int Reset();
[PreserveSig]
int Clone([Out] out IEnumPins ppEnum);
}
[ComImport,
Guid("56a86897-0ad4-11ce-b03a-0020af0ba770"),
InterfaceType(ComInterfaceType.InterfaceIsIUnknown)]
public interface IReferenceClock
{
[PreserveSig]
int GetTime([Out] out long pTime);
[PreserveSig]
int AdviseTime(
[In] long baseTime,
[In] long streamTime,
[In] IntPtr hEvent, // System.Threading.WaitHandle?
[Out] out int pdwAdviseCookie
);
[PreserveSig]
int AdvisePeriodic(
[In] long startTime,
[In] long periodTime,
[In] IntPtr hSemaphore, // System.Threading.WaitHandle?
[Out] out int pdwAdviseCookie
);
[PreserveSig]
int Unadvise([In] int dwAdviseCookie);
}
[ComImport,
Guid("89c31040-846b-11ce-97d3-00aa0055595a"),
InterfaceType(ComInterfaceType.InterfaceIsIUnknown)]
public interface IEnumMediaTypes
{
[PreserveSig]
int Next(
[In] int cMediaTypes,
[In, Out, MarshalAs(UnmanagedType.CustomMarshaler, MarshalTypeRef=typeof(EMTMarshaler), SizeParamIndex = 0)] AMMediaType[] ppMediaTypes,
[Out] out int pcFetched
);
[PreserveSig]
int Skip([In] int cMediaTypes);
[PreserveSig]
int Reset();
[PreserveSig]
int Clone([Out] out IEnumMediaTypes ppEnum);
}
[ComImport,
Guid("36b73884-c2c8-11cf-8b46-00805f6cef60"),
InterfaceType(ComInterfaceType.InterfaceIsIUnknown)]
public interface IMediaSample2 : IMediaSample
{
#region IMediaSample Methods
[PreserveSig]
new int GetPointer([Out] out IntPtr ppBuffer); // BYTE **
[PreserveSig]
new int GetSize();
[PreserveSig]
new int GetTime(
[Out] out long pTimeStart,
[Out] out long pTimeEnd
);
[PreserveSig]
new int SetTime(
[In, MarshalAs(UnmanagedType.LPStruct)] DsLong pTimeStart,
[In, MarshalAs(UnmanagedType.LPStruct)] DsLong pTimeEnd
);
[PreserveSig]
new int IsSyncPoint();
[PreserveSig]
new int SetSyncPoint([In, MarshalAs(UnmanagedType.Bool)] bool bIsSyncPoint);
[PreserveSig]
new int IsPreroll();
[PreserveSig]
new int SetPreroll([In, MarshalAs(UnmanagedType.Bool)] bool bIsPreroll);
[PreserveSig]
new int GetActualDataLength();
[PreserveSig]
new int SetActualDataLength([In] int len);
[PreserveSig]
new int GetMediaType([Out] out AMMediaType ppMediaType);
[PreserveSig]
new int SetMediaType([In] AMMediaType pMediaType);
[PreserveSig]
new int IsDiscontinuity();
[PreserveSig]
new int SetDiscontinuity([In, MarshalAs(UnmanagedType.Bool)] bool bDiscontinuity);
[PreserveSig]
new int GetMediaTime(
[Out] out long pTimeStart,
[Out] out long pTimeEnd
);
[PreserveSig]
new int SetMediaTime(
[In, MarshalAs(UnmanagedType.LPStruct)] DsLong pTimeStart,
[In, MarshalAs(UnmanagedType.LPStruct)] DsLong pTimeEnd
);
#endregion
[PreserveSig]
int GetProperties(
[In] int cbProperties,
[In] IntPtr pbProperties // BYTE *
);
[PreserveSig]
int SetProperties(
[In] int cbProperties,
[In] IntPtr pbProperties // BYTE *
);
}
[ComImport,
Guid("92980b30-c1de-11d2-abf5-00a0c905f375"),
InterfaceType(ComInterfaceType.InterfaceIsIUnknown)]
public interface IMemAllocatorNotifyCallbackTemp
{
[PreserveSig]
int NotifyRelease();
}
[ComImport,
Guid("379a0cf0-c1de-11d2-abf5-00a0c905f375"),
InterfaceType(ComInterfaceType.InterfaceIsIUnknown)]
public interface IMemAllocatorCallbackTemp : IMemAllocator
{
#region IMemAllocator Methods
[PreserveSig]
new int SetProperties(
[In] AllocatorProperties pRequest,
[Out, MarshalAs(UnmanagedType.LPStruct)] AllocatorProperties pActual
);
[PreserveSig]
new int GetProperties([Out] AllocatorProperties pProps);
[PreserveSig]
new int Commit();
[PreserveSig]
new int Decommit();
[PreserveSig]
new int GetBuffer(
[Out] out IMediaSample ppBuffer,
[In] long pStartTime,
[In] long pEndTime,
[In] AMGBF dwFlags
);
[PreserveSig]
new int ReleaseBuffer([In] IMediaSample pBuffer);
#endregion
[PreserveSig]
int SetNotify([In] IMemAllocatorNotifyCallbackTemp pNotify);
[PreserveSig]
int GetFreeCount([Out] out int plBuffersFree);
}
[ComImport,
Guid("56a8689c-0ad4-11ce-b03a-0020af0ba770"),
InterfaceType(ComInterfaceType.InterfaceIsIUnknown)]
public interface IMemAllocator
{
[PreserveSig]
int SetProperties(
[In, MarshalAs(UnmanagedType.LPStruct)] AllocatorProperties pRequest,
[Out, MarshalAs(UnmanagedType.LPStruct)] AllocatorProperties pActual
);
[PreserveSig]
int GetProperties(
[Out, MarshalAs(UnmanagedType.LPStruct)] AllocatorProperties pProps
);
[PreserveSig]
int Commit();
[PreserveSig]
int Decommit();
[PreserveSig]
int GetBuffer(
[Out] out IMediaSample ppBuffer,
[In] long pStartTime,
[In] long pEndTime,
[In] AMGBF dwFlags
);
[PreserveSig]
int ReleaseBuffer(
[In] IMediaSample pBuffer
);
}
#endregion
}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -