destroyer716 / ffmpegvideorange2 Goto Github PK
View Code? Open in Web Editor NEWandroid ffmpeg 仿剪映 视频剪辑 预览条 快速抽帧
android ffmpeg 仿剪映 视频剪辑 预览条 快速抽帧
你好,我将PreviewFrameActivity.java及其必要依赖复制到本地项目中运行后发现并没有抽帧画面,调试发现OnGetFrameBitmapCallback接口返回的Bitmap为null。
部分日志如下:
......
E/kzg: **********************:
E/getBitmapBySec: sec: 5000000 presentationTimeUs:1656377 ,extractor.getSampleTime():1689700
I/CCodecBufferChannel: [c2.mtk.avc.decoder#6] cannot render buffer without surface
E/getBitmapBySec: presentationTimeUs: 1689700
E/kzg: **********************:
E/getBitmapBySec: sec: 5000000 presentationTimeUs:1689700 ,extractor.getSampleTime():1733077
I/CCodecBufferChannel: [c2.mtk.avc.decoder#6] cannot render buffer without surface
E/getBitmapBySec: presentationTimeUs: 1733077
E/kzg: **********************:
E/getBitmapBySec: sec: 5000000 presentationTimeUs:1733077 ,extractor.getSampleTime():1766422
I/CCodecBufferChannel: [c2.mtk.avc.decoder#6] cannot render buffer without surface
E/getBitmapBySec: presentationTimeUs: 1766422
E/kzg: **********************:
E/getBitmapBySec: sec: 5000000 presentationTimeUs:1766422 ,extractor.getSampleTime():1799766
I/CCodecBufferChannel: [c2.mtk.avc.decoder#6] cannot render buffer without surface
E/getBitmapBySec: presentationTimeUs: 1799766
D/PipelineWatcher: [0xb400007deea54068] pipelineFull: too many frames in pipeline (19)
E/kzg: **********************:
E/getBitmapBySec: presentationTimeUs: 1833111
D/PipelineWatcher: [0xb400007deea54068] pipelineFull: too many frames in pipeline (19)
E/kzg: **********************:
E/getBitmapBySec: sec: 5000000 presentationTimeUs:1833111 ,extractor.getSampleTime():1866455
D/PipelineWatcher: [0xb400007deea54068] pipelineFull: too many frames in pipeline (19)
I/CCodecBufferChannel: [c2.mtk.avc.decoder#6] cannot render buffer without surface
E/getBitmapBySec: presentationTimeUs: 1866455
D/PipelineWatcher: [0xb400007deea54068] pipelineFull: too many frames in pipeline (19)
E/kzg: **********************:
......
调试跟进到getBitmapBySec中,找到最后为bitmap赋值的分支,发现presentationTimeUs>=sec
和doRender
在控制是否输出图片,于是修改上层调用处的传入参数sec,发现又有图片输出了,但仍然存在上述报错。请问如何解决?
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.