tapioca
tapioca copied to clipboard
video_processing_failed
Unhandled Exception: PlatformException(video_processing_failed, video processing is failed., null, null)
[ERROR:flutter/lib/ui/ui_dart_state.cc(209)] Unhandled Exception: PlatformException(video_processing_failed, video processing is failed., null, null)
StandardMethodCodec.decodeEnvelope (package:flutter/src/services/message_codecs.dart:607:7)
MethodChannel._invokeMethod (package:flutter/src/services/platform_channel.dart:177:18)
Getting this error after selection of file and send "Cup" for Video editing.
try { var tempDir = await getTemporaryDirectory(); final path = '${tempDir.path}/result2.mp4'; final tapiocaBalls = [ TapiocaBall.filter(Filters.pink), //TapiocaBall.imageOverlay(imageBitmap, 300, 300), TapiocaBall.textOverlay("text", 100, 10, 100, const Color(0xffffc0cb)), ]; final cup = Cup(Content(video.path), tapiocaBalls); cup.suckUp(path).then(() async { print("finished"); print(path); GallerySaver.saveVideo(path).then((bool? success) { print(success.toString()); });
setState(() {});
});
} on Exception {
print("error!!!!");
}
I need help on this issue... can anyone help on the same
Thanks.
I also encountered the same problem. How did you solve it
@UjjawalPanchal @nur001 on iOS or Android?
I have tried it on Android.
i had the same problem but when i run the app on my real device it works good
not working in emulator work only in physical device
Even I am still facing this issue on Android real device
I am trying to apply tapioca filter to a video which was created using ffmpeg package in flutter. but it giving me the same above error. But when I try to apply regular camera generated videos, it works fine. Why? I am giving below the command I used to generate ffmpeg video : String command = "-hide_banner -y " + customImagePaths + "-filter_complex " + ""[0:v]setpts=PTS-STARTPTS,scale=w='if(gte(iw/ih,640/427),min(iw,640),-1)':h='if(gte(iw/ih,640/427),-1,min(ih,427))',scale=trunc(iw/2)*2:trunc(ih/2)*2,setsar=sar=1/1,split=2[stream1out1][stream1out2];" + "[1:v]setpts=PTS-STARTPTS,scale=w='if(gte(iw/ih,640/427),min(iw,640),-1)':h='if(gte(iw/ih,640/427),-1,min(ih,427))',scale=trunc(iw/2)*2:trunc(ih/2)*2,setsar=sar=1/1,split=2[stream2out1][stream2out2];" + "[stream1out1]pad=width=640:height=427:x=(640-iw)/2:y=(427-ih)/2:color=#00000000,trim=duration=3,select=lte(n\,90)[stream1overlaid];" + "[stream1out2]pad=width=640:height=427:x=(640-iw)/2:y=(427-ih)/2:color=#00000000,trim=duration=1,select=lte(n\,30)[stream1ending];" + "[stream2out1]pad=width=640:height=427:x=(640-iw)/2:y=(427-ih)/2:color=#00000000,trim=duration=2,select=lte(n\,60)[stream2overlaid];" + "[stream2out2]pad=width=640:height=427:x=(640-iw)/2:y=(427-ih)/2:color=#00000000,trim=duration=1,select=lte(n\,30),split=2[stream2starting][stream2ending];" + "[stream2starting][stream1ending]blend=all_expr='if(gte(X,(W/2)*T/1)*lte(X,W-(W/2)*T/1),B,A)':shortest=1[stream2blended];" + "[stream3starting][stream2ending]blend=all_expr='if(gte(X,(W/2)*T/1)*lte(X,W-(W/2)*T/1),B,A)':shortest=1[stream3blended];" + "[stream1overlaid][stream2blended][stream2overlaid]concat=n=3:v=1:a=0,scale=w=640:h=424,format=" + "yuv420p" + "[video]"" + " -map [video] -fps_mode cfr " + "" + "-c:v " + "mpeg4" + " -r 30 " + output_path;