| 270 | } |
| 271 | |
| 272 | void MediaPlayer::SelectTrack(int index) |
| 273 | { |
| 274 | std::lock_guard<std::mutex> lock(mMutexAbr); |
| 275 | GET_PLAYER_HANDLE |
| 276 | |
| 277 | if (SELECT_TRACK_VIDEO_AUTO == index) { |
| 278 | mAbrManager->EnableAbr(true); |
| 279 | return; |
| 280 | } else if (index < SELECT_TRACK_VIDEO_AUTO) { |
| 281 | return; |
| 282 | } |
| 283 | |
| 284 | StreamType type = CicadaSwitchStreamIndex(handle, index); |
| 285 | |
| 286 | if (ST_TYPE_VIDEO == type) { |
| 287 | mAbrManager->EnableAbr(false); |
| 288 | } |
| 289 | } |
| 290 | |
| 291 | bool MediaPlayer::IsEnableAbr() |
| 292 | { |