-
Notifications
You must be signed in to change notification settings - Fork 1.6k
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
Is it possible to stream MediaCodec outputbuffer to FFmpegFrameRecorder? #665
Comments
Most likely yes. Please try to use packets: #93 |
@saudet Is there a working example of this? |
/cc @alicanalbayrak @Baobomb You guys have anything? |
Hi, @saudet ! Are there any updates on this question? I googled around and found this project My first thought was to implement conversion between MediaCodec's output buffer and FFMpegFrameRecorder's input packet, but I have had no luck with that. There you said it's needed to add a support for RAW (H264?) packets which seems to be exactly what I have tried to do. I know this issue was pushed many times and I am sorry for doing it again but I am in real need in it. So I would greatly appreciate if you can kindly guid me or give an advice for next steps. |
@balbelias I'm sorry, I don't have any more information about that. That's why I labeled this issue with "help wanted". If you do put the effort into making this work, please consider making a contribution back! Thank you |
@saudet ok! I see, it's more about FFMPEG than JavaCV. But what did you mean by "add support for RAW packets"? |
Support for packets was added here: #372 |
BTW, FFmpeg supports MediaCodec now and we should be able to use it easily like this, for example: |
But how to construct |
@alexey-pelykh We can do it with FFmpeg for sure. Contributions are welcome! |
BTW, FFmpeg 6.0 now supports hardware accelerated encoding using MediaCodec, so we don't need to use its API directly anymore. Please give it a try with the snapshots: http://bytedeco.org/builds/ |
I'm trying to stream MediaCodec that records a surface over RTMP.
I understand that MediaCodec buffer is a raw h264 frame. How would I go about converting this to the correct format to feed to the FFmpegFrameRecorder?
The text was updated successfully, but these errors were encountered: