Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!


video should be H264+AAC codecs - How to do on a Ubuntu VPS
New on LowEndTalk? Please Register and read our Community Rules.

All new Registrations are manually reviewed and approved, so a short delay after registration may occur before your account becomes active.

video should be H264+AAC codecs - How to do on a Ubuntu VPS

Hello friends, I'm not an expert in handling server related stuff. I want to know how to encode videos in to streamable formats. Exactly "H264+AAC codecs". FFMPEG is very tricky. Can someone guide me pls...

Comments

  • You could use Plexus. https://github.com/Wolveix/Plexus

    Developed by @Wolveix.

    Thanked by 2paily Wolveix
  • randy33randy33 Member
    edited June 2020

    @vladimirlenin Convert the video with libx264 and audio to AAC two channels:
    ffmpeg -i input.mp4 -c:v libx264 -crf 22 -preset:v veryfast -ac 2 -c:a libfdk_aac -vbr 3 output.mp4

  • Hey @randy33 Thanks. But I'm getting this error :'( Unknown encoder 'libfdk_aac'

  • @vladimirlenin
    Try
    ffmpeg -i input.mp4 -vcodec libx264 -crf 22 -preset:v veryfast -ac 2 -acodec aac -ab 128K -strict -2 output.mp4

  • @randy33 thank you so much bro <3 You are the saviour.....

  • randy33randy33 Member
    edited June 2020

    @vladimirlenin
    You can vary the quality of the video with presets. A preset is a collection of options that will provide a certain encoding speed to compression ratio. A slower preset will provide better compression (compression is quality per filesize). This means that, for example, if you target a certain file size or constant bit rate, you will achieve better quality with a slower preset. Similarly, for constant quality encoding, you will simply save bitrate by choosing a slower preset.

    Use the slowest preset that you have patience for. The available presets in descending order of speed are:
    ultrafast
    superfast
    veryfast
    faster
    fast
    medium – default preset
    slow
    slower
    veryslow

  • Hey @randy33 i need one more help. How to auto convert all downloaded videos that are not in above format without executing the above command manually? Thanks :)

  • Batch command line
    for i in *.mp4; do ffmpeg -i "$i" -vcodec libx264 -crf 22 -preset:v veryfast -ac 2 -acodec aac -ab 128K -strict -2 "$i_encode.mp4"; done

  • @vladimirlenin What kind of video do you encode btw

  • @randy33 said:
    Batch command line
    for i in *.mp4; do ffmpeg -i "$i" -vcodec libx264 -crf 22 -preset:v veryfast -ac 2 -acodec aac -ab 128K -strict -2 "$i_encode.mp4"; done

    Thank you so much @randy33 you are awesome <3 I messaged you the details
    :P

Sign In or Register to comment.