Graphics

 View Only
Expand all | Collapse all

Life without inverted masks...

  • 1.  Life without inverted masks...

    Posted 09-27-2018 22:49
    ...is at times VERY difficult.

    I find myself in a situation in which, were the option to simply invert a mask present, would be child's play. BUT since it is not an option, I am having to try and figure out how to create this rig to emulate that sort of behavior.

    Simple setup:

    L3rd, made of a simple Quad, set to a width of 1920. The pivot point for this quad is set to -960, so that it is all the way to the Left Side of the screen.

    I have a VL setup which drives the X Scale of the quad based on the bounding box width of the text which resides in said L3rd.

    Then, I have a group object set to the same position as the quad, and am bringing the quad on by animating the X scale of that group object. This allows the easing of the animation to translate perfectly regardless of the length of the text.

    All of this is working great. Where it goes off the rails is on the text reveal...

    The text is meant to appear as though it were being wiped on in place by the quad. In After Effects, this is a simple matter of duplicating the animated quad, and setting it to be an alpha matte for the text, so that it only appears when and where the back plate is, no sweat. For this to work the same way in XPression, I would have to be able to set the mask to an Inverted state so the element growing on would reveal, but since I cannot do that, I have to make the opposite happen where the mask object moves off the text in a way that mirrors the quad scaling on, while also respecting the logic with respect to text length. I can get the inverse telescoping thing to happen, but animating the reveal is proving to be an exercise in frustration. I've tried all manner of things, dividing thus by that, adding this to that, subtracting one thing from the other, using a second group to scale the mask separately etc, but I cannot seem to get a repeatable, scalable behavior.... I know there has to be an answer, and it seems like it should be relatively simple, but it has eluded me all afternoon.

    Anyone have any ideas?

    Thanks in advance


  • 2.  RE: Life without inverted masks...

    Posted 09-28-2018 00:10

    This is as far as I can get it... everything here works BUT the back plate and the matte both scale in the same direction, so as to create a symmetrical move where they start at opposite sides of the screen and meet at the end... INSTEAD, I need the matte to do the opposite.. to be at a scale of 1 when the back plate is at 0, and then scale down in direct relationship to the way the back plate scales up so the edges of where one starts and other ends always line up perfectly.

    The tricky bit is I am limited to a range of 0 and 1.. so the usual trick of a -1 multiplier wont work as having a negative scale is of course not what we're after. How can I make is so that when the plate BP_ANIM starts at 0, the Matte_Offset is at 1, and then when the animation completes. and say (per the length of the text) the Back_Plate is at 56, the Matte_Offset resolves to 44?


    #XPression


  • 3.  RE: Life without inverted masks...

    Posted 09-28-2018 01:13
    I've been trying to approach this from any angle I can think of.... trying to move the matte instead of scaling it, but I either end up with a matte that overshoots the animation of the quad, or is simply doesn't line up.

    fir this I have to account for both the animated 0 - 1 scale of the BP Anim Group object AND the logic-adjusted scale of the backplate quad (being driven by the bounding box width scaled of the text object). this is so unbelievably basic I cannot believe I am unable to find a workable solution. Trying not to vent too much on the board, I just have literally no one I can talk to about this and 7 hours of futility is enough to frustrate even the most saintly of us....
    #XPression


  • 4.  RE: Life without inverted masks...

    Posted 09-28-2018 02:06
    Do you have an example from After Effects of what you're trying to do? Still trying to wrap my head around this.
    #XPression


  • 5.  RE: Life without inverted masks...

    Posted 09-28-2018 05:03
    I can find one, but honestly its just a simple quad that scales on left to right on X. The text doesn't move. but gets wiped on by the by the quad as it scales in. Super basic stuff...

    Thing is, the reference they sent us has a very specific ease to the animation that needs to be emulated exactly, and they want the length of the lower 3rd to change dynamically with the length of the text, and that easing needs to be the same regardless of the length.

    So, to do this, I have the quad (1920 wide) rigged to a VL that scales on X the quad with the bounding box width scaled of the text. I do the animate in with a group object which is the parent of the quad who's position is the same as said quad. The group animates on scale from 0 to 1 over the course of about 1.5 to 2 seconds (I forget the exact timing, but that's immaterial) while the size of the quad itself is determined by the VL (you can see the rig in the screen shot I attached earlier from the office).

    All of that works 100% perfectly, the animation is beautiful and consistent at any length. The problem is in trying to do the text reveal. I can get the mask quad to stick perfectly to the end of the animated group, but of course that would only work if the l3rd was always 1920, it of course doesn't work when the nested quad is any other length, and no matter what I do I can't get the quad to 'stick' to the end of the resized nested quad as it builds in. If I try to do a scale -> position translation where I try different operations to connect the animated scale of the group and the scaled value of the quad to the position of the mask, the mask over shoots the the quad, they aren't moving at the same speed... if I try to do a scale->scale operation, I can only get them to both scale to the opposite edges, and even then they move at different speeds.

    Its frustrating as doing this kind of reveal in AE is so simple as to be an afterthought. If XPression had the option to invert a mask, I could just duplicate the quad, apply all the same adjustments / animations to it, and let the text reveal at the mask grows across it. I have to figure out a way to instead make it do the opposite, and it's proving to be a hugely unexpected and horribly frustrating obstacle on a project with an impossibly tight turn around.

    I appreciate any thoughts / insights you have. I could send you possibly a sample scene and reference movie tomorrow if you have a channel through which I can contact you (I don't think I can post it publicly). I have to figure this out, and I remain steadfast in my belief that it is achievable.
    #XPression


  • 6.  RE: Life without inverted masks...

    Posted 09-28-2018 13:53
    So this is a bit complicated to do, but this is the only way I know how to do it for the animation to work regardless of text length. You want to create a Null object in which you animate from 1 to -1 over the length you want your mask to animate. This object needs to be completely separate from the scene with the visibility off. You then also want to create another Null object that will guide your animation. The mask you are using for the text needs to be a child of this object so you can call this Null your "Text Null". The rest of this is VL based. So you take your bounding box width scaled of your main text object and offset this by an amount you'd prefer (something to fine tune after the animation works). You take the output of the offset block and run it into a Multiply with the Null (the one with its visibility off) as its multiplier (this is the Null you animated from 1 to -1). You then want to run the multiply block into a divide block in which you divide by 2 and then you output this value to your "Text Null" in which you mask is a child of. The mask needs to always have a x position of 0. It's a weird setup, but it works for any text length and allows for the animation to be the same every time. You'll want to put the easing on your Null animation.
    #XPression


  • 7.  RE: Life without inverted masks...

    Posted 09-28-2018 13:59
    Hello Willie,
    sorry but I don't understand very well what you want to do (sometimes my english is not so good ...)
    It seems the issue is with the animation that must depends on text width.


    I've made a sample project with a quad mask that reveals lower third and stop at the end of the text with same "template" animation. Visual Logic is used.
    [ATTACH]n17256[/ATTACH]
    Don't know if it's what you want .

    As drewshealy97 suggested , if you can create a simple video example with After Effects it will help.


    #XPression


  • 8.  RE: Life without inverted masks...

    Posted 09-29-2018 00:03
    Hey guys, I got it working with a variation of Amignon's rig... Drew, for some reason, I couldn't get your setup working. I have a few theories to why, but being that I was presented with 2 options here and the other worked, I didn't go back to investigate. I really appreciate the both of you!
    #XPression


  • 9.  RE: Life without inverted masks...

    Posted 10-02-2018 22:23

    Hey will, doesn't "invert" under the current stage modifier do what you want?


    #XPression


  • 10.  RE: Life without inverted masks...

    Posted 10-03-2018 17:31
    Hi Red, though it seems like it should, it doesn't... the material ceases acting like a mask at all when I change the current stage modifier.
    #XPression


  • 11.  RE: Life without inverted masks...

    Posted 10-03-2018 20:27
    Hey Willie, not my method but sent to me by a colleague, try this method instead.

    Here is the way to set invert mask. [LIST=1]
  • Set material blending mode to Alpha Mask
  • In texture shader, set Alpha Blending blend mode to Subtract and Mix value at 100%
  • It needs a layer object to work.

  • #XPression


  • 12.  RE: Life without inverted masks...

    Posted 10-03-2018 22:27
    Alas, that didn't work either... It again just ceases to be a mask in those conditions...
    #XPression


  • 13.  RE: Life without inverted masks...

    Posted 10-03-2018 23:03

    changing texture shader seems to work to invert mask :



    see sample project attached : [ATTACH]n17302[/ATTACH]

    Thank you @redmile for this information !


    #XPression


  • 14.  RE: Life without inverted masks...

    Posted 10-04-2018 01:00
    Well, the only difference I see between your example and my attempt was that in mine, the Mask Texture was occupied the entire texture space, where as yours is in the center with some 'dead' space around it. So, it is technically an inverted mask, and would have some usefulness for sure, but still doesn't quite work in the manner I was imaging which is essentially the way that track mattes work In After Effects.

    Cool nonetheless. Thanks guys, and cheers.
    #XPression