Reputation: 744
I want to capture video from screen.
I am unable to capture video from avplayer layer. But, can record from other viewes.
Do I need to search code for OpenGLES?
Upvotes: 3
Views: 4367
Reputation: 410
This is good for you testing you achieve that goal through this framework https://github.com/gabriel/CaptureRecord for screen capture. But, it can be used to record simulator only. You can't submit app to appstore using this code as it use private api.
Upvotes: 0
Reputation: 2729
I would suggest using the GPUImage framework, for a number of reasons:
There is a class named GPUImageMovie that wraps AVAssetReader for playback and another named GPUImageMovieWriter that allows you to write textures to file - these can be the same file, or separate.
There are quite a few examples available within the repository that should be pretty easy to understand...
Source Code / Git Repo * https://github.com/BradLarson/GPUImage
Blog * http://www.sunsetlakesoftware.com/2012/02/12/introducing-gpuimage-framework
Hope that helps !
Upvotes: 0
Reputation: 3506
These two libraries are the best possible options that you can use to record video of your application screen.
https://github.com/wess/Glimpse
https://everyplay.com/about
Upvotes: 3
Reputation: 710
You can have look at the blog.
I think it covers what you want.
Actually this blog does not use AVPlayer
, but rather it uses AVAssetWriter
.
Look into the comments there you can get hint using AVPlayer
.
Or you can have this project, which is for recording of screen.
Upvotes: 3
Reputation: 11
You need to work on OpenGLES to render video layer, otherwise it will look black
Upvotes: 1
Reputation:
Yes I'm working with the same job it comes black screen because of high frameDuration of video .But I've solved this
Don't add AVPlayer to that view. Add to another view and note the time at play and then crop the video of time that has played and after all merge with the recorded video.
I've stated it shortly but I hope you will understand.
Upvotes: 2