From cf8882380fd9adf256d12b74fc48a9d2676b16e4 Mon Sep 17 00:00:00 2001 From: kueller Date: Mon, 3 Jan 2011 10:48:06 +0000 Subject: [PATCH] Neue Version V963 git-svn-id: svn://svn.compuextreme.de/Viitor/V963/Viitor_video2mp3@5933 504e572c-2e33-0410-9681-be2bf7408885 --- usr/bin/video2mp3 | 29 ++++++++++++++++++++++++ usr/share/applications/video2mp3.desktop | 13 +++++++++++ 2 files changed, 42 insertions(+) create mode 100755 usr/bin/video2mp3 create mode 100644 usr/share/applications/video2mp3.desktop diff --git a/usr/bin/video2mp3 b/usr/bin/video2mp3 new file mode 100755 index 0000000..f9dd0a1 --- /dev/null +++ b/usr/bin/video2mp3 @@ -0,0 +1,29 @@ +#!/bin/bash + +export G_BROKEN_FILENAMES=true +VIDEO=$1 +while true; do + if [ ! "$VIDEO" ]; then + VIDEO=`Xdialog --stdout --title "Please Select Video File to convert" --fselect . 60 250 ` + if [ ! "$VIDEO" ]; then + echo "USAGE: $0 " + exit 10 + fi + fi + if [ -f "$VIDEO" ]; then + WAVFILE=`echo $VIDEO|sed -e "s/\....$/\.wav/"` + MP3FILE=`echo $VIDEO|sed -e "s/\....$/\.mp3/"` + DIRNAME=`dirname "$VIDEO"` + if [ "$DIRNAME" ]; then + cd "$DIRNAME" + fi + ffmpeg -i "${VIDEO}" "${WAVFILE}" + #mplayer -ao pcm:file="${WAVFILE}" -vc null -vo null -hardframedrop -cache 16384 -srate 44100 "${VIDEO}" + lame --preset 160 "${WAVFILE}" "${MP3FILE}" + rm "${WAVFILE}" + normalize "${MP3FILE}" + VIDEO="" + else + exit 10 + fi +done diff --git a/usr/share/applications/video2mp3.desktop b/usr/share/applications/video2mp3.desktop new file mode 100644 index 0000000..29cd1d2 --- /dev/null +++ b/usr/share/applications/video2mp3.desktop @@ -0,0 +1,13 @@ +#!/usr/bin/env xdg-open +[Desktop Entry] +Name=Video2mp3 +Name[en_US]=Video2mp3 +Name[de]=Video2mp3 +Comment=Convert Videodata to MP3 Music +Comment[de]=Extrahiere Audio Daten aus Video Streams und speichere diese als MP3 +Exec=/usr/bin/video2mp3 +Type=Application +StartupNotify=true +Categories=Applications;Qt;AudioVideo;Video; +Path=$HOME +Icon=/usr/lib/jdk/lib/deploy/java-icon.ico