mirror of
https://github.com/ZLMediaKit/ZLMediaKit.git
synced 2024-11-22 19:00:01 +08:00
完善MP4点播
This commit is contained in:
parent
47d8e37e3d
commit
0a31b03064
@ -136,13 +136,12 @@ bool MP4Reader::seekTo(uint32_t ui32Stamp){
|
||||
return true;
|
||||
}
|
||||
//搜索到下一帧关键帧
|
||||
bool eof = false;
|
||||
bool keyFrame = false;
|
||||
while (!eof) {
|
||||
while (true) {
|
||||
auto frame = _demuxer->readFrame(keyFrame);
|
||||
if(!frame){
|
||||
eof = true;
|
||||
break;
|
||||
//文件读完了都未找到下一帧关键帧
|
||||
return false;
|
||||
}
|
||||
if(keyFrame || frame->keyFrame() || frame->configFrame()){
|
||||
//定位到key帧
|
||||
|
Loading…
Reference in New Issue
Block a user