The IAMFileCutListElement interface provides support for a cutlist element for a file stream.
See About Cutlists and Using Cutlists for more information.
When to Implement
Implement this interface in your application when you implement your own IAMCutListElement interface. Usually, you don't need to implement either interface because DirectShow provides the CLSID_VideoFileClip and CLSID_AudioFileClip objects that implement it for you. However, you can implement this interface in your application when you need to change the default behavior of this interface.
When compiling a cutlist application you must explicitly include the cutlist header file as follows:
#include <cutlist.h>
When to Use
Use this interface in your filter when you specify a media clip stored in a file. Call QueryInterface on IAMCutListElement to determine if the element is file-based.
Methods in Vtable Order
| IUnknown methods | Description |
| QueryInterface | Retrieves pointers to supported interfaces. |
| AddRef | Increments the reference count. |
| Release | Decrements the reference count. |
| IAMFileCutListElement methods | Description |
| GetFileName | Retrieves the file name of the cutlist element. |
| GetTrimInPosition | Retrieves the media time of the trimin point, based on the timeline of the cut's source file. |
| GetTrimOutPosition | Retrieves the media time of the trimout point, based on the timeline of the cut's source file. |
| GetOriginPosition | Retrieves the media time of the origin of the file or clip. |
| GetTrimLength | Retrieves the length of time between the trimin and trimout points. |
| GetElementSplitOffset | Retrieves the media time of the number of frames between the trimin point and the start of this element in output time. |
Retrieves the media time of the number of frames between the trimin point and the start of this element in output time.
HRESULT GetElementSplitOffset(
REFERENCE_TIME *pmtOffset
);
Returns an HRESULT value that depends on the implementation of the interface. HRESULT can include one of the following standard constants, or other values not listed.
| Value | Meaning |
| E_FAIL | Failure. |
| E_INVALIDARG | Argument is invalid. |
| E_NOTIMPL | Method is not supported. |
| E_POINTER | Null pointer argument. |
| S_OK | Success. |
This method must retrieve a zero offset. Other offsets are not supported.
Retrieves the file name of the cutlist element.
HRESULT GetFileName(
LPWSTR *ppwstrFileName
);
Returns an HRESULT value that depends on the implementation of the interface. HRESULT can include one of the following standard constants, or other values not listed.
| Value | Meaning |
| E_FAIL | Failure. |
| E_INVALIDARG | Argument is invalid. |
| E_NOTIMPL | Method is not supported. |
| E_POINTER | Null pointer argument. |
| S_OK | Success. |
Retrieves the media time of the origin of the file or clip.
HRESULT GetOriginPosition(
REFERENCE_TIME *pmtOrigin
);
Returns an HRESULT value that depends on the implementation of the interface. HRESULT can include one of the following standard constants, or other values not listed.
| Value | Meaning |
| E_FAIL | Failure. |
| E_INVALIDARG | Argument is invalid. |
| E_NOTIMPL | Method is not supported. |
| E_POINTER | Null pointer argument. |
| S_OK | Success. |
This method must return a zero origin. Clips with nonzero start times are not supported.
Retrieves the media time of the trimin point, based on the timeline of the cut's source file.
HRESULT GetTrimInPosition(
REFERENCE_TIME *pmtTrimIn
);
Returns an HRESULT value that depends on the implementation of the interface. HRESULT can include one of the following standard constants, or other values not listed.
| Value | Meaning |
| E_FAIL | Failure. |
| E_INVALIDARG | Argument is invalid. |
| E_NOTIMPL | Method is not supported. |
| E_POINTER | Null pointer argument. |
| S_OK | Success. |
Retrieves the length of time between the trimin and trimout points.
HRESULT GetTrimLength(
REFERENCE_TIME *pmtLength
);
Returns an HRESULT value that depends on the implementation of the interface. HRESULT can include one of the following standard constants, or other values not listed.
| Value | Meaning |
| E_FAIL | Failure. |
| E_INVALIDARG | Argument is invalid. |
| E_NOTIMPL | Method is not supported. |
| E_POINTER | Null pointer argument. |
| S_OK | Success. |
This method retrieves the length of time between the in and out points specified by GetTrimInPosition and GetTrimOutPosition.
The value that GetTrimLength retrieves equals the value that GetElementDuration retrieves (trimout minus trimin). Other lengths are not supported.
Retrieves the media time of the trimout point, based on the timeline of the cut's source file.
HRESULT GetTrimOutPosition(
REFERENCE_TIME *pmtTrimOut
);
Returns an HRESULT value that depends on the implementation of the interface. HRESULT can include one of the following standard constants, or other values not listed.
| Value | Meaning |
| E_FAIL | Failure. |
| E_INVALIDARG | Argument is invalid. |
| E_NOTIMPL | Method is not supported. |
| E_POINTER | Null pointer argument. |
| S_OK | Success. |
The media time does not include the trimout point.
© 1997 Microsoft Corporation. All rights reserved. Terms of Use.