Comments (18)
Hello All,
I was facing the same problem.
and i found one solution.
add following before output
-c:v libx264 -preset ultrafast
it will help to decrease processing time.
from ffmpeg-android-java.
Hello All,
I was facing the same problem.
and my video is 12 second and it will take long time to compress ,
i need it will complete within 12-15 second .
i am using below command with video size 45mb and 12 second.
"ffmpeg -y -i /sdcard/videokit/input.mp4 -s 320x240 -r 20 -c:v libx264 -preset ultrafast -c:a copy -me_method zero -tune fastdecode -tune zerolatency -strict -2 -b:v 1000k -pix_fmt yuv420p /sdcard/videokit/123out.mp4";
Please help me to complete this compressor in 12-15 second.
from ffmpeg-android-java.
This command make video processing really fast
-c:v libx264 -preset ultrafast
I am working on slowing video playback.
from ffmpeg-android-java.
Hi.. I am using
-y -i /sdcard/videokit/in.mp4 -strict experimental -vcodec libx264 -preset ultrafast -crf 24 -acodec aac -ar 44100 -ac 2 -b 36000k -s 1280x720 -aspect 16:9 -metadata:s:v:0 rotate=0 /sdcard/videokit/out3.mp4
command. It reduce the compression time little.
from ffmpeg-android-java.
anyone please help me to solve the issue.
Unable to find a suitable output format for 'ffmpeg' ffmpeg: Invalid argument
tried many ways and also change commands but still the same issue
"ffmpeg -y -i "+path+" -s 320x240 -r 20 -c:v libx264 -preset ultrafast -c:a copy -me_method zero -tune fastdecode -tune zerolatency -strict -2 -b:v 1000k -pix_fmt yuv420p "+outputFilePath;
input and output format is mp4.i want to compress the video
from ffmpeg-android-java.
try this
ffmpeg -i /storage/emulated/0/Movies/Instagram/VID_219920217_214928_732.mp4 -vf scale=-1:480.0 -threads 16 -c:v libx264 -maxrate 1984k -bufsize 3968k -ac 2 -vf format=yuv420p -g 60 -c:a aac -b:a 128k -ar 44100 -movflags +faststart -profile:v baseline -level 3.1 -crf 28 -preset ultrafast -strict -2 /storage/emulated/0/Android/data/com.staze/cache/1514433292621.mp4
Working fine for me using
compile 'com.writingminds:FFmpegAndroid:0.3.2'
from ffmpeg-android-java.
I ran into same issue here. I suspect making up a service may help since main thread is in charge of UI drawing, etc.
It's only a guess, in fact I'll try this option and then share my discoveries.
from ffmpeg-android-java.
* Overlaying two videos of around max 15 seconds**
I am also facing same issue. Even for a 5 second video the processing time is around 1 minute.
We are using service with a handlerthread, but still we are facing the issue.
Please Help.
from ffmpeg-android-java.
Also noticed that, conversion is very slow. Fortunately "-preset ultrafast" helped a lot.
from ffmpeg-android-java.
Hi
I have used below command but right now its display '-preset' Unrecognized option.
-y -i /sdcard/videokit/in.mp4 -strict experimental -vcodec libx264 -preset ultrafast -crf 24 -acodec aac -ar 44100 -ac 2 -b 36000k -s 1280x720 -aspect 16:9 -metadata:s:v : 0 rotate=0 /sdcard/videokit/out3.mp4
from ffmpeg-android-java.
Hi,
I too had the same issue with "-preset ultrafast" command. Here is the error from log:
Reading option '-preset' ...Unrecognized option 'preset'.
Error splitting the argument list: Option not found
ffmpeg4android: ffmpeg_parse_options not passed
exit_program: 1
from ffmpeg-android-java.
Hi rt1909
i think in android library there are "-preset ultrafast " not supported if you found than please replay hear.
from ffmpeg-android-java.
Hi Sanjay,
I have checked it. In the blog post they mentioned about using the "-preset
ultrafast" in combination with mpeg4 codec. But it seems it works only with
libx264.
On Thu, Jul 28, 2016 at 12:49 PM, Sanjay Bhalani [email protected]
wrote:
Hi rt1909
i think in android library there are "-preset ultrafast " not supported
if you found than please replay hear.—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub
#54 (comment),
or mute the thread
https://github.com/notifications/unsubscribe-auth/ATeQKl0yAV5dTveyIav9K4I3tyZrpHOgks5qaFgHgaJpZM4Gmb_F
.
from ffmpeg-android-java.
Hi rt1909
Yes but in my case it's seem to taken to much time for compressed video also decries video quality. Below command is working fine with same quality, but it's also take 30 to 50 second for compressing any video.
"ffmpeg -y -i in.mp4 -strict experimental -r 30 -ab 48000 -ac 2 -ar 48000 -vcodec mpeg4 -b 2097152 out.mp4"
from ffmpeg-android-java.
What is -b:v stands for if bitrate how setting -b:v 1000k decrease the process time
from ffmpeg-android-java.
What is -b:v stands for if bitrate how setting -b:v 1000k decrease the process time
-b:v means you want to alter bitrate of the video stream. -v:b 1000k means that in the output video, the bitrate of video stream will be 1000 bps. It should decrease processing time becuase the bitrate is low.
from ffmpeg-android-java.
/usr/bin/ffmpeg -y -i /var/www/vod/storage/app/public/temp/GIbSMv9DcueO2maksuvZ6ZeWvGcSiDI4RMtn4qzB.mp4 -map 0 -flags -global_header -f segment -segment_format mpeg_ts -segment_list /var/www/vod/storage/app/public/movies/lopl//nonenc/l69enpRRLtbJuO3wBSbM_1500.m3u8 -segment_time 6 -threads 12 -vcodec libx264 -acodec aac -b:v 1500k -refs 6 -coder 1 -sc_threshold 40 -flags +loop -me_range 16 -subq 7 -i_qfactor 0.71 -qcomp 0.6 -qdiff 4 -trellis 1 -b:a 128k -pass 1 -passlogfile /tmp/ffmpeg-passes5f73880a9868fmowmp/pass-5f73880a9881a /var/www/vod/storage/app/public/movies/lopl//nonenc/l69enpRRLtbJuO3wBSbM_1500_%05d.ts
this is my command
but very slow!!
i am using php and laravel-ffmpeg
i change thread from 12 to 16 but not effective!
this command use very cpu but not effective
ram is very low usage
please help me
from ffmpeg-android-java.
Did anyone got the command which is fast for video compression in android. i have been trying to reduce the compression time but nothing seems to be working. if anyone have the way please reply
from ffmpeg-android-java.
Related Issues (20)
- Can i use "copy" in the slow motion command? Currently getting error "Filtering and streamcopy cannot be used together"
- Not working with Android 10 HOT 2
- Not Working on Android api target 29 HOT 4
- Using along with Javacv
- its not working with android 10 shows Permission denied HOT 4
- Permission Denied Exception HOT 5
- Can I have an example of input array you put into the ffmpeg.execute function ??|
- Can I have an example of input array you put into the ffmpeg.execute function ??|
- FFmpegLoadLibraryAsyncTask.onPostExecute never gets called
- No such directory. Ffmpeg libavcodec libavutil and other files no such directory. I tried sample and tried with -version command its working fine but when i trim a video shows this error
- how to apply filter on videos? HOT 2
- its not working with android 10 shows Permission denied Error Code 13 HOT 2
- how to generate video from arraylist.
- I am using ffmpeg in android but taking much time to crop the video
- Text Relocation in API level >23
- how to split videos into parts
- what is command for adding text and audio in videoview
- command for adding audio(mp3) to mp4
- Can the live audio stream address and the live video stream address be combined into the live audio & video stream address of the two stream addresses?
- BG-380-[hevc @ 0xe86ff800] Could not find ref with POC 34
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from ffmpeg-android-java.