Mp4Composer-android icon indicating copy to clipboard operation
Mp4Composer-android copied to clipboard

Mp4Composer: Unable to compose the engine

Open HirenBharodiya opened this issue 3 years ago • 9 comments

Hello,

I'm apply GlWatermarkFilter on video Its work great, but some time I facing an error like this...

com.app_package E/Mp4Composer: Unable to compose the engine java.lang.IllegalStateException: Failed to stop the muxer at android.media.MediaMuxer.nativeStop(Native Method) at android.media.MediaMuxer.stop(MediaMuxer.java:454) at android.media.MediaMuxer.release(MediaMuxer.java:694) at com.daasuu.mp4compose.composer.Mp4ComposerEngine.compose(Mp4ComposerEngine.java:159) at com.daasuu.mp4compose.composer.Mp4Composer$2.run(Mp4Composer.java:305) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1167) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:641) at java.lang.Thread.run(Thread.java:764) 2020-09-08 11:06:00.769 18745-19244/com.app_package E/Mp4Composer: Unable to compose the engine java.lang.IllegalStateException: writeSampleData returned an error at android.media.MediaMuxer.nativeWriteSampleData(Native Method) at android.media.MediaMuxer.writeSampleData(MediaMuxer.java:682) at com.daasuu.mp4compose.composer.MuxRender.writeSampleData(MuxRender.java:92) at com.daasuu.mp4compose.composer.RemixAudioComposer.drainEncoder(RemixAudioComposer.java:196) at com.daasuu.mp4compose.composer.RemixAudioComposer.stepPipeline(RemixAudioComposer.java:102) at com.daasuu.mp4compose.composer.Mp4ComposerEngine.runPipelines(Mp4ComposerEngine.java:267) at com.daasuu.mp4compose.composer.Mp4ComposerEngine.compose(Mp4ComposerEngine.java:133) at com.daasuu.mp4compose.composer.Mp4Composer$2.run(Mp4Composer.java:305) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1167) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:641) at java.lang.Thread.run(Thread.java:764)

HirenBharodiya avatar Sep 08 '20 05:09 HirenBharodiya

I am facing this issue too. I am using GlFilter

D/Mp4Composer: rotation = 0 D/Mp4Composer: rotation = NORMAL D/Mp4Composer: inputResolution width = 360 height = 460 outputResolution width = 360 height = 560 fillMode = PRESERVE_ASPECT_FIT bitrate=1512000 W/FileSource: offset/length adjusted from 0/576460752303423487 to 0/1194906 E/Mp4Composer: Unable to compose the engine java.lang.RuntimeException: setDataSource failed: status = 0xFFFFFFEA at android.media.MediaMetadataRetriever.setDataSource(Native Method) at android.media.MediaMetadataRetriever.setDataSource(MediaMetadataRetriever.java:141) at com.daasuu.mp4compose.composer.Mp4ComposerEngine.compose(Mp4ComposerEngine.java:82) at com.daasuu.mp4compose.composer.Mp4Composer$2.run(Mp4Composer.java:305) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1167) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:641) at java.lang.Thread.run(Thread.java:764) W/System: A resource failed to call close.

@MasayukiSuda

GujjuFlutterGuy avatar Sep 09 '20 07:09 GujjuFlutterGuy

I got same issue 10-24 23:44:50.726 26418-26893/com.daasuu.mp4composer E/Mp4Composer: Unable to compose the engine java.lang.IllegalStateException: Failed to stop the muxer at android.media.MediaMuxer.nativeStop(Native Method) at android.media.MediaMuxer.stop(MediaMuxer.java:242) at com.daasuu.mp4compose.composer.Mp4ComposerEngine.compose(Mp4ComposerEngine.java:149) at com.daasuu.mp4compose.composer.Mp4Composer$2.run(Mp4Composer.java:312) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1113) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:588) at java.lang.Thread.run(Thread.java:818) 10-24 23:44:50.726 26418-26893/com.daasuu.mp4composer E/SAMPLE: onFailed() Failed to stop the muxer

dondell avatar Oct 24 '21 15:10 dondell

same issue.

sanketk478 avatar Oct 27 '21 09:10 sanketk478

@sanketk478 You can use https://github.com/MasayukiSuda/GPUVideo-android/

dondell avatar Oct 28 '21 05:10 dondell

any update on this issue @MasayukiSuda ? I am also facing this issue !

Thanks !

ranaaditya avatar Nov 13 '21 06:11 ranaaditya

I got the same issue when my video was too high res

DoozyDoz avatar Aug 14 '22 17:08 DoozyDoz

@sanketk478 You can use https://github.com/MasayukiSuda/GPUVideo-android/

doesnt solve it , I tried . the solution is to reduce the res (width, height)

DoozyDoz avatar Aug 14 '22 17:08 DoozyDoz

image Facing same issue

umairshah143 avatar Dec 21 '23 05:12 umairshah143

Same issue... Dear @MasayukiSuda are you planning to respond after 3 years ? or is this project abandoned ?

DannyFilo avatar Mar 30 '24 15:03 DannyFilo