Microsoft DirectX 9.0 |
The VTrackInsBefore method inserts a virtual track into the composition at the specified priority.
Syntax
HRESULT VTrackInsBefore(
IAMTimelineObj *pVirtualTrack,
long Priority
);
Parameters
pVirtualTrack
Pointer to the IAMTimelineObj interface of the virtual track.
Priority
Priority at which to insert the virtual track, or 1 to insert the virtual track at the end of the priority list. The priority list determines which clips are visible. See Remarks for more information.
Return Value
Returns one of the following HRESULT values:
Return code | Description |
S_OK | Success. |
E_INVALIDARG | Invalid argument. |
E_NOINTERFACE | Object is not a virtual track. |
Remarks
Each virtual track in composition has a unique priority level. Priority levels range from 0 to n - 1, where n is the number of virtual tracks in the composition. For video groups, a virtual track hides any virtual tracks with a lower priority level, except in places where the track is empty or contains a transition. You can think of virtual tracks as being layers in the final composition. Track 1 is layered on top of track 0, track 2 is layered on top of track 1, and so forth.
If you specify -1 for the Priority parameter, the virtual track is inserted at the end of the list, with a higher priority value than the existing tracks. If you specify a priority value that already exists in the composition, every track with an equal or greater priority moves up one priority level.
Example: Track A has priority 0, and track B has priority 1. If track C is inserted at priority 0, track A moves to priority 1, and track B moves to priority 2.
If the specified priority is greater than the current number of tracks in the composition, the method fails.
Requirements
Header: Include Qedit.h. This header file is not compatible with Microsoft® Direct3D® headers later than version 7.
Library: Use strmiids.lib.
See Also