Learning With Quartz Part 5: Using Twitter Hashtags + RSS Feeds in VDMX

| 7 Comments

[[ UPDATE : A while ago – Twitter changed the way it deals with RSS, thereby breaking the technique below… ]]

(( For possible solutions, try this labnol work-around (video explanation)
or try this discussion over at the Inklen / Serato QC forums... ))

As part of doing live video for a event a few months ago, I was asked about displaying a live twitter feed for it.
“I can probably take care of that.” Which meant…

QUARTZ COMPOSER WRESTLING

Ingredient 1:

The basic RSS patch that comes with Quartz Composer…

RSS quartz composer patch

(Entering the skynoise RSS feed URL into the patch on the left, generates the output in the viewer on the right.)

Ingredient 2:

Generating an RSS feed from a hashtag.

Although Twitter doesn’t offer up RSS feeds, it turns out they can be generated by using the following URL

http://search.twitter.com/search.atom?q=%23hashtag

and replacing the word hashtag with your word of choice eg

http://search.twitter.com/search.atom?q=%23KONYtattoos

http://search.twitter.com/search.atom?q=%23cannibalsvisitingIKEA

http://search.twitter.com/search.atom?q=%23butmorriseysaysmeatismurder etc

Which means – this URL can be used to populate your Quartz patch, with any tweets published by people using that hashtag.

So I edited that quartz composer file, so each tweet was composited the way I wanted, in a 16:9 image, and details like date etc were turned off.

(Uploaded here: https://skynoise.net/qtz/RSS_twitter-test2.qtz.zip )

Problems:

The Quartz patch didn’t seem to continually update from the twitter RSS feed – but starts to cycle back through older tweets in a loop after a while… ( like 10-15 tweets ? ) + couldn’t figure out how to display author, alongside the text … Tried looking through the RSS info to find author parameters, then see where these might be adjusted within the quartz patch, no dice.

Solution: ( via @lumabeamerz / aka Mr.Coge : check his software out! )

I posted a description of the problem to pastebin and asked on twitter.. and @lumabeamerz kindly wrote back *and* adjusted the quartz patch, noting…

“If you put your mouse pointer for a moment to a structure’s output, you will see what is “flowing”, like this:

So, 0-4 are indexes, “…” are keys. Basically, we need the member of key “authors”, which will give use an other structure. The index 0 member of structure is good for us, and give us an other structure. From the last structure, we can extract the name with the key “name”. It is simple if you are a programmer, since the method is same in the Obj-C land to access structures. For the updating, I connected a Signal patch to the RSS patch’s update signal input, so it actually refreshes in a 60sec. period.”

Here’s the final quartz patch, edited by @lumabeamerz – which continuously updates any tweets from a particular hashtag, and displays author name alongside. Maybe it’s a useful template for you to modify however you wish?

https://skynoise.net/qtz/RSS_twitter-test3-lumabeamerz-edit.qtz.zip

And below, the patch inside VDMX:

vdmx twitter rss quartz patch

(See above: when triggered from a VDMX media bin, the quartz patch, gives an option for writing in your preferred hashtag. If you want to add more controls, such as changing the colour, size or position of text – you can publish the relevant parameters in quartz, so they become available for use inside VDMX. )

For more industrial options – see the *spark screenrunner

Recently Gathered Quartz Composer links: 

– cv at github shares 14 example quartz patches as tutorials, available for download and playing with.

– Superfleamedia 3 part tutorial about using iterators-in-quartz-composer

– http://quartzcomposer.nodepond.com/ – Patches and various how-to’s, by Nodepond – specialists in Mac OS-X and iOS graphic tools.

– Pixelnoizz on how to turn a quartz patch into a Pixelmator filter

Learning Quartz Composer Part 1
Learning Quartz Composer Part 2
Learning With Quartz Part 3: DIY Anchor Rotation FX for VDMX
Learning With Quartz Part 4: 3D Objects With Video Textures in VDMX

Autobot Roulette:

7 Comments

  1. Maria Jaramillo says:

    Hi there!
    thanks for posting that! found it really useful.
    Wander if there´s a way to display more than one feed at the same time, say last 3 or 4… is this possible?
    Thanks

    • j-p says:

      Thanks Maria –
      I don’t see why you couldn’t replicate the patch, but include 3-4 different feeds… each composited to be somewhere slightly different… ( doing that composition within VDMX, or perhaps within Quartz )

  2. This is brilliant!

    Just wondering if this could display a picture via a tweet?

  3. Wiley says:

    For some reason the composition just gives me an all-white screen both in quartz composer and in vdmx.

    • j p says:

      Hi Wiley – I just updated the post to reflect that Twitter changed their RSS API a fair while ago, breaking this technique… I’ve included a link at the top to a possible solution / workaround…

      maybe this’ll work for you?

      cheers!

  4. zam says:

    hey jean, thanks for this. pretty awesome stuff. i’ve tried it out and worked okay. only problem is the author’s name doesn’t appear alongside the tweet. how do i fix this?

    thanks!

Leave a Reply

Required fields are marked *.


This site uses Akismet to reduce spam. Learn how your comment data is processed.