maemo.org - Talk

maemo.org - Talk (https://talk.maemo.org/index.php)
-   General (https://talk.maemo.org/forumdisplay.php?f=7)
-   -   Tablet-encode & mencoder (https://talk.maemo.org/showthread.php?t=12249)

JeffElkins 2007-11-25 17:09

Tablet-encode & mencoder
 
Andrew,

These are my results using current svn version of tablet-encode as compared to 'straight' mencoder. I may well not have used tablet-encode to it's best advantage.

Code:


filesize:70833360
the_counter_clock_incident.tb.avi
Produced with tablet-encode -o --preset=best

Video and audio rapidly lose sync. Video appears jerky.
Only playable with mplayer.

AVI file format detected.
VIDEO:  [DIVX]  320x240  24bpp  23.976 fps  273.4 kbps (33.4 kbyte/s)
Clip info:
 Software: MEncoder 2:1.0~rc2-0ubuntu1~gutsy1
[nokia770] Nokia N800 hardware detected
==========================================================================
Opening video decoder: [ffmpeg] FFmpeg's libavcodec codec family
Selected video codec: [ffodivx] vfm: ffmpeg (FFmpeg MPEG-4)
==========================================================================
==========================================================================
Trying to force audio codec driver family dspmp3...
Opening audio decoder: [dspmp3] MP3 audio pass-through for Nokia 770/N800
(fake decoder)
ADecoder preinit failed :(
ADecoder init failed :(
Trying to force audio codec driver family libmad...
Opening audio decoder: [libmad] libmad mpeg audio decoder
AUDIO: 44100 Hz, 2 ch, s16le, 128.0 kbit/9.07% (ratio: 16000->176400)
Selected audio codec: [mad] afm: libmad (libMAD MPEG layer 1-2-3)
==========================================================================
[AO SDL] Samplerate: 44100Hz Channels: Stereo Format s16le
AO: [sdl] 44100Hz 2ch s16le (2 bytes per sample)
Starting playback...
VDec: vo config request - 320 x 240 (preferred colorspace: Planar YV12)
VDec: using Planar YV12 as output csp (no 0)
Movie-Aspect is 1.33:1 - prescaling to correct movie aspect.
VO: [nokia770] 320x240 => 320x240 Planar YV12  [fs] [zoom]
[nokia770] Using ARM JIT YUV420 scaler (quality=2) to scale 320x240 =>
320x240


============================

filesize:134529848
 the_counter_clock_incident.nk.avi
produced by:
mencoder -vf scale=320:240 -oac mp3lame -ovc lavc -lavcopts vcodec=mpeg4 $1 -o $2.avi

Audio and video remain in sync. Video is smooth.
Playable with both mplayer and Nokia media player.


Cache fill:  0.00% (0 bytes)
AVI file format detected.
VIDEO:  [FMP4]  320x240  24bpp  23.976 fps  571.8 kbps (69.8 kbyte/s)
Clip info:
 Software: MEncoder 2:1.0~rc2-0ubuntu1~gutsy1
[nokia770] Nokia N800 hardware detected
==========================================================================
Opening video decoder: [ffmpeg] FFmpeg's libavcodec codec family
Selected video codec: [ffodivx] vfm: ffmpeg (FFmpeg MPEG-4)
==========================================================================
==========================================================================
Trying to force audio codec driver family dspmp3...
Opening audio decoder: [dspmp3] MP3 audio pass-through for Nokia 770/N800
(fake decoder)
ADecoder preinit failed :(
ADecoder init failed :(
Trying to force audio codec driver family libmad...
Opening audio decoder: [libmad] libmad mpeg audio decoder
AUDIO: 44100 Hz, 2 ch, s16le, 32.0 kbit/2.27% (ratio: 4000->176400)
Selected audio codec: [mad] afm: libmad (libMAD MPEG layer 1-2-3)
==========================================================================
[AO SDL] Samplerate: 44100Hz Channels: Stereo Format s16le
AO: [sdl] 44100Hz 2ch s16le (2 bytes per sample)
Starting playback...
VDec: vo config request - 320 x 240 (preferred colorspace: Planar YV12)
VDec: using Planar YV12 as output csp (no 0)
Movie-Aspect is 1.33:1 - prescaling to correct movie aspect.
VO: [nokia770] 320x240 => 320x240 Planar YV12  [fs] [zoom]
[nokia770] Using ARM JIT YUV420 scaler (quality=2) to scale 320x240 => 320x240


aflegg 2007-11-25 20:08

Re: Tablet-encode & mencoder
 
Thanks very much for this.

Is this being played back on an N800? Using OS2007 or OS2008?

When you say "only playable with mplayer", do you mean it plays back well with mplayer or that it suffers from the problems you describe and Media Player won't touch it at all? If the latter, does it give an error message?

JeffElkins 2007-11-25 20:46

Re: Tablet-encode & mencoder
 
I'm using OS2008 on an N800.

The file won't play at all with the Nokia media player, but oddly enough no error message. Media player goes into zoom mode, but the video never starts.


Playback with mplayer gives alightly jerky video and the sound is badly out of sync with the video.

Serge 2007-11-25 20:58

Re: Tablet-encode & mencoder
 
I remember having problems with '-noidx' option in some older version of 770-encode.pl script. After removing this option, everything got much better. Is it really needed?

JeffElkins 2007-11-25 21:22

Re: Tablet-encode & mencoder
 
Quote:

Originally Posted by Serge (Post 99804)
I remember having problems with '-noidx' option in some older version of 770-encode.pl script. After removing this option, everything got much better. Is it really needed?

Good call.

Code:

#  push @params, ($options{"index"} ? '-forceidx' : '-noidx');
After commenting out the line above, audio/video are back in sync.

Nikem 2007-11-25 21:32

Re: Tablet-encode & mencoder
 
Yeah, I removed the '-noidx' option too, because else I couldn't skip in the videos.

JeffElkins 2007-11-25 21:37

Re: Tablet-encode & mencoder
 
One other change...

I changed:

Code:

push @params, '-ffourcc', 'DIVX';
To:
Code:

push @params, '-ffourcc', 'FMP4';
and the output file plays in both mplayer and Nokia media player.

aflegg 2007-11-25 22:12

Re: Tablet-encode & mencoder
 
Interesting. Thanks for all the comments, I'll integrate these changes in the next version. I can't remember why -noidx was in there. It won't be any longer :-)

Jeff, did you see a difference in playback performance between the two FOURCCs?

aflegg 2007-11-25 22:20

Re: Tablet-encode & mencoder
 
Jeff,

Could you do me a favour, and also `dd if=the_counter_clock_incident.tb.avi of=fragment.avi bs=1M count=20' and send me the result?

If you need somewhere to FTP it, let me know.

Many thanks in advance,

Andrew

JeffElkins 2007-11-25 22:25

Re: Tablet-encode & mencoder
 
Quote:

Originally Posted by aflegg (Post 99834)
Jeff, did you see a difference in playback performance between the two FOURCCs?

Performance seems about the same. The only difference is that FMP4 works with both players: Nokia's and mplayer.

BTW, tablet-encode just did an excellent job on ST2:Wrath of Khan. 400Mb and the aspect ratio/playback is perfect.

JeffElkins 2007-11-25 22:59

Re: Tablet-encode & mencoder
 
Quote:

Originally Posted by aflegg (Post 99838)
Jeff,

Could you do me a favour, and also `dd if=the_counter_clock_incident.tb.avi of=fragment.avi bs=1M count=20' and send me the result?

If you need somewhere to FTP it, let me know.

Many thanks in advance,

Andrew

Sure. I'll PM you when it's ready.

aflegg 2007-11-26 13:25

Re: Tablet-encode & mencoder
 
Thanks. I'll do some more playing and include this all in v2.01.

Many thanks,

Andrew

mplawner 2007-11-26 20:36

Re: Tablet-encode & mencoder
 
Thanks for -c ! Works great!

ranasing 2007-11-28 20:47

Re: Tablet-encode & mencoder
 
I am trying to get the latest version of mplayer installed on a N800 with OS800 beta on it. It says it is missing the libmad0 packages. Can you explain where this package is installed from? Thanks!

aflegg 2007-11-28 21:24

Re: Tablet-encode & mencoder
 
The latest version in svn now features all the requirements and requests in this thread, comments and testing welcome:

https://garage.maemo.org/plugins/scm...iautils&rev=48

The only feature holding up a proper release is taking general DVD requests and turning that into the longest title using `mplayer -identify'. Hopefully done this weekend.

@ranasing: there are other threads discussing mplayer on OS2008, I suggest you try there :-)

JeffElkins 2007-11-28 21:52

Re: Tablet-encode & mencoder
 
Thanks for your work on this useful tool Andrew!

ranasing 2007-11-28 22:46

Re: Tablet-encode & mencoder
 
Ok, I did do a search for mplayer, but this was one of the few threads I found. Can you direct me to any specific threads. Thanks!

JeffElkins 2007-11-28 22:51

Re: Tablet-encode & mencoder
 
Code:

Package: libmad0
Priority: optional
Section: libs
Installed-Size: 156
Maintainer: Mad Maintainers <pkg-mad-maintainers@lists.alioth.debian.org>
Architecture: armel
Source: libmad
Version: 0.15.1b-2.1
Depends: libc6 (>= 2.3.5-1)
Filename: pool/chinook/free/libm/libmad/libmad0_0.15.1b-2.1_armel.deb
Size: 75112
MD5sum: 8e5b013df4a4fc012e81ca8d77aef6f2
SHA1: a8bab91aa52ad927415f09072764f014548e3358
SHA256: 69fdf6436bf717b98e2d5eefe11dd2a9c53b5a594816af9d1dc1f11741545a48
Description: MPEG audio decoder library
 MAD is an MPEG audio decoder. It currently only supports the MPEG 1
 standard, but fully implements all three audio layers (Layer I, Layer II,
 and Layer III, the latter often colloquially known as MP3.)
 .
 MAD has the following special features:
  - 100% fixed-point (integer) computation
  - completely new implementation based on the ISO/IEC 11172-3 standard
  - distributed under the terms of the GNU General Public License (GPL)


ranasing 2007-11-29 00:18

Re: Tablet-encode & mencoder
 
I tried installing that package and it won't let me. I get a "incompatible application package" error. I don't know if is related to having OS2008 beta on my N800. It seems like other people have been able to get it, mplayer, to install on a N800 with OS2008. Any assistance would be greatly appreciated. Thanks!

ranasing 2007-11-29 00:27

Re: Tablet-encode & mencoder
 
Ok, success! I don't know what happened, but I got it to finally install. Now on to UKMP! ;)

JeffElkins 2007-12-01 23:26

Re: Tablet-encode & mencoder
 
Just as an end-note for this thread, I just tested the newest version of tablet-encode.

My verdict: Excellent!

Thanks, Andrew :)

aflegg 2007-12-02 20:38

Re: Tablet-encode & mencoder
 
FWIW, the latest version which Jeff mentions has now been properly released:

https://garage.maemo.org/frs/?group_id=455

Full details at:
https://garage.maemo.org/frs/shownot...elease_id=1223

Tesiph 2007-12-05 22:16

Re: Tablet-encode & mencoder
 
Small 'bug': If the resolution of the movie is smaller than that of the preset, it gets upscaled.

aflegg 2007-12-08 11:45

Re: Tablet-encode & mencoder
 
Quote:

Originally Posted by Tesiph (Post 104961)
Small 'bug': If the resolution of the movie is smaller than that of the preset, it gets upscaled.

Good point, it won't do this if the source is DivX or similar; but the same should be done for other input formats as well.

bubieyehyeh 2008-03-24 00:24

Re: Tablet-encode & mencoder
 
Quote:

Originally Posted by JeffElkins (Post 99819)
One other change...

I changed:

Code:

push @params, '-ffourcc', 'DIVX';
To:
Code:

push @params, '-ffourcc', 'FMP4';
and the output file plays in both mplayer and Nokia media player.

That may help on the Nokia 800 or later, but changing from DIVX stops it working in the nokia media player on my 770.

There is a bug on the maemo garage site
[#1900] tablet-encode produces videos unplayable on a 770 (audio codec not supported)

I modified tablet-encode, and changed back to DIVX. And files now work, however best doesn't work in Nokia player (maybe only mplayer not yet checked)

Wierd that changing the fourcc, gives a audio codec error in 770's nokia media player!

Any chance of a 770 option in tablet encode Andrew?

Jaffa 2008-03-25 11:11

Re: Tablet-encode & mencoder
 
Yep, 2.18 is under development and adds a '--770' option for a 770-compatible FOURCC, brings back a very high spec profile for mplayer and will (when it's finished) have the ability to read additional profiles from your home directory.

More info can be seen in the Subversion commit log:

https://garage.maemo.org/plugins/scm...utils&view=log

bubieyehyeh 2008-03-25 21:41

Re: Tablet-encode & mencoder
 
Quote:

Originally Posted by Jaffa (Post 159838)
Yep, 2.18 is under development and adds a '--770' option for a 770-compatible FOURCC, brings back a very high spec profile for mplayer and will (when it's finished) have the ability to read additional profiles from your home directory.

Thanks Andrew,

I've been using 770-encode (v1.35) for a while. I noticed the bitrates have increased with tablet-encoder for presets with the same name. Are they now optimized for the 800/810?

The "best" preset in tablet-encoder won't play on nokia media player on 770 due to too high a resolution.

Would it be better to readjust the presets to lower values when the --770 is used?

Heres a comparison using grep...

tablet-encode: smallest => { abitrate => 32, vbitrate => 80, width => 240 },
tablet-encode: small => { abitrate => 96, vbitrate => 150, width => 240 },
tablet-encode: average => { abitrate => 128, vbitrate => 350, width => 320, fps => 30 },
tablet-encode: good => { abitrate => 160, vbitrate => 600, width => 352, fps => 30 },
tablet-encode: best => { abitrate => 192, vbitrate => 768, width => 400, height => 240, fps => 30 },
770-encode.pl: smallest => { abitrate => 32, vbitrate => 80, width => 240 },
770-encode.pl: small => { abitrate => 96, vbitrate => 96, width => 240 },
770-encode.pl: average => { abitrate => 96, vbitrate => 200, width => 320 },
770-encode.pl: good => { abitrate => 128, vbitrate => 240, width => 320 },
770-encode.pl: best => { abitrate => 128, vbitrate => 400, width => 352, fps => 25 },
770-encode.pl: mplayer => { abitrate => 128, vbitrate => 420, width => 400, height => 240, fps => 30 },

Jaffa 2008-03-25 22:04

Re: Tablet-encode & mencoder
 
Quote:

Originally Posted by bubieyehyeh (Post 160136)
I've been using 770-encode (v1.35) for a while. I noticed the bitrates have increased with tablet-encoder for presets with the same name. Are they now optimized for the 800/810?

They're certainly pushed as high as they can be. v2.18 re-introduces the "mplayer" preset which really pushes the envelope (and has a higher bitrate than most TV episodes you can find on the *cough* Internet).

I'm not particularly keen on having two sets of presets. I may have anything above "average" raise a warning if --770 is set; but v2.18 allows you to define your own presets in ~/.tablet-encode.conf - or even change the ones that are present.

bubieyehyeh 2008-03-25 22:33

Re: Tablet-encode & mencoder
 
Quote:

Originally Posted by Jaffa (Post 160148)
They're certainly pushed as high as they can be. v2.18 re-introduces the "mplayer" preset which really pushes the envelope (and has a higher bitrate than most TV episodes you can find on the *cough* Internet).

I'm not particularly keen on having two sets of presets. I may have anything above "average" raise a warning if --770 is set;

fair enough. The current "good" preset plays on the 770, its just "best" that won't work on nokia player, well prehaps it does using mplayer on 770, I've not checked since the version of mplayer I have on my 770 crashes most of the time.

Quote:

Originally Posted by Jaffa (Post 160148)
but v2.18 allows you to define your own presets in ~/.tablet-encode.conf - or even change the ones that are present.

Wishlist: Does/Will the configuration file offer a way to set the 770 mode permenently? And prehaps a way to set default preset. I can modify the script myself, but I guess other may like the features also.

Thanks for 770-encode/tablet-encode it has been fanastic for long train journeys!

Jaffa 2008-03-26 13:14

Re: Tablet-encode & mencoder
 
Quote:

Originally Posted by bubieyehyeh (Post 160171)
fair enough. The current "good" preset plays on the 770, its just "best" that won't work on nokia player, well prehaps it does using mplayer on 770, I've not checked since the version of mplayer I have on my 770 crashes most of the time.

OK, current Subversion version outputs a warning if the video bitrate is too high and 770-compatibility mode is enabled.

Quote:

Wishlist: Does/Will the configuration file offer a way to set the 770 mode permenently? And prehaps a way to set default preset. I can modify the script myself, but I guess other may like the features also.
Yes to both :-)

Quote:

Thanks for 770-encode/tablet-encode it has been fanastic for long train journeys!
Glad you like it. I'm finding the all-episodes-DVD ripping very handy for a forthcoming 11 hour flight to San Francisco.

Jaffa 2008-03-29 11:19

Re: Tablet-encode & mencoder
 
Quote:

Originally Posted by bubieyehyeh (Post 160171)
Wishlist: Does/Will the configuration file offer a way to set the 770 mode permenently? And prehaps a way to set default preset. I can modify the script myself, but I guess other may like the features also.

tablet-encode v2.18 has been released. More detail at:

http://www.maemopeople.org/index.php...uch_improved_d

To set the default preset and to always enable 770-compatibility mode, create ~/.tablet-encode.conf and put in it:

Code:

$options{770} = 1;
$defaultPreset = 'good';

You can also define your own presets, there's more info in the README.

Let me know if you have any problems.

mve 2008-03-30 13:20

Re: Tablet-encode & mencoder
 
Is it possible to add few more parameters for the tablet-encode? I tried to use "--mencoder=ARGn" but couldn't get it working.

I have some kung-fu DVDs which have English audio set as a default and when I make conversion, tablet-encode selects it. However I would like to have original Chinese audio with English subtitles.

I have also used few other parameters with my own script (based to ones found on maemo.org wiki) which I would like to see also in tablet-encode. One of those is possibility to keep original aspect ratio and still crop black borders away. Videos will be 400 pixels (or whatever is set as resolution) wide and height will be automatically calculated based on aspect ratio. At least mplayer plays these videos correctly and black borders aren't encoded at all.

These are the mencoder parameters I would like to see in tablet-encode:

#Audio language e.g "zh"
-alang <lang code>

#Subtitle language e.g "en"
-slang <lang code>

#Subtitle font and its size
-subfont-text-scale 7 -spuaa 3 -subcp latin1

#Crop value and scaling to correct aspect ratio.
-vf crop <x:x:x:x>,scale=400:-10

I have used "mplayer dvd://$TITLE -vf cropdetect" to get correct crop value. Crop value can be different in the start of the movie so I have selected manually a position which I would like to use as a crop value and then I have then put it as a parameter for "-vf crop".

Here is the script I have used to convert my DVDs. It's bit rough edged but it has been working just fine for me :)
Code:

#!/bin/bash
#
# N800dvd.sh
#
# Usage: N800dvd.sh
#

TITLE=$1

clear
echo
echo '      ##################################################'
echo '      #                                                #'
echo '      #          Encode DVD for Nokia N800            #'
echo '      #                                                #'
echo '      ##################################################'
echo
echo -n "DVD title number to be encoded? [$1]: "
read title_in
if [ "$title_in" != "" ]; then
  TITLE=$title_in
fi

# Default values
ABR='128'
VBR='600'
ALANG='en'
AID='128'
SLANG='fi'
SID='1'
RES='400'
OUT=`echo -n "$TITLE" |sed 's/$/-N800.avi/g'`
VOP='0:0:0:0'

echo -n "Output file? [$OUT]: "
read out_in
if [ "$out_in" != "" ]; then
  OUT=$out_in
fi

echo -n "Resolution (width)? [$RES]: "
read res_in
if [ "$res_in" != "" ]; then
  RES=$res_in
fi

echo -n "Video bitrate? [$VBR]: "
read vbr_in
if [ "$vbr_in" != "" ]; then
  VBR=$vbr_in
fi

echo -n "Audio bitrate? [$ABR]: "
read abr_in
if [ "$abr_in" != "" ]; then
  ABR=$abr_in
fi

echo -n "Audio language code? [$ALANG]: "
read alang_in
if [ "$alang_in" != "" ]; then
  ALANG=$alang_in
fi

echo -n "Subtitle language code? [$SLANG]: "
read slang_in
if [ "$slang_in" != "" ]; then
  SLANG=$slang_in
fi

echo
echo "Crop black bars?"
echo "(y) Yes"
echo "(n) No"
echo -n "Select [n]: "
read crop
if [ "$crop" = "y" ]; then
echo
echo Press q to use that point as a croping value.
mplayer dvd://$TITLE -vf cropdetect -nosound -vo xv &>crop.tmp
sed -e :a -e '$q;N;4,$D;ba' crop.tmp > crop1.tmp
crop_line=$(sed q crop1.tmp)
crop_front=$(echo "$crop_line" | sed -re 's/^.+\=//')
VOP=$(echo "$crop_front" | sed s/..$//)
rm crop*.tmp 2>/dev/null

else
VOP='0:0:0:0'
fi

echo
echo Video crop area: $VOP

echo
echo '      ##################################################'
echo '      #                                                #'
echo '      #            Encoding (pass 1 of 2)              #'
echo '      #                                                #'
echo '      ##################################################'
echo
echo "Start time: $(date)"

rm -f divx2pass_$OUT.log 2>/dev/null

#nice -n 19 \
mencoder "dvd://$TITLE" \
    -o "$OUT" \
    -oac mp3lame -lameopts cbr:preset=$ABR -af volnorm=1 \
    -passlogfile divx2pass_$OUT.log \
    -vf field=0 \
    -ovc lavc -lavcopts vcodec=mpeg4:vbitrate=$VBR:vpass=1:turbo \
    -vf crop=$VOP,scale=$RES:-10 \
    -ffourcc DIVX &>/dev/null \
    -alang $ALANG -slang $SLANG \
    -idx \
    -subfont-text-scale 7 -spuaa 3 -subcp latin1 &>/dev/null


echo "End time: $(date)"

echo
echo '      ##################################################'
echo '      #                                                #'
echo '      #            Encoding (pass 2 of 2)              #'
echo '      #                                                #'
echo '      ##################################################'
echo
echo "Start time: $(date)"

#nice -n 19 \
mencoder "dvd://$TITLE" \
    -o "$OUT" \
    -oac mp3lame -lameopts cbr:preset=$ABR -af volnorm=1 \
    -passlogfile divx2pass_$OUT.log \
    -vf field=0 \
    -ovc lavc -lavcopts vcodec=mpeg4:vbitrate=$VBR:mbd=2:vpass=2 \
    -vf crop=$VOP,scale=$RES:-10 \
    -ffourcc DIVX \
    -alang $ALANG -slang $SLANG \
    -idx \
    -subfont-text-scale 7 -spuaa 3 -subcp latin1 &>/dev/null

rm -f divx2pass_$OUT.log 2>/dev/null

echo "End time: $(date)"
echo
echo '      ##################################################'
echo '      #                                                #'
echo '      #              Encoding completed              #'
echo '      #                                                #'
echo '      ##################################################'
echo


Jaffa 2008-03-30 18:48

Re: Tablet-encode & mencoder
 
mve, thanks for the feedback.

* Auto-cropping using cropdetect is possible, but why've you got videos with encoded black bars in them anyway? ;-) I'll look into it for the next version.

* Original aspect ratio can be maintained with --original-aspect (-o).

* -alang is passed through for auto-detected DVDs, based on $LANG. I'll look at doing it more often.

* --mencoder=ARGn should work, e.g.:

Code:

tablet-encode -o -m-alang -mzh -m-slang -men in.avi out.avi
You can use the new ~/.tablet-encode.conf feature to use these as standard, if desired.

Hope that helps,

Andrew

mve 2008-03-30 19:38

Re: Tablet-encode & mencoder
 
Quote:

Originally Posted by Jaffa (Post 162474)
* Auto-cropping using cropdetect is possible, but why've you got videos with encoded black bars in them anyway? ;-) I'll look into it for the next version.

Yeah, those crappy 1:2.35 DVDs why they just don't make all those in 4:3 full screen ;) Thank you for looking it.

Quote:

* Original aspect ratio can be maintained with --original-aspect (-o).

* -alang is passed through for auto-detected DVDs, based on $LANG. I'll look at doing it more often.

* --mencoder=ARGn should work, e.g.:

Code:

tablet-encode -o -m-alang -mzh -m-slang -men in.avi out.avi

This was a thing I was looking. I had wrong syntax when I tried tablet-encode. Now I can hear original CHAP and CHOP sound effects in my movies with Chinese dialog and English subs :D

Jaffa 2008-03-30 19:41

Re: Tablet-encode & mencoder
 
Quote:

Originally Posted by mve (Post 162499)
Yeah, those crappy 1:2.35 DVDs why they just don't make all those in 4:3 full screen ;) Thank you for looking it.

Ah, 2.35:1 DVDs. Good point :-)

ldrn 2008-05-22 16:04

Re: Tablet-encode & mencoder
 
Tablet-encode is awesome!

I wanted to set it up to automatically encode all the files I download with azureus... not there yet, but I ran into a bug with mencoder and mkvs that I've run into before, where it cuts short mkv files while encoding randomly. My point is, I found where someone wrote up a workaround for it, and the way you can pass any mencoder option to tablet encode via -m let me use it really easily. Thanks a ton for this great program! :)

(The other awesome part about tablet encode to me? I can launch a progress bar for my conversion from the command line, meaning I can automate things with visual feedback. And if I put it inside screen first, I can get remote console feedback on the progress of files, too! :))

Jaffa 2008-05-23 08:50

Re: Tablet-encode & mencoder
 
If the option is something which could always be passed for *.mkv files without any problems, let me know and I'll stick it in by default.

ldrn 2008-05-24 18:47

Re: Tablet-encode & mencoder
 
That'd be great! It could be passed without issue; the way I do it does add a bit of extra time (about 10 seconds on my machine) to the process up front, though. I know there are better ways to do it -- you can extract the audio first -- I just haven't bothered.

The bug can be summed up as: mencoder has trouble with mkvs when it has to also decode the audio for some reason; I know nothing of the technical details. The workaround I use is a bash script; I thought about modifying tablet-encode, but I know almsot no perl.

Problem with how I do it is, what if you are not on a Linux system? I don't know if other systems work the same way or how to adapt it.

Here's what I do, without the stuff specific to me:
Code:

#!/bin/bash
        TEMPFILE=`mktemp`
        rm $TEMPFILE
        mplayer "$1" -ao pcm:fast:file=$TEMPFILE -vc null -vo null
        ~/bin/tablet-encode --preset mplayer -m-audiofile -m$TEMPFILE --gui $1 $2
        rm $TEMPFILE


nyu2 2008-07-15 08:17

Re: Tablet-encode & mencoder
 
Quote:

Originally Posted by Jaffa (Post 162474)
Code:

tablet-encode -o -m-alang -mzh -m-slang -men in.avi out.avi
You can use the new ~/.tablet-encode.conf feature to use these as standard, if desired.

I can't seem to get the syntax of this file down. Could you post an example, converting the code above into the .tablet-encode.conf format as a further example?

-nyu2

Jaffa 2008-07-15 12:21

Re: Tablet-encode & mencoder
 
Quote:

Originally Posted by nyu2 (Post 203106)
I can't seem to get the syntax of this file down. Could you post an example, converting the code above into the .tablet-encode.conf format as a further example?

No problem at all! At the moment, it might require a little too much Perl knowledge, I'm hoping to drum up some extra developers at the Maemo Summit lightning session on tablet-encode.

For the above command line options, put this in ~/.tablet-encode.conf:

Code:

$options{'original-aspect'} = 1;
$options{'mencoder'} = [qw(-alang zh -slang en)];

The next version of the GUI (some thoughts based on suggestions from RST38h here) should provide a mechanism for maintaining the configuration file to make it easier to set your default options. Again, patches and suggestions always welcome :-)

Hope that helps,

Andrew


All times are GMT. The time now is 00:58.

vBulletin® Version 3.8.8