Microsoft DirectX 9.0

MPEG2_TRANSPORT_STRIDE

The MPEG2_TRANSPORT_STRIDE structure describes the format of MPEG-2 transport stream (TS) packets. This structure allows for transports streams in which the 188-byte transport packets are not contiguous. For the purpose of this documentation, such packets are referred to as stride packets.

Stride packets are identified by the following media type:

Major Type MEDIATYPE_Stream
Subtype MEDIASUBTYPE_MPEG2_TRANSPORT_STRIDE
Format Type FORMAT_None

The format block (pbFormat) is optional. If the format block is included, it must begin with an MPEG2_TRANSPORT_STRIDE structure. This structure defines the layout of the transport packet within the stride packet. If the format block is NULL, the packets are assumed to use a set of default values; see the Remarks section for details.

Syntax

struct MPEG2_TRANSPORT_STRIDE {
    DWORD   dwOffset
    DWORD   dwPacketLength
    DWORD   dwStride
};

Members

dwOffset

Specifies the offset, in bytes, from the beginning of the packet to the first byte of the embedded transport packet. The value must range from zero to (dwStride - dwPacketLength), inclusive.

dwPacketLength

Specifies the length of the embedded transport packet, in bytes. For standard MPEG-2 transport packets, the value must be 188 bytes.

dwStride

Specifies the length of the entire stride packet, in bytes. The value must be at least (dwOffset + dwPacketLength).

Remarks

The following diagram illustrates the relations between the structure members.

MPEG-2 stride packet

Input buffers that contain multiplexed stride packets have some restrictions:

There is no restriction on the number of stride packets per buffer.

If the media type does not contain a format block (pbFormat is NULL), the following default values are used:

See Also