Media Library

From AwkwardTV
Revision as of 14:24, 6 September 2007 by Uw1Nci (talk | contribs)
Jump to: navigation, search

socket 840 hunedoara (provincia) diesel 75ml buco culo neuroactive steroid sare nere tiziano ferro smerigliatrice angolare conto corrente banca mediolanum graduatoria integrazione affitto anno 20 compact flash reader puma repli cat mid iii amd athlon 64 3200 venice socket 939 funkit lingeri sexi gli amici della notte castellina technics cuffie dj modelli con motore a scoppio lisa marie scott integrazione culturale fax multifunzione telefono router dlink dsl504t favero gioiello mario party 4 kaaza lite campion league corso roma mexican hat dance camping latsch com lv grand televiewer pro dvi rotel rc 1070 opel meriva 1 7 16v cdti aircard sierra passion flowers climatizzatori dual distributori gas metano provincia modena benfica red star fernandalessa respirare in alto mare batteria panasonic g60 kx fa 83 panasonic constantine pc guasti audi a2 recupero materiali balbi giornale di vicenza problemi tetta famosa chat veneto hendrix cancellato il progetto wish brizard www simonerossi com phoenix cose fare talkabout t5422 toboy horosho hard disk usb mini alluminio blackgirls kitana jade moda uomo tg it ci (lettera) packard bell easynote b cd navitech auto opel frontera zucchero everybody s got to learn sometime quitte vale di piu www imetec kabas canned heat dogale mara vernier guci forema melissa panarello gang bang per coppie di notte a parigi purextc netgear pern nintendo al tiro da tre olympus c 730 air hocke montblanc noblesse oblige casse ps2 hey mama black eyed peace camicie ralph lauren uomo absolon virus mortale cos im cool holly vallance sheela simonetti hong hanh occhiali ferragamo nemici naturali cullmann treppiede flagstaff hotel marano sul panaro toshiba 1370 toner la carica dei 101 ii custodia olympus mju mini u2 go home serenisima janet gaynor patente a1 sony dsc v3 unisob stati di devozione testi francesco renga pascal blaise canzone nightswimming liebherr frigorifero combinato dvd dvr hard disk videocamera jvc 3 ccd camera matera centro assistenza akai roma crociera di piacere miamisan jose carta si visa mi fai un favore epidemiologia cd corso multimediale patente di guida lancio del pinguino 1 rsmmc kingmax conduttrici io e lui lady punk stacja oklahoma city shopping sony pocket vaio scart multi nico berg camedia c 7070 olympus un motore grafico da 300000 dollari alla ricerca della pietra di cristallo crystalstone cinema hard sms internet gratis mammelle il delitto della villa saldatura metalli pavia proiettore panasonic la morte si fa bella mandy moore jonathan foreman someday torce elettriche bilancia pesalettere regalo natale 2004 decalcomanie per ceramica x 21 forno a microonde a incasso sigmatau eros michelle skoda octavia 4x4 codice sbocco nokia 3510i santo daniele ricci monitor lcd speaker keepsake lettori mp3 con pendrive dragostea midi agenzia immobiliare napoli global line telecomunicazioni lcd tv hyundai sata hdd 2 5 motos yamaha rd stradario di catania extranged scarpa pirelli provini per bimbi ramona chorleu ultimo testo di elisa mensajes de pcs digital hp plotter italia evanscence www frutta frozenbubble excel recovery tera patricks dolores (argentina) servi futbol juegos www cinema castlerock it amplificatori per karaoke albergo economici firenze colin farrell veline senza velo mini cooper bologna francis cabrel annuncio casa nuoro milano marittima hotel www thecalling it nikotini georgos casio qv r52 technisub stratos erika maldini playas nudistas video mature gratis digging your scene abbigliamento notte batteria finepix un giorno di sole per te sei diventata nera dhl libro di magia toschi paxil qwest ringtones zanaflex online rivotril online hgh online cheap ultracet norco online prozac online free cingular ringtones cheap ambien samsung ringtones cheap diazepam cheap didrex levitra online ultram cheap ativan sildenafil online adipex free sprint ringtones motorola ringtones wellbutrin cheap xanax free cool ringtones free midi ringtones celexa cheap carisoprodol fioricet propecia free wwe ringtones cheap cyclobenzaprine ortho online valium cheap hoodia cheap hydrocodone free ericsson ringtones cheap xenical free alltel ringtones tramadol nexium online cheap cialis vicodin music ringtones mp3 ringtones zoloft free funny ringtones free punk ringtones vigrx online sony ringtones nokia ringtones cheap tenuate free mtv ringtones mono ringtones cheap pharmacy online sharp ringtones lortab free kyocera ringtones cheap lisinopril flexeril online cheap lorazepam cheap diethylpropion free tracfone ringtones phentermine online meridia online viagra online cheap clonazepam cheap soma free sony ericsson ringtones cheap clomid free nextel ringtones free free ringtones free sonyericsson ringtones alprazolam online zyban online verizon ringtones free sagem ringtones free real ringtones free polyphonic ringtones albuterol lipitor free jazz ringtones The Media Library file (in /mnt/Media/Media Library) is similar to iTunesDB on the iPod. The path to the actual media files are relative to /mnt/Media/Media Files/

I've updated the patch below to allow AVI files as well as to create files in the layout for Apple TV instead of iPod. The patch is available at http://ericiii.pastey.net/9471 (now includes avi metadata support, requires mplayer, and adds the ability to create hardlinks instead of copying files).

Follow the instructions below for "After gnupod is built" to add files, but you can just copy the contents of the iPod_Control directory (created in the IPOD_MOUNTPOINT directory) to /mnt/Media on the Apple TV. Restarting Finder (Front Row) on the Apple TV is still necessary.

Original patches

Patch for gnupod (http://www.gnu.org/software/gnupod/) to output the correct path as well as a stub for handling .mov (for reference files) (also note that this makes it not work for real ipods):

--- gnupod-orig/src/ext/FileMagic.pm    2006-09-27 02:52:23.000000000 -0700
    gnupod-0.99.1/src/ext/FileMagic.pm  2007-03-24 16:48:43.000000000 -0700
@@ -73,6  73,20 @@
   elsif(!-r $file) {
    warn "FileMagic.pm: Can't read '$file'\n";
   }
   elsif($file =~ /mov$/){
   my %rh = ();
 # just some bogus data
   $rh{bitrate}  = 20;
   $rh{filesize} = (-s $file);
   $rh{srate}    = 5;
   $rh{time}     = 20;
   $rh{fdesc}    = "Quicktime Video File";
   $rh{title}    = "Unknown vdeo Title";
   $rh{album} =   "Unknown Album";
   $rh{artist} =    "Unknown Artist";
   $rh{mediatype}  = MEDIATYPE_VIDEO;
        return (\%rh, {ftyp=>"MOV", format=>"mov"});
   }
   elsif(my $nnat  = __is_NonNative($file,$flags,$con)) { #Handle non-native formats
    return($nnat->{ref}, {ftyp=>$nnat->{codec}}, $nnat->{encoder});
   }
diff -ur gnupod-orig/src/ext/XMLhelper.pm gnupod-0.99.1/src/ext/XMLhelper.pm
--- gnupod-orig/src/ext/XMLhelper.pm    2006-02-03 12:47:24.000000000 -0800
    gnupod-0.99.1/src/ext/XMLhelper.pm  2007-03-24 16:48:53.000000000 -0700
@@ -121,6  121,8 @@
 
 #Convert /'s to :'s
 $ipath =~ tr/\//:/;
 # for appletv
 $ipath=~s/:iPod_Control:Music//;
 return ($ipath, $path);
 }

These patches will let you set more things on the command-line with "--set-title=", "--set-tvshow" and "--set-tvepisode":

--- gnupod-orig/src/gnupod_addsong.pl   2006-03-22 12:05:24.000000000 -0700
    gnupod-0.99.1/src/gnupod_addsong.pl 2007-03-25 04:29:47.000000000 -0700
@@ -41,7  41,7 @@
 $opts{mount} = $ENV{IPOD_MOUNTPOINT};
 #Don't add xml and itunes opts.. we *NEED* the mount opt to be set..
 GetOptions(\%opts, "version", "help|h", "mount|m=s", "decode=s", "restore|r", "duplicate|d", "disable-v2", "disable-v1",
-                   "set-artist=s", "set-album=s", "set-genre=s", "set-rating=i", "set-playcount=i",
                    "set-artist=s", "set-album=s", "set-genre=s", "set-rating=i", "set-playcount=i", "set-title=s", "set-tvshow=s", "set-tvepisode=s",
                    "set-songnum", "playlist|p=s", "reencode|e=i");
 GNUpod::FooBar::GetConfig(\%opts, {'decode'=>'s', mount=>'s', duplicate=>'b',
                                    'disable-v1'=>'b', 'disable-v2'=>'b', 'set-songnum'=>'b'},
@@ -138,6  138,11 @@
                $fh->{genre}       = $opts{'set-genre'}       if $opts{'set-genre'};
                $fh->{rating}      = $opts{'set-rating'}      if $opts{'set-rating'};
                $fh->{playcount}   = $opts{'set-playcount'}   if $opts{'set-playcount'};
                $fh->{title}       = $opts{'set-title'}       if $opts{'set-title'};
                $fh->{tvshow}      = $opts{'set-tvshow'}      if $opts{'set-tvshow'};
                $fh->{artist}      = $opts{'set-tvshow'}      if $opts{'set-tvshow'};
                $fh->{mediatype}   = 0x40                     if $opts{'set-tvshow'};
                $fh->{tvepisode}   = $opts{'set-tvepisode'}   if $opts{'set-tvepisode'};
                $fh->{songnum}     = 1 $addcount              if $opts{'set-songnum'};
 
                #Set the addtime to unixtime(now) MACTIME (the iPod uses mactime)
--- gnupod-orig/src/ext/FileMagic.pm    2006-09-27 02:52:23.000000000 -0700
    gnupod-0.99.1/src/ext/FileMagic.pm  2007-03-25 03:46:25.000000000 -0700
@@ -29,6  29,7 @@
 
 use constant MEDIATYPE_AUDIO => 0x01;
 use constant MEDIATYPE_VIDEO => 0x02;
 use constant MEDIATYPE_TVSHOW => 0x40;
 
 #
 # How to add a converter:

With the above, if you set "--set-tvshow", the movie file will appear under TV Shows in the sub-folder that you set it to. You can then use "--set-title" to set the episode name. FYI: even though I put --set-tvepisode in there, it may produce odd results!

After gnupod is built:

  • mkdir MediaNew
  • export IPOD_MOUNTPOINT=`pwd`/MediaNew
  • gnupod_INIT.pl
  • gnupod_addsong.pl <whatever>
  • mktunes.pl

Copy these files to the appletv:

  • iPod_Control/Music/* -> /mnt/Media/Media Files/*
  • iPod_Control/iTunes/iTunesDB -> /mnt/Media/Media Library

You'll need to restart Finder/Front Row on the appletv to get it to reread the db


Todo

  • Set the proper bitrate, time, etc. for mov/avi