-
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
android FFmpegFrameRecorder and otaliastudios #2255
Comments
You'll need to call recorder.close() somewhere |
yes i do that ` long time = 1000*20;
` the size is 0 before the stop, and 212 after |
Please try again with the snapshots: http://bytedeco.org/builds/ |
thanks but if i change my build.gradle to implementation("org.bytedeco:javacv-platform:1.5.11-SNAPSHOT") Cannot resolve symbol 'bytedeco' this is code i use to save image in jpeg YuvImage yuvImage = new YuvImage(bitmapbytes, ImageFormat.NV21, width, height, null); but imageData doesn't works with javacv |
Hello
i use the library otaliastudios for managing camera
i set the recorder
recorder = new FFmpegFrameRecorder(ffmpeg_link, imageWidth, imageHeight, 0);
recorder.setFormat("flv");
recorder.setFrameRate(frameRate);
try {
recorder.start();
} catch (FFmpegFrameRecorder.Exception e) {
throw new RuntimeException(e);
}
then in frame processor i added
mCameraView.addFrameProcessor(new FrameProcessor() {
@OverRide
@workerthread
public void process(@nonnull Frame frame) {
try {
Log.d(TAG, "add frame ok");
recorder.record(frame.getData());
} catch (FFmpegFrameRecorder.Exception e) {
Log.d(TAG, "add frame ko");
throw new RuntimeException(e);
}
then i stopped the record after 10 seconds
but the flv file has a very low size of 212 ( bytes )
and is unreadeable
any suggestion ?
how can i convert the frame ( otaliastudio format ) to javacv.Frame
Required type:
org.bytedeco.javacv.Frame
Provided:
com.otaliastudios.cameraview.frame.Frame
thanks
The text was updated successfully, but these errors were encountered: