DVBTechnics Forum  

Zurück   DVBTechnics Forum > Software-Support > Project X
Registrieren Hilfe Benutzerliste Kalender Suchen Heutige Beiträge Alle Foren als gelesen markieren

Antwort
 
Themen-Optionen Thema durchsuchen Ansicht
  #1  
Alt 17.04.2009, 14:26
Skeeve Skeeve ist offline
Junior Mitglied
 
Registriert seit: 23.08.2007
Beiträge: 39
Standard Nachbearbeitung unter OS X (Abschlussbefehl)

Ich hatte Schwierigkeiten, einen vernünftigen Abschlussbefehl zu erstellen.

/pfad/zu/meinem/shellscript "?0"

Liefert Fehler. Wenn die Datei z.B. /Users/skeeve/Wickie und die starken Männer 1.ts ist, kommt als erster Parameter beim Shellscript an:
"/Users/skeeve/Wickie

Das Problem ist meiner Meinung nach diese Zeile im Source:

Code:
Process subprocess = Runtime.getRuntime().exec(commandline); // anyone has told that works better
Die auskommentierte Folgezeile ist besser:
Code:
Process subprocess = Runtime.getRuntime().exec(arguments);
Zumindest läuft mein Shellscript jetzt und der Übergabeparameter muß auch nicht gequotet werden.

/pfad/zu/meinem/shellscript ?0


steht da also jetzt, und das Shellscript hat den Inhalt:

Code:
#!/bin/sh
infile=$1
outfile=$1.mp4
/Applications/iSquint.app/Contents/Resources/ffmpeg \
 -y              \
 -threads 4      \
 -i "$infile"    \
 -s 400x300      \
 -r 25.00        \
 -vcodec mpeg4   \
 -g 300          \
 -aspect 400:300 \
 -b 2300         \
 -async 50       \
 -acodec aac     \
 -ar 44100       \
 -ac 2           \
 -ab 128         \
 "$outfile"
Mit Zitat antworten
  #2  
Alt 17.04.2009, 18:38
Skeeve Skeeve ist offline
Junior Mitglied
 
Registriert seit: 23.08.2007
Beiträge: 39
Standard

Und hier jetzt nochmal der vollständige Abschlußbefehl, den ich in OS X nutze, um nach dem Schneiden und Konvertieren mein Aufnahmen vom M750S direkt eine iPod kompatible Version zu erstellen.

Hier die Variante für 4:3 Aufnahmen:
Code:
#!/bin/sh
osascript -e '
	property resH      : "400"
	property resV      : "300"
	property framerate : "25.00"
	property aspect    : "4:3"
	property bgcol     : {16705, 26985, 43690} -- kind of blue
	property fgcol     : {65535, 65535, 39321} -- kind of yellow
	property bdcol     : {65535, 65535, 65535} -- white
	on run (arg)
		set arg to quoted form of (arg as text)
		set columns to 26 + length of arg
		if columns > 200 then set columns to 200
		tell application "Terminal"
			set theTab to do script "/Applications/iSquint.app/Contents/Resources/ffmpeg -y -threads 4 -i " & arg & " -s " & resH & "x" & resV & " -r " & framerate & " -vcodec mpeg4 -g 300 -aspect " & aspect & " -b 2300 -async 50 -acodec aac -ar 44100 -ac 2 -ab 128 " & arg & ".mp4 ; exit"
			tell theTab to tell current settings
				if number of columns < columns then set number of columns to columns
				set background color to bgcol
				set cursor color to fgcol
				set normal text color to fgcol
				set bold text color to bdcol
			end tell
		end tell
	end run
' "$1"
Als Abschlußbefehl habe ich unter "TS" eingetragen:
Code:
/Users/skeeve/bin/convert2iPod_4x3.sh ?0
d.h. also, obiges Script muß als ausführbare Datei "convert2iPod_4x3.sh in meinem ~/bin Verzeichnis liegen.

Nach dem Konvertieren öffnet sich nun ein Terminal Fenster mit eigenen Farben (Siehe Properties im Script) in dem mit ffmpeg (aus iSquint) die Konvertierung erfolgt.
Mit Zitat antworten
Antwort


Themen-Optionen Thema durchsuchen
Thema durchsuchen:

Erweiterte Suche
Ansicht

Forumregeln
Es ist Ihnen nicht erlaubt, neue Themen zu verfassen.
Es ist Ihnen nicht erlaubt, auf Beiträge zu antworten.
Es ist Ihnen nicht erlaubt, Anhänge anzufügen.
Es ist Ihnen nicht erlaubt, Ihre Beiträge zu bearbeiten.

vB Code ist An.
Smileys sind An.
[IMG] Code ist An.
HTML-Code ist Aus.
Gehe zu


Alle Zeitangaben in WEZ +2. Es ist jetzt 02:54 Uhr.


Powered by vBulletin® Version 3.6.7 (Deutsch)
Copyright ©2000 - 2010, Jelsoft Enterprises Ltd.