#!/usr/bin/perl -w
+use strict;
# launch a gst-launch pipeline for the supplied media file
# use the extension to determine the gst-launch pipeline
# .tar.gz extensions do we ?
if ($path =~ /\./)
{
- my $ext = $path;
+ $ext = $path;
$ext =~ s/^.*\.//;
}
else { $ext = ""; }
"ac3", "a52dec ! $cfg{AUDIOSINK}",
"au", "auparse ! $cfg{AUDIOSINK}",
"avi", "avidemux video_%02d! { queue ! windec ! $cfg{VIDEOSINK} } avidemux0.audio_%02d! { queue ! mad ! $cfg{AUDIOSINK} }",
+ "flac", "flacdec ! $cfg{AUDIOSINK}",
"fli", "flxdec ! colorspace ! $cfg{VIDEOSINK}",
"m1v", "mpegdemux video_%02d! { queue ! mpeg2dec ! $cfg{VIDEOSINK} }",
"m2v", "mpegdemux video_%02d! { queue ! mpeg2dec ! $cfg{VIDEOSINK} }",
my $file;
while ($file = shift @ARGV) {
my $ext = extension ($file);
+ if (!$ext) {
+ print "file $file doesn't have an extension !\n";
+ return -1;
+ }
if ($ext eq 'm3u')
{
open (PLAYLIST, '<', $file);