[vdr] vdr-pictures and pic2mpg
Stefan Wagner
stefanwag at gmx.at
Mon Feb 25 06:48:25 CET 2008
Klaus Schmidinger <Klaus.Schmidinger at cadsoft.de> wrote:
> On 02/24/08 21:42, Stefan Wagner wrote:
>> the pic2mpg script aceptis only files with lower case caracters.
>> is it posible to support upper case caracters by default?
>>
>> my pictures are named DSCN*.JPG and the script only acepts DSCN*.jpg.
>
> --- PLUGINS/src/pictures/pic2mpg 2008/02/02 11:34:43 1.2
> +++ PLUGINS/src/pictures/pic2mpg 2008/02/24 22:00:18
> @@ -143,7 +143,7 @@
> sub ConvertFile
> {
> my ($Pict, $Mpeg) = @_;
> - (my $Type) = $Pict =~ /\.([^\.]*)$/;
> + (my $Type) = lc($Pict) =~ /\.([^\.]*)$/;
> if (!defined $PNMCONV{$Type}) {
> return if ($Ignore);
> die "unknown file type '$Type': '$Pict'\n";
>
>
> (untested).
>
> Klaus
works fine now with uper and lower case.
stefan at mona:/media/daten/burn$ pic2mpg -v 1 /media/daten/burn/ /media/daten/burn/dest/
./dscn0015.jpg -> /media/daten/burn/dest//./dscn0015.jpg.mpg
./DSCN00051.JPG -> /media/daten/burn/dest//./DSCN00051.JPG.mpg
but wen i call the script with relative paths:
stefan at mona:/media/daten/burn$ pic2mpg -v 1 ./ dest/
./dscn0015.jpg -> dest//./dscn0015.jpg.mpg
./DSCN00051.JPG -> dest//./DSCN00051.JPG.mpg
removing ./DSCN00051.JPG.mpg
removing ./dscn0015.jpg.mpg
dest/: No such file or directory
why will the script remove the files?
they are in dest/ before ending script.
stefan
More information about the vdr
mailing list