Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fixed some bugs in PKVideoDecoder #17

Merged
merged 1 commit into from
Jul 4, 2017
Merged

Conversation

xgfjyw
Copy link
Contributor

@xgfjyw xgfjyw commented Jun 29, 2017

改成这样的目的是让processAsset拥有并维护自己的reader。

尝试过让原来cancelReading调用位置不动,后来发现有特定操作导致小视频拉出屏幕后还残留线程没退出。没有仔细查是什么原因,但我猜是快速划过屏幕(进出屏幕时间间隔很短)的时候processAsset中[self createAssetReader]还没执行完然后就去cancelReading,导致cancel不掉。最终改成现在这样。

简单测试过快速拖动时不会产生线程退不出来的情况,把所有小视频的view拉出可见区域后没有残留播放小视频的线程。

[PKVideoDecoder endProcessing]这个方法应该放哪里我没看太懂,可能因为代码改变需要调一下触发的位置。

@pepsikirk pepsikirk merged commit b8dda11 into pepsikirk:master Jul 4, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants