# PlayerStreamInfo (/zh-CN/api-reference/rtc/unity/class-playerstreaminfo)

> For AI agents: see the complete documentation index at [llms.txt](/llms.txt).

<a id="class_playerstreaminfo__prototype"></a>

```csharp
public class PlayerStreamInfo
    {
        public int streamIndex { set; get; }
        public MEDIA_STREAM_TYPE streamType { set; get; }
        public string codecName { set; get; }
        public string language { set; get; }
        public int videoFrameRate { set; get; }
        public int videoBitRate { set; get; }
        public int videoWidth { set; get; }
        public int videoHeight { set; get; }
        public int videoRotation { set; get; }
        public int audioSampleRate { set; get; }
        public int audioChannels { set; get; }
        public int audioBitsPerSample { set; get;
        public int64_t duration { set; get; }
        public PlayerStreamInfo()
        {
            streamIndex = 0;
            streamType = MEDIA_STREAM_TYPE.STREAM_TYPE_UNKNOWN;
            videoFrameRate = 0;
            videoBitRate = 0;
            videoWidth = 0;
            videoHeight = 0;
            videoRotation = 0;
            audioSampleRate = 0;
            audioChannels = 0;
            audioBitsPerSample = 0;
            duration = 0;
            codecName = "";
            language = "";
        }
    };
```

<a id="class_playerstreaminfo__parameters"></a>

## 属性 [#属性]

<ParameterList>
<a id="streamindex"></a>
<Parameter name="streamIndex">

媒体流的索引值。

</Parameter>
<a id="streamtype"></a>
<Parameter name="streamType">

此条媒体流的类型。详见 [MEDIA_STREAM_TYPE](/zh-CN/api-reference/rtc/unity/enum-mediastreamtype)。

</Parameter>
<a id="codecname"></a>
<Parameter name="codecName">

此条媒体流的编码规格。

</Parameter>
<a id="language"></a>
<Parameter name="language">

此条媒体流的语言。

</Parameter>
<a id="videoframerate"></a>
<Parameter name="videoFrameRate">

该参数仅对视频流生效，表示视频帧率 (fps)。

</Parameter>
<a id="videobitrate"></a>
<Parameter name="videoBitRate">

该参数仅对视频流生效，表示视频码率 (bps)。

</Parameter>
<a id="videowidth"></a>
<Parameter name="videoWidth">

该参数仅对视频流生效，表示视频宽度 (px)。

</Parameter>
<a id="videoheight"></a>
<Parameter name="videoHeight">

该参数仅对视频流生效，表示视频高度 (px)。

</Parameter>
<a id="videorotation"></a>
<Parameter name="videoRotation">

该参数仅对视频流生效，表示旋转角度。

</Parameter>
<a id="audiosamplerate"></a>
<Parameter name="audioSampleRate">

该参数仅对音频流生效，表示音频采样率 (Hz)。

</Parameter>
<a id="audiochannels"></a>
<Parameter name="audioChannels">

该参数仅对音频流生效，表示声道数。

</Parameter>
<a id="audiobitspersample"></a>
<Parameter name="audioBitsPerSample">

该参数仅对音频流生效，表示每个音频采样点的位数 (bit)。

</Parameter>
<a id="duration"></a>
<Parameter name="duration">

媒体流的时长（毫秒）。

</Parameter>
</ParameterList>
