Interesting problem, update defocused effect plugin

Find out why the . goes before the /

Moderator: Paul Tuersley

Post Reply
Darkmoon_UK
Posts: 62
Joined: September 5th, 2006, 3:45 am
Location: Chiswick, London, UK
Contact:

Hi all,

I am hoping for some advice on some scripting I am currently involved in. Ultimately, I think my question relates to getting expressions to update between compositions...

The script, in essence, is not a complex one, generating a hundred or so namestraps from a text file, rendering each one, in turn on its own 3D layer.

So far so good, but I also want a box around the text, which varies in size, depending on how much text there is, to fit the text. The limitations of dealing with text in script are well known; and this includes things like 'measuring' the size of it, so I knew this wasn't going to be the easiest thing to automate.

Thankfully I came across Paul Tuersleys 'PT Text Info' plugin, which works as an effect with two parameters, revealing the bounding box of the text being rendered. This would be perfect (nice one, Paul) except for the limitation that it won't work with a 3D layer, only 2D.

I figured this could by solved by making another composition with the same text in a 2D layer, used soley for the purpose of measuring the text, using Pauls plugin. I set its text source as an expression, referring to the text source of the 3D layer in my original composition.

The box around this 3D layer was then set to an expression that refers to the measured values in Pauls 'PT Text Info' effect in the other composition.

This *does* work, in principle. The problem I am having is that the update seems to be sporadic, often needing encouragement in the form of switching between compositions, viewing the effect parameters in he effect panel etc.

I am not sure if its the expressions between the two compositions that aren't updating, or the values in Paul's plugin (since its an effect thats in an off-screen composition).

How can I force the effect of an off-screen composition to update, and any expressions associated with it?

Prize of eternal thanks goes to the winner :-)

Any suggestions greatly appreciated.
Paul Tuersley
Posts: 704
Joined: June 5th, 2004, 7:59 am
Location: London, UK

I can't claim credit for the Text Info plug-in. The PT in this case is Peter Torpey (aka vidpat) and here's the thread where he posted a link to it: http://www.aenhancers.com/viewtopic.php?t=150

This isn't an area I'm particularly familiar with so hopefully someone else, maybe Peter, can offer some help.

Paul T
Darkmoon_UK
Posts: 62
Joined: September 5th, 2006, 3:45 am
Location: Chiswick, London, UK
Contact:

Peter Torpey - My sincere apologies - I got the wrong 'PT'!
Darkmoon_UK
Posts: 62
Joined: September 5th, 2006, 3:45 am
Location: Chiswick, London, UK
Contact:

I have discovered another possible avenue to solving the scale-to-text problem:

When you create a mask in the AE interface, it automatically bounds the amount of text in the text field. If I could get the script to create this default mask, then remove it again for each piece of text, I could read the bounds of the text from the mask properties.

Does anyone know how to script the creation of this default mask as I can't see that either?

Adobe didn't make this easy!
Post Reply