LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - General
User Name
Password
Linux - General This Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.

Notices



Reply
 
Search this Thread
Old 04-15-2012, 03:17 AM   #1
linuxlicious
Member
 
Registered: May 2011
Posts: 58

Rep: Reputation: 0
Mencoder adds the extension of the original file to the output file ex: file.flv.mp4


I'm trying to convert some .flv files to .mp4 with mencoder, but it keeps adding the extension of the original file to the output file, so that I end up with file.flv.mp4. Can I simply remove the .flv extension or will I have to encode it in a different way, and if yes, then how do I prevent this from happening in the first place?
 
Old 04-15-2012, 05:07 AM   #2
jschiwal
Guru
 
Registered: Aug 2001
Location: Fargo, ND
Distribution: SuSE AMD64
Posts: 15,733

Rep: Reputation: 655Reputation: 655Reputation: 655Reputation: 655Reputation: 655Reputation: 655
Could you post the script you use?

I have a script in $HOME/bin/ that uses mencoder. If I hadn't used the third line, I would see two extensions as well. I suspect you are not removing the extension from the input file, and tacking on .mp4 after the -o option.

Code:
#!/bin/bash
videoin="$1"
videoout="${videoin%.*}.svi"
if [ -f "$videoin" ]; then
    mencoder -vf scale=480:272 -ofps 29.97 -ffourcc XVID \
             -oac mp3lame -lameopts cbr:br=128 \
             -ovc xvid \
             -xvidencopts max_bframes=0:quant_type=mpeg:bitrate=1024 \
             -af resample=44100 \
             "$videoin" \
             -o "$videoout" 
fi
 
1 members found this post helpful.
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Mencoder adds the extension of the original file to the output file ex: file.flv.mp4 linuxlicious Linux - General 2 04-17-2012 03:22 PM
[SOLVED] no thumbnail for flv file though present for mpg,avi & mp4 files sumeet inani Ubuntu 7 05-07-2010 05:53 AM
gzip but keep the original file, and bzip2 - multiple files to one file? SirTristan Linux - Newbie 4 10-20-2009 04:37 AM
Trying to convert from flv to mp4 (for iPod) using mencoder. alkos333 Slackware 6 11-03-2007 03:36 PM
why when redirecting output to a file any file extension seems to be fine? dr_zayus69 Linux - General 1 05-21-2005 05:09 AM


All times are GMT -5. The time now is 07:31 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration