I do wonder at Apple sometimes. With Mac OS X, they give you Xcode, their superb development environment. On the other hand with it, they supply hugely underpowered applications like Property List Editor. Very odd!

Anyway, one thing that Property List Editor does have going for it is the ability to edit binary plists without having to convert them to ASCII XML:- very useful. However without, for instance, search and replace it is (for me) almost useless!

To the rescue is PlistEdit Pro; all the same stuff as the Apple app, but with loads more to boot. If you need to work with plists a lot then $25 doesn't seem like big money.

And with regard to editing Quartz Composer files, I can confirm that I can edit the files, search and replace, save them and they work as they should. If I wasn‘t thinking more down the automated shell script route (perhaps with some nifty applescript), I’d probably be shelling out for PlistEdit Pro!

SteamSHIFT Out

OK not so much a discovery, more of a confirmation; I tried using plutil command line utility to change qtz binary plist files into standard xml files, and then editing them in SubEthaEdit (BTW I had to use SEE because with the qtz extension TextWrangler opened them as Movies). I then turned them back into binary plist qtz files and opened them in Quartz Composer - SUCCESS!

On a related note, I also tried opening the ASCII XML file - it opened in Quartz Composer without any complaint (TextWrangler's behaviour gave it away that this might happen.)

So what does this mean? (warning some of this is completely off the top of my head brainstorming and could well mean it's rambling rubbish!)

  • Well, first it means that if I need to change the location of any of the hard coded assets, I can do Search and Replace very easily, which is awesomely useful.
  • Similarly, I could potentially write a shell script that checked for the existence of the assets required by a quartz composer file.
  • Obviously, because the file is loaded into RAM on load, if I open the file simultaneously in SEE and QC, and make changes in SEE, these are not reflected unless I do ‘revert to saved’ in QC (and to that I need to make some change in QC to allow that option to appear); So that's not hugely useful.
  • The fact that the XML file seems to open and work just as well as the binary does beg the question, why is Apple using this format?
  • There are probably all sorts of parameters and alterations you could make to the files outside of QC; in fact if you were very determined you could probably create whole QC files without even opening the quartz composer application.
  • Perhaps in combination with a custom application, that constantly checked the file for updates, it could dynamically reload the content?
  • Would it be possible to put the content of QC files into a database for instance; to dynamically generate them on the fly - you could then write a local web application for managing assets (he says as PHP/MYSQL developer - technology I understand!)

I'm sure that there is some mileage in this stuff. Will report more another time.

SteamSHIFT out.

Now, I realise that this little post is probably just for my records, but we go …

At work I was setting up a server (Apple XServe running OS X Server 10.4.3), and I wanted to copy the set up from a different XServe.

  • So in Server Admin (application), in the set up for the old server, I dragged the little icon from the Web < Settings < Sites tab to the desktop.
  • I then edited it and dragged it back to the same window for the new server.
  • It looked like it had worked, but wouldn't save. I tried the same thing with the command line tools … no luck.
  • Phoned Apple support - surprisingly helpful (past experiences have not been entirely satisfactory). With their help I managed to boil it down to a problem with the plist file.
  • So, I created an empty plist file and bit by bit copied stuff in …

The culprit? The one secure domain. I have had problems with them before, so the moral of this story is, if your OS X Server web service is giving you problems, try taking out the secure stuff first. It might save some digging.

SteamSHIFT out.

Just as an addendum - a good number of problems in OS X are problems with plist files (a useful command line tool is plutil).

So, in response to my own musings on easier ways of re-linking to the movie files, i found the following:

Quartz Composer Discoveries: “They're binary-format PList files. You can open them in the PList Editor tool, which also means you can save them out as XML. The reverse transformation is also possible, which means that dynamically creating .qtz files should be possible by writing out or transforming XML data, then converting to binary PList. The contents of the PList is just descriptive of the structure of your composition - nodes and connections - not of the rendered output or, seemingly, any compiled code (although there is a quantity of binary data in the .qtz file that could be some sort of bytecode). Could imply that .qtz files are really purely declarative programs - source-code, if you like.”

Very useful, so let's have a little play

So, to convert (thanks to the ever useful MacOSXHints.com) …

macosxhints - 10.4: Convert new plist files between XML and binary: "Apple has introduced a new .plist file format in 10.4. You'll notice that you can no longer just edit a .plist file in TextEdit or other text editors. The reason for this is that the files are now binary rather than raw XML.

"

And I can confirm that the plutil utility works as expected on the QTZ file (I changed the name from .qtz to .plist ; I don't know if it was necessary but there we go). And Having done that I could open the file in TextWrangler (which BTW is brilliant), and using the find function I was able to find all my linked movies etc.

I haven‘t yet tried the conversion the other way, but one thing I did realise is the huge importance of titling all your nodes (and perhaps putting useful information in the description) - it’s going to take some investigating to find exactly which node my broken movie was in (I need to decide whether to take it out completely).

Anyway, more later. SteamSHIFT out.

If you work with video-in in quartz composer make sure you close the little preview window in finder column view - if it's open on the composition you are loading up, it will grab the video-in feed and stop it coming through to quartz composer. That little gotcha has caught me out a few times! Also it can really eat up RAM

SteamSHIFT out.

On Sat (10th) I was all set to be doing visuals with Gojira at The Brook in Southampton; when I got there I tried to load up my (admittedly way complex) quartz composer composition. Now I'm not exaggerating here, it took a full 10 minutes to load and then crawled like a snail carrying a very heavy load. This is on a 1.5Ghz G4 Powerbook with 1Gb RAM; no other foreground apps running. As you can imagine - I was getting very stressed.

So, at the suggestion of the BA.dger (Q: why didn‘t I think of that??), I created a new user account, and shifted the movies and composition etc. over to the /Users/Shared directory (and then went through the tedious re-linking … ooh if quartz composer compositions are essentially just xml files, could I have just done that using plist editor or a text editor and search and replace?? Also I have one movie that I can’t find the broken reference to - will that help me find it??)

SUCCESS! Ran beautifully. So there you go - hope it helps someone avoid the stress!

SteamSHIFT out.

blend_explorer.jpg

I have found that sometimes I am looking for a particular visual blend effect, but I can‘t remember how they look or don’t know how they will work with my clips / images. Maybe you're new to Quartz Composer and would like to learn more about blends.

Anyway here is a little composition I knocked up to have a look at the different blend modes. Just connect an image or movie to each of the “Render In Image” nodes and use the up and down arrow keys to cycle through the different modes.

desktop_small.jpg

Click on the above image top download a zip archive of this 1280 * 960 Gojira desktop, based on the album cover from Gojira's first album.

PE_example.jpg

Pocket Electronics Info: “Pocket Electronic (abbreviation: ‘PE’ in the following) is an universal electronics DIY kit to built your own MIDI control box. Up to 16 controlling elements can be connected to PE transmitting 16 different MIDI messages on different (or even the same) MIDI channels.”

Another handy board for making MIDI controllers

Copyright © 2013 - Brothers Bennettw - Powered by Hexo
- Ported theme GreyShade -