如何显示实时滤波相机preVIEW同时录制视频?实时、相机、视频、preVIEW

2023-09-04 23:42:50 作者:一句苍白丷

我想告诉过滤相机preVIEW同时使用记录媒体记录的视频。要过滤preVIEW我需要的帧正常,我可以拿到从previewFrame()函数,但同时录制媒体记录的视频,在previewFrame()函数不会被调用。所以我想知道,有没有其他的方法来获得这些帧进行过滤,然后修改后告诉他们?我查了从谷歌一些应用程序播放为例,幻觉的VideoCam。它显示preVIEW与在录制视频的效果。我想要做这样的事情,但没有提示如何这样做。因此,我将AP preciate有关问题的任何帮助/提示/ code /样品。谢谢你。

I want to show filtered camera preview while recording a video using media recorder. To filter the preview i need frames normally which i can get that from onPreviewFrame() function but while recording video with media recorder, onPreviewFrame() function does not get called. So what i want to know , is there any other ways to get these frames for filtering and then show them after modification ? I checked some apps from Google Play for example, Videocam Illusion. Its showing preview with effects during recording videos. I want to do something like that but have no hint how to do so. So i will appreciate any help/hints/code/sample regarding the issue. Thanks.

推荐答案

我没有做它自己,但就在不久前寻找它。有一个关于StackOverflow的答案,以显示previewFrame修改过的缓冲区:

I haven't done it myself, but searched for it not so long ago. There's an answer on StackOverflow to show modified buffer of PreviewFrame:

的https://groups.google.com/forum/?fromgroups=#!topic/android-developers/yF6CmrIJzuo

在这里,一个谷歌的团体链接在同一主题。

And here, a google groups link on the same topic.

如何操作相机preVIEW

How can I manipulate the camera preview?

希望这会有所帮助,我打算修改该preVIEW帧的应用,但不会记录任何东西。

Hope this helps, I'm planning on an application that modifies the preview frames, but is not going to record anything.

最佳Regars。