Videos von der Samsung WB500 Mac-Kompatibel machen

ladoma

ladoma

Neues Mitglied
Thread Starter
Dabei seit
16.11.2006
Beiträge
14
Reaktionspunkte
5
Hallo,

bei der WB500 werden mp4 avc clips erstellt. Beim import in iMovie gibt es einen Fehler. Um diesen zu vermeiden lösche ich 2-3 Sekunden am Anfang des Clips per Quicktime und exportiere dann per "Durrchreichen" wieder.

Das ganze habe ich mir als AppleScript zusammengebaut und wollte das gerne mit anderen teilen.

Kurz und knapp, hier der Code:
Code:
with timeout of 86400 seconds
	
	display dialog "Before beginning batch processing, make sure QuickTime Player is set to the desired export settings, and all videos to be processed are in a folder named ‘Input’ on the desktop." with icon note
	
	tell application "Finder"
		set the startup_disk to the name of the startup disk
	end tell
	
	set user to do shell script "whoami"
	set input_folder_name to "Input"
	set input_folder to startup_disk & ":Users:" & user & ":Desktop:" & input_folder_name & ":"
	set user_desktop to startup_disk & ":Users:" & user & ":Desktop:"
	set output_folder to startup_disk & ":Users:" & user & ":Desktop:Output:"
	set file_extension to "_export.mp4"
	
	try
		tell application "Finder"
			make new folder at user_desktop with properties {name:"Output"}
		end tell
	end try
	
	try
		set the_folder_list to list folder input_folder without invisibles
		repeat with x from 1 to count of the_folder_list
			set the_file to input_folder & item x of the_folder_list
			set output_file to output_folder & item x of the_folder_list & file_extension
			tell application "QuickTime Player"
				activate
				open the_file
				tell application "QuickTime Player"
					activate
					set documentList to id of every document -- jedes offene Filmdokument wird in eine Liste gelegt
					repeat with i in documentList
						tell document 1
							
							set laenge to get duration -- Filmlänge in 600stel Sekunden
							select at (600 * 3) to (laenge - 600 * 0) -- schneidet vorn und hinten 5sec ab
							trim --schnipp
							
						end tell
						-- sichern/exportieren überlasse ich dir		
					end repeat
				end tell
				export front document to output_file as MPEG4 using most recent settings with replacing
				close front document
			end tell
		end repeat
	on error
		display dialog "This script requires a folder named ‘" & input_folder_name & "‘ located on the desktop." with icon stop
	end try
	
	beep
	
end timeout

Gruß, Ladoma
 
  • Gefällt mir
Reaktionen: Wildwater
Hallo,

seit heute habe ich auch die WB500. Hab sie mir nur wegen der Videofunktion gekauft, um hier und da mal ein paar Clips/ kleine Filme erstellen zu können.

Leider habe ich mit imovie auch das von dir beschriebene Problem. iMovie 08 wie auch 09 sollen ja wirklich nicht sehr kompatibel mit den verschieden Formaten sein. Für mich bewahrheitet sich das gerade.


Braucht man dazu nicht Quicktime Pro?
Kannst du mir vielleicht noch sagen wie man diese Apple Skripte einsetzt? Ich habe davon leider keine Ahnung.
Liegt das wirklich nur an den ersten 2-3sek der Aufnahme? Ich dachte die WB500 nimmt nicht mp4 konformer Weise (oder wie auch immer) auf?

Über weiteren Austausch würde ich mich freuen.

Hier die superbe Anleitung als Schritt für Schritt Video von Ladoma: http://www.youtube.com/watch?v=3dOYpoj5vug

leider wirklich Quicktime Pro notwendig und das bin ich nicht bereit zu zahlen.
 
Zuletzt bearbeitet:
Hallo,

ich habe den Code verbessert. Nun wird das Änderungsdatum nicht geändert, sodass die "beschnittene" Version den Original Zeitstempel erhält.

@Coup: Ja, man braucht Quicktime 7 Pro. ich hab mir aber tatsächlich auch ein bißchen über die Zukunft gedanken gemacht und einen fast fertigen Code für QT X geschrieben. Den poste ich auch gleich mal.

Code:
with timeout of 86400 seconds
	
	display dialog "Before beginning batch processing, make sure QuickTime Player is set to the desired export settings, and all videos to be processed are in a folder named ‘Input’ on the desktop." with icon note
	
	tell application "Finder"
		set the startup_disk to the name of the startup disk
	end tell
	
	set user to do shell script "whoami"
	set input_folder_name to "Input"
	set input_folder to startup_disk & ":Users:" & user & ":Desktop:" & input_folder_name & ":"
	set user_desktop to startup_disk & ":Users:" & user & ":Desktop:"
	set output_folder to startup_disk & ":Users:" & user & ":Desktop:Output:"
	set file_extension to "_export.mp4"
	
	
	try
		tell application "Finder"
			make new folder at user_desktop with properties {name:"Output"}
		end tell
	end try
	
	try
		set the_folder_list to list folder input_folder without invisibles
		repeat with x from 1 to count of the_folder_list
			set the_file to input_folder & item x of the_folder_list
			set output_file to output_folder & item x of the_folder_list & file_extension
			set dateiname to item x of the_folder_list
			--hier gehts los
			tell application "Finder"
				activate
				
				set modDate to modification date of document file dateiname of folder "Input" of folder "Desktop" of folder "michael" of folder "Users" of startup disk
				
				
			end tell
			
			
			
			--hier endet meine modification
			tell application "QuickTime Player"
				activate
				open the_file
				tell application "QuickTime Player"
					activate
					set documentList to id of every document -- jedes offene Filmdokument wird in eine Liste gelegt
					
					repeat with i in documentList
						tell document 1
							
							
							set laenge to get duration -- Filmlänge in 600stel Sekunden
							«event MVWRslct» given «class stqt»:(600 * 3), «class enqt»:(laenge - 600 * 0) -- schneidet vorn und hinten 5sec ab
							«event MVWRptri» --schnipp
							
						end tell
						-- sichern/exportieren überlasse ich dir		
					end repeat
				end tell
				export front document with «class repl» given «class expd»:output_file, «class expk»:«constant expkmpg4», «class exps»:«constant expsexpr»
				--set modDate to modification date of document 1 of selectedItem
				close front document
				
			end tell
			
			--hier gehts los
			
			tell application "Finder"
				activate
				
				set dateiname2 to dateiname & "_export.mp4"
				set modification date of document file dateiname2 of folder "Output" of folder "Desktop" of folder "michael" of folder "Users" of startup disk to modDate
				
				
			end tell
			
			--hier endet es	
			
			
			
		end repeat
		
		tell application "QuickTime Player"
			quit
		end tell
	on error
		display dialog "This script requires a folder named ‘" & input_folder_name & "‘ located on the desktop." with icon stop
	end try
	
	
	
	
	beep
	
end timeout
 
So hier ist der Code für Quicktime X. Dieser hat den Nachteil, dass man nach jedem Schnitt auf Enter drücken muss, also nicht vollautomatisch. Außerdem wird der Datei die Endung *.mov hinten angehängt. Ich denke man kann diese einfach wieder tauschen?!?! keine Ahnung!
Es geht auch sehr schnell und das Originaldatum bleibt auch erhalten.

Wenn jemand Verbesserungen vornehmen möchte, nur zu :D

Code:
with timeout of 86400 seconds
	
	display dialog "Before beginning batch processing, make sure QuickTime Player is set to the desired export settings, and all videos to be processed are in a folder named ‘Input’ on the desktop." with icon note
	
	tell application "Finder"
		set the startup_disk to the name of the startup disk
	end tell
	
	set amount_to_trim to 1
	set user to do shell script "whoami"
	set input_folder_name to "Input"
	set input_folder to startup_disk & ":Users:" & user & ":Desktop:" & input_folder_name & ":"
	set user_desktop to startup_disk & ":Users:" & user & ":Desktop:"
	set output_folder to startup_disk & ":Users:" & user & ":Desktop:Output:"
	set file_extension to "_export.mp4"
	
	try
		tell application "Finder"
			make new folder at user_desktop with properties {name:"Output"}
		end tell
	end try
	
	try
		set the_folder_list to list folder input_folder without invisibles
		repeat with x from 1 to count of the_folder_list
			set the_file to input_folder & item x of the_folder_list
			set output_file to output_folder & item x of the_folder_list & file_extension
			set dateiname to item x of the_folder_list
			tell application "Finder"
				activate
				
				set modDate to modification date of document file dateiname of folder "Input" of folder "Desktop" of folder "michael" of folder "Users" of startup disk
				
				
			end tell
			tell application "QuickTime Player"
				activate
				try
					close front window
				end try
				open the_file
				trim document 1 from 1 to (duration of document 1)
				--export front document to output_file as MPEG4 using most recent settings with replacing
				save front document
				close front document
			end tell
			tell application "Finder"
				activate
				
				-- Anzahl Zeichen am Ende entfernen
				
				set alleZeichen to every character of dateiname
				set anzahlZeichen to (count of alleZeichen) - 4
				set aktuellesZeichen to 0
				set fertigerString to ""
				
				repeat while aktuellesZeichen is not anzahlZeichen
					set aktuellesZeichen to aktuellesZeichen + 1
					set fertigerString to fertigerString & (item aktuellesZeichen of alleZeichen)
				end repeat
				
				set dateiname to fertigerString
				
				
				set dateiname2 to dateiname & ".mov"
				set modification date of document file dateiname2 of folder "Input" of folder "Desktop" of folder "michael" of folder "Users" of startup disk to modDate
				
				
			end tell
		end repeat
	on error
		display dialog "This script requires a folder named ‘" & input_folder_name & "‘ located on the desktop." with icon stop
	end try
	
	beep
	
end timeout
 
vielen Dank für deine Mühe, hatte seinerzeit dann auch geklappt, aber ich habe die Cam auch bald wieder verkauft.

720P Videos in weitaus besser Qualität hat die T500 von Sony gemacht. Die sind selbst auch einem 92" Bild projiziert von einem Full HD-Projekotr noch gestochen scharf!
 
  • Gefällt mir
Reaktionen: ladoma
Zurück
Oben Unten