|
|
Your welcome Stephen, glad it worked out.
To clarify here is the code cleaned up. Copy and paste messes with things. :)
The comments here shouldn't break it.
/*CODE STARTS BELOW THIS*/
var curSeqFrame = parseInt(timeToFrames(t = time + thisComp.displayStartTime, fps = 1.0 / thisComp.frameDuration, isDuration = false)); /*GETS TIMELINE FRAMES*/
var offset = 0; /*CHANGE VALUE TO OFFSET FRAME NUMBER TO MATCH YOUR START FRAME*/
var seqNum = curSeqFrame + offset; /*FINAL SEQUENCE NUMBER VALUE*/
var seqName = thisComp.layer("SHT_VFX_25_ROTO_MB_LADY_V002.[0001-1050].png").name; /*CHANGE LAYER NAME TO YOUR CLIP NAME*/
var subtractChar = 20;/*NUMBER OF CHARACTERS TO REMOVE FROM YOUR LAYER NAME*/
var shortName = seqName.substring(0, seqName.length-subtractChar);/*FINAL ADJUSTED CLIP NAME*/
shortName + "." + seqNum;/*FINAL RESULT TO DISPLAY*/
/*CODE ENDS HERE*/
--
David Torno
Visual Effects Artist and Supervisor
http://www.ghosttownmedia.com
david@ghosttownmedia.com
O: 213.739.2290
C: 818.391.6060
------------------------------------------------
http://www.sydefxink.com (main portfolio)
http://aeioweyou.blogspot.com (vfx tutorials and AE scripts blog)
http://mactex.blogspot.com (free textures blog)
-----Original Message-----
From: Stephen van Vuuren [mailto:stephen@sv2studios.com]
Sent: Thursday, December 13, 2012 05:31 PM
To: 'After Effects Mail List'
Subject: Re: [AE] Script to display individual image sequence burn-in
Thanks David! (and everyone who chimed in). FYI, David's solution works
perfectly for what I need. Here it is:
1) The comments I added got messed up from the paste. To fix this just
re-copy the code here without the comments.
//?????????????
var curSeqFrame = parseInt(timeToFrames(t = time +
thisComp.displayStartTime, fps = 1.0 / thisComp.frameDuration, isDuration =
false)); var offset = 0; var seqNum = curSeqFrame + offset; var seqName =
thisComp.layer("SHT_VFX_25_ROTO_MB_LADY_V002.[0001-1050].png").name;
var subtractChar = 20;
var shortName = seqName.substring(0, seqName.length-subtractChar);
shortName + "." + seqNum;
//?????????????
stephen van vuuren
336.202.4777
http://www.insaturnsrings.com/
http://www.sv2dcp.com/
http://www.sv2studios.com/
A film is - or should be - more like music than like fiction. It should be a
progression of moods and feelings. The theme, what's behind the emotion, the
meaning, all that comes later.
-Stanley Kubrick
-----Original Message-----
From: David Torno [mailto:torno@sydefxink.com]
Sent: Thursday, December 13, 2012 7:47 PM
To: stephen@sv2studios.com
Subject: Re: [AE] Script to display individual image sequence burn-in
Oh, that should have still worked if the clip is in the same comp as the
text layer. Two possible other cause...
1) The comments I added got messed up from the paste. To fix this just
re-copy the code here without the comments.
//?????????????
var curSeqFrame = parseInt(timeToFrames(t = time +
thisComp.displayStartTime, fps = 1.0 / thisComp.frameDuration, isDuration =
false)); var offset = 0; var seqNum = curSeqFrame + offset; var seqName =
thisComp.layer("SHT_VFX_25_ROTO_MB_LADY_V002.[0001-1050].png").name;
var subtractChar = 20;
var shortName = seqName.substring(0, seqName.length-subtractChar);
shortName + "." + seqNum;
//?????????????
2) The quotes pasted as Smart Quotes, which can happen. To fix this paste
the code into a simple text (not rich text) document using TextEdit (mac) or
NotePad (pc). Then copy that new text into the expression.
--
David Torno
Visual Effects Artist and Supervisor
http://www.ghosttownmedia.com
david@ghosttownmedia.com
O: 213.739.2290
C: 818.391.6060
------------------------------------------------
http://www.sydefxink.com (main portfolio) http://aeioweyou.blogspot.com
(vfx tutorials and AE scripts blog) http://mactex.blogspot.com (free
textures blog)
-----Original Message-----
From: Stephen van Vuuren [mailto:stephen@sv2studios.com]
Sent: Thursday, December 13, 2012 04:29 PM
To: ''David Torno''
Subject: RE: [AE] Script to display individual image sequence burn-in
I did not pickwhip - I added a text layer to the comp then cut pasted this
expression and changed the layer name. Does it need a pickwhip and if so to
the layer or to Source Text?
stephen van vuuren
336.202.4777
http://www.insaturnsrings.com/
http://www.sv2dcp.com/
http://www.sv2studios.com/
A film is - or should be - more like music than like fiction. It should be a
progression of moods and feelings. The theme, what's behind the emotion, the
meaning, all that comes later.
-Stanley Kubrick
-----Original Message-----
From: David Torno [mailto:torno@sydefxink.com]
Sent: Thursday, December 13, 2012 7:17 PM
To: <stephen@sv2studios.com>
Subject: Re: [AE] Script to display individual image sequence burn-in
For the "seqName" variable that you pick whipped to your layer, make sure
".name" is still written afterwards. It might have been replaced when you
pick whipped.
David Torno
Visual Effects Artist & Supervisor
http://www.ghosttownmedia.com
O: 213.739.2290
C: 818.391.6060
---------------------
http://www.sydefxink.com
http://aeioweyou.blogspot.com
http://mactex.blogspot.com
"The most useless day is that in which we do not laugh"
-Charles Field
On Dec 13, 2012, at 3:48 PM, "Stephen van Vuuren" <stephen@sv2studios.com>
wrote:
> I cut and paste what you sent - just put in my layer name, also cut
> and paste.
>
> stephen van vuuren
> 336.202.4777
>
> http://www.insaturnsrings.com/
> http://www.sv2dcp.com/
> http://www.sv2studios.com/
>
> A film is - or should be - more like music than like fiction. It
> should be a progression of moods and feelings. The theme, what's
> behind the emotion, the meaning, all that comes later.
> -Stanley Kubrick
>
>
> -----Original Message-----
> From: David Torno [mailto:torno@sydefxink.com]
> Sent: Thursday, December 13, 2012 6:44 PM
> To: <stephen@sv2studios.com>
> Subject: Re: [AE] Script to display individual image sequence burn-in
>
> Check the case. Should be capital N on name.
>
> David Torno
> Visual Effects Artist & Supervisor
> http://www.ghosttownmedia.com
> O: 213.739.2290
> C: 818.391.6060
> ---------------------
> http://www.sydefxink.com
> http://aeioweyou.blogspot.com
> http://mactex.blogspot.com
>
> "The most useless day is that in which we do not laugh"
> -Charles Field
>
> On Dec 13, 2012, at 3:36 PM, "Stephen van Vuuren"
> <stephen@sv2studios.com>
> wrote:
>
>> David,
>>
>> Thanks. You are understanding correctly - tried this but get error
>> "Class global has no property named 'shortname' Error occurred at
>> line
>> 4
>>
>> stephen van vuuren
>> 336.202.4777
>>
>> http://www.insaturnsrings.com/
>> http://www.sv2dcp.com/
>> http://www.sv2studios.com/
>>
>> A film is - or should be - more like music than like fiction. It
>> should be a progression of moods and feelings. The theme, what's
>> behind the emotion, the meaning, all that comes later.
>> -Stanley Kubrick
>>
>>
>> -----Original Message-----
>> From: David Torno [mailto:torno@sydefxink.com]
>> Sent: Thursday, December 13, 2012 6:27 PM
>> To: stephen@sv2studios.com
>> Subject: Re: [AE] Script to display individual image sequence burn-in
>>
>> If I am understanding correctly, you just want the actual individual
>> frame name to show as a bug over the actual image frame?
>>
>> If so you could drop the clip into a comp, add a text layer above it
>> and apply this expression to the "Source Text" property. It's crude,
>> but should work.
>>
>> //???????????????
>> var curSeqFrame = parseInt(timeToFrames(t = time +
>> thisComp.displayStartTime, fps = 1.0 / thisComp.frameDuration,
>> isDuration = false)); //Gets timeline current whole frame number var
>> offset = 0; //Used to offset the above frame value to match your
>> sequence starting frame number var seqNum = curSeqFrame + offset;
>> //Creates your final sequence frame number variable var seqName =
>> thisComp.layer("SHT_VFX_25_ROTO_MB_LADY_V002.[0001-1050].png").name;
>> //Gets layer name. Pick whip in your actual sequence layer var
>> subtractChar = 16; //Number of characters to remove from the end of
>> layer name var shortName = seqName.substring(0,
>> seqName.length-subtractChar); //Shortens name
>>
>> shortName + "." + seqNum; //Creates final text to display
> //???????????????
>>
>>
>>
>> --
>> David Torno
>> Visual Effects Artist and Supervisor
>> http://www.ghosttownmedia.com
>> david@ghosttownmedia.com
>> O: 213.739.2290
>> C: 818.391.6060
>> ------------------------------------------------
>> http://www.sydefxink.com (main portfolio)
>> http://aeioweyou.blogspot.com (vfx tutorials and AE scripts blog)
>> http://mactex.blogspot.com (free textures blog)
>>
>> -----Original Message-----
>> From: Stephen van Vuuren [mailto:stephen@sv2studios.com]
>> Sent: Thursday, December 13, 2012 02:59 PM
>> To: 'After Effects Mail List'
>> Subject: [AE] Script to display individual image sequence burn-in
>>
>> I'm working with some long space image sequences (20,000+ frames) and
>> need a quick way to identify a specific frame in a sequence. I need
>> to hack some way for AE to tell me which filename of the imported
>> image sequence is on screen, ideally via visual burn-in layer - but
>> it appears AE can only reference the file name? The workaround would
>> be doing math but that gets awkward very fast.
>>
>>
>>
>> Is this possible in AE?
>>
>>
>>
>> stephen van vuuren
>>
>> 336.202.4777
>>
>>
>>
>> http://www.insaturnsrings.com/
>>
>> http://www.sv2dcp.com/
>>
>> <http://www.sv2studios.com/> http://www.sv2studios.com/
>>
>>
>>
>> A film is - or should be - more like music than like fiction. It
>> should be a progression of moods and feelings. The theme, what's
>> behind the emotion, the meaning, all that comes later.
>>
>> -Stanley Kubrick
>>
>>
>>
>>
>>
>>
>>
>>
>
>
>
+---End of message---+
To unsubscribe send any message to <ae-list-off@media-motion.tv>
|
|