Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
[Solved] iPod Nano 3rd - Converting videos to sync
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Unsupported Software
View previous topic :: View next topic  
Author Message
lyallp
Veteran
Veteran


Joined: 15 Jul 2004
Posts: 1400
Location: Adelaide/Australia

PostPosted: Sun Apr 11, 2010 10:50 am    Post subject: [Solved] iPod Nano 3rd - Converting videos to sync Reply with quote

Hi all.
Previously, I found on this forum, a script which took an AVI and generated an mp4 video file, re-sized and re-coded such that it would play on my iPod Nano 3rd Generation.

For some reason, be it iTunes 9.1 or changes in the linux toolset (the more likely) I am using, iTunes says that these video file cannot play on the iPod Nano.

Files that I re-coded quite some time ago work, but when I use the script now, they won't go.

The script was originally written by sebastian_ml at gmx net

Any suggestions?

Oh, by the way, here is the console output, comparing both a mp4 I converted in the past, which works, and one I am generating now, which does not.
Code:
lyall@lyalls-pc:/tmp
$ mplayer DoesNotSync.iPod.mp4
MPlayer SVN-r29796-4.3.4 (C) 2000-2009 MPlayer Team
Can't open joystick device /dev/input/js0: No such file or directory
Can't init input joystick

Playing DoesNotSync.iPod.mp4.
libavformat file format detected.
[lavf] Audio stream found, -aid 0
[lavf] Video stream found, -vid 1
VIDEO:  [H264]  320x176  24bpp  23.976 fps  256.9 kbps (31.4 kbyte/s)
Clip info:
 major_brand: isom
 minor_version: 1
 compatible_brands: isomavc1
 title: DoesNotSync
==========================================================================
Opening video decoder: [ffmpeg] FFmpeg's libavcodec codec family
Selected video codec: [ffh264] vfm: ffmpeg (FFmpeg H.264)
==========================================================================
==========================================================================
Opening audio decoder: [faad] AAC (MPEG2/4 Advanced Audio Coding)
AUDIO: 48000 Hz, 2 ch, s16le, 136.2 kbit/8.87% (ratio: 17031->192000)
Selected audio codec: [faad] afm: faad (FAAD AAC (MPEG-2/MPEG-4 Audio))
==========================================================================
AO: [oss] 48000Hz 2ch s16le (2 bytes per sample)
Starting playback...
Movie-Aspect is 1.78:1 - prescaling to correct movie aspect.
VO: [xv] 320x176 => 320x180 Planar YV12
A:   1.1 V:   1.1 A-V: -0.002 ct: -0.019   0/  0  1%  3%  0.7% 0 0
Exiting... (Quit)

lyall@lyalls-pc:/tmp
$ mplayer DoesSync.iPod.mp4       
MPlayer SVN-r29796-4.3.4 (C) 2000-2009 MPlayer Team
Can't open joystick device /dev/input/js0: No such file or directory
Can't init input joystick

Playing DoesSync.iPod.mp4.
libavformat file format detected.
[lavf] Audio stream found, -aid 0
[lavf] Video stream found, -vid 1
VIDEO:  [H264]  320x240  24bpp  23.976 fps  350.0 kbps (42.7 kbyte/s)
Clip info:
 major_brand: isom
 minor_version: 1
 compatible_brands: isomavc1
 title: DoesSync
==========================================================================
Opening video decoder: [ffmpeg] FFmpeg's libavcodec codec family
Selected video codec: [ffh264] vfm: ffmpeg (FFmpeg H.264)
==========================================================================
==========================================================================
Opening audio decoder: [faad] AAC (MPEG2/4 Advanced Audio Coding)
AUDIO: 48000 Hz, 2 ch, s16le, 137.0 kbit/8.92% (ratio: 17121->192000)
Selected audio codec: [faad] afm: faad (FAAD AAC (MPEG-2/MPEG-4 Audio))
==========================================================================
AO: [oss] 48000Hz 2ch s16le (2 bytes per sample)
Starting playback...
Movie-Aspect is 1.33:1 - prescaling to correct movie aspect.
VO: [xv] 320x240 => 320x240 Planar YV12
A:   4.2 V:   4.2 A-V:  0.000 ct:  0.021   0/  0  1%  0%  0.7% 0 0
Exiting... (Quit)

_________________
...Lyall
Back to top
View user's profile Send private message
lyallp
Veteran
Veteran


Joined: 15 Jul 2004
Posts: 1400
Location: Adelaide/Australia

PostPosted: Tue Apr 13, 2010 12:29 pm    Post subject: Reply with quote

I emailed the original author, he was most helpful.

You can obtain the latest and greatest version of this batch conversion script at http://forum.doom9.org/showthread.php?t=133598

Read the thread to find out what software is required - you will need to install some programs to get it to work. Additionally, I tweaked the default config to not use nero and to disable subtitles (USE_NERO_AAC="no" and SBTL="" in the config file).

It will transcode entire directories of files, that will play on your iPod (and it works on my iPod Nano 3rd Generation) and your PSP.

The only change I made to the script was to make the failure of 'aacgain' a warning, rather than aborting the entire transcode effort.

Code:
 echo -e "\033[1mApplying ReplayGain:\033[0m\n"
  aacgain -r -k "$TMP_DIR/${RND_ASCII}_aac.m4a"
  ERROR=${?}
  echo
  e "$CMD_ABORT" $E_CMD

to
Code:
 echo -e "\033[1mApplying ReplayGain:\033[0m\n"
  aacgain -r -k "$TMP_DIR/${RND_ASCII}_aac.m4a"
  ERROR=${?}
  echo
  warn "$CMD_ABORT" $E_CMD

_________________
...Lyall
Back to top
View user's profile Send private message
snake111
Tux's lil' helper
Tux's lil' helper


Joined: 18 Dec 2004
Posts: 113

PostPosted: Fri Jun 04, 2010 10:55 pm    Post subject: Reply with quote

Thanks for the hint, very usefull! :)

Do you know how can I change the output resolution? By default it's about 320x160, I'd like to have 480px as horizontal res.
Back to top
View user's profile Send private message
lyallp
Veteran
Veteran


Joined: 15 Jul 2004
Posts: 1400
Location: Adelaide/Australia

PostPosted: Sat Jun 05, 2010 3:34 am    Post subject: Reply with quote

Edit ~/.avi2mp4.conf

Look for MAX_RES
_________________
...Lyall
Back to top
View user's profile Send private message
snake111
Tux's lil' helper
Tux's lil' helper


Joined: 18 Dec 2004
Posts: 113

PostPosted: Fri Jun 11, 2010 8:52 pm    Post subject: Reply with quote

Thanks, works! I was changing only the script MAX_RES parameter...
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Unsupported Software All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum