LinuxQuestions.org
Review your favorite Linux distribution.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 06-27-2007, 12:03 PM   #1
zach014
LQ Newbie
 
Registered: Nov 2006
Distribution: Ubuntu
Posts: 16

Rep: Reputation: 0
problems with mencoder for video compatibility with Sansa e250


I found a mencoder script online to resize, change the frame rate, the rotation, change it to 420p, change it to grayscale, and change the file type in order for it to be playable on a Sandisk Sansa e250.
However, when i run this script, it tells me constantly that it is skipping a frame. When i remove the -ofps argument it goes fine, but in both instances when I open the resulting *.mov, it doesn't show any video. The audio works fine though. Here is the script:
Code:
#!/bin/bash
mencoder -ofps 15 -vf rotate=1,scale=160:208 -ffourcc mjpb -ovc lavc -lavcopts vcodec=mjpeg:vbitrate=150:vhq:gray -oac pcm -srate 11025 -of lavf -lavfopts i_certify_that_my_video_stream_does_not_use_b_frames futurama-12.mpg -o /tmp/video.mov
ffmpeg -i /tmp/video.mov -vcodec copy -acodec pcm_s16be futurama-12.mov
rm -f /tmp/video.mov
thanks in advance
~zach

EDIT (10:15 AM, JULY 17):
ok after trying each section of this code, i figured out that the problem was the section:
Code:
-ffourcc mjpgb
it wouldn't play in xine or mplayer when i converted it to MJPEG-B format
it also didnt work in the Sansa
is there some other way to convert it to MJPEG-B format, or perhaps some codecs i need?

Last edited by zach014; 07-17-2007 at 09:17 AM.
 
Old 06-28-2007, 05:07 AM   #2
Samotnik
Member
 
Registered: Jun 2006
Location: Belarus
Distribution: Debian GNU/Linux testing/unstable
Posts: 471

Rep: Reputation: 40
Try to play resulting video with $ mplayer -identify -v futurama-12.mov and grep output for all critical parameters (container format, video codec, video bitrate, audio codec, audio samplerate, dimensions etc.) to be the same as needed by your player.
 
Old 07-17-2007, 09:12 AM   #3
zach014
LQ Newbie
 
Registered: Nov 2006
Distribution: Ubuntu
Posts: 16

Original Poster
Rep: Reputation: 0
YES! a solution!
the script was a bit iffy
so here's the new one:
Code:
#!/bin/bash
INPUT="apple-getamac-fat_480x376.mov"
OUTPUT="apple-fat"
mencoder $INPUT -o /tmp/output.mov -oac pcm -af resample=11025 -ovc lavc -lavcopts vcodec=mjpeg:gray -ffourcc mjpa -vf rotate=1,scale=176:220 -ofps 12 -of lavf -lavfopts i_certify_that_my_video_stream_does_not_use_b_frames
ffmpeg -i /tmp/output.mov -vcodec copy -acodec pcm_s16be $OUTPUT.mov
rm -f /tmp/output.mov

Last edited by zach014; 07-17-2007 at 10:25 AM.
 
Old 07-17-2007, 08:00 PM   #4
reddazz
LQ Guru
 
Registered: Nov 2003
Location: N. E. England
Distribution: Fedora, CentOS, Debian
Posts: 16,298

Rep: Reputation: 77
zach014 we do not routinely delete threads or posts except in very exceptional circumstances. If your problem has been resolved, the thread is just kept as it is. Cheers.
 
Old 07-27-2007, 07:15 PM   #5
frenchn00b
Senior Member
 
Registered: Jun 2007
Location: E.U., Mountains :-)
Distribution: Debian, Etch, the greatest
Posts: 2,561

Rep: Reputation: 57
Nice thread.

I used this as "copy" mode & rotation :
Code:
mencoder /tmp/input.mov  -o /tmp/output.avi -oac pcm  -ovc lavc -vf rotate=1
 
Old 07-31-2007, 09:54 AM   #6
zach014
LQ Newbie
 
Registered: Nov 2006
Distribution: Ubuntu
Posts: 16

Original Poster
Rep: Reputation: 0
yep these scripts are all very well but for the color problem
so i just put rockbox on my e250 instead
rockbox.org
 
  


Reply



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 Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
frame rate slow down hummus Mandriva 1 09-25-2005 06:51 AM
abiword window frame resizing bm1 Slackware 2 11-04-2004 01:44 AM
Frame Rate LImiter qwacko Linux - Games 2 06-20-2004 05:23 PM
Problems with changing the frame buffer setting in console. adz Linux - Software 1 10-23-2003 02:25 AM
frame rate thegreatgatsby Linux - Software 2 10-07-2003 12:19 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 11:29 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
Open Source Consulting | Domain Registration