views:

97

answers:

2

I'd like to be able to grab the metadata of the currently playing file in Quicktime X using ScriptingBridge and Ruby, so far I have the following code

require 'osx/cocoa'
OSX.require_framework 'ScriptingBridge'

@app = OSX::SBApplication.applicationWithBundleIdentifier("com.apple.QuickTimePlayerX")

@app.documents.each do |movie|
  # What now?!
end

But I can't find any functions in QuickTime X's applescript dictionary to get the metadata from a document object (the same data you can see in QT's 'Show Movie Inspector' HUD) — does anyone have any ideas?

A: 

Here is an example of metadata manipulation. Is that what you want? http://oreilly.com/pub/a/mac/2005/06/28/quicktime.html

FractalizeR
That article was posted in 2005, well before the release of QuickTime X, so I'm sorry - it's not very useful!
JP
A: 

A quick inspection of objects can be done with the Looksee gem - tells you what methods are available on a ruby-object. I don't know if it will work properly with ScriptingBridge, but it's quick to try.

laust.rud
Unfortunately Scripting Bridge appears to work by passing the commands directly to the OS X cocoa framework via `method_missing` so looksee, pretty though it is, doesn't help out so much! Sorry!
JP