VideoHelp Forum

Try DVDFab and download streaming video, copy, convert or make Blu-rays,DVDs! Download free trial !
+ Reply to Thread
Results 1 to 15 of 15
Thread
  1. Banned
    Join Date
    Oct 2014
    Location
    Northern California
    Search PM
    I like to get some suggestions on the best approach on how to make a stroke of videos (more than 50) that slide right to left. I did a small project with 13 videos and it works great with using a sliding window on top of a large video canvas, however this solution obviously does not scale.

    Any suggestions?

    Here is a sample of what I am looking for:
    https://www.youtube.com/watch?v=72XQb_m-IEg
    Quote Quote  
  2. Member racer-x's Avatar
    Join Date
    Mar 2003
    Location
    3rd Rock from the Sun
    Search Comp PM
    I don't particularly care for it myself, but you should be able to do it. Create a series of screens and use a push transition to animate them. Just slow down the speed to what you like.

    I know I can do this with Aviutl (free),
    Got my retirement plans all set. Looks like I only have to work another 5 years after I die........
    Quote Quote  
  3. Member racer-x's Avatar
    Join Date
    Mar 2003
    Location
    3rd Rock from the Sun
    Search Comp PM
    I just did a couple of very fast examples using various clips I had lying around. The first is a basic slide effect and the 2nd is a basic cube effect.

    Obviously you can slow it down or whatever, I just made it fast to reduce file size........
    Image Attached Files
    Got my retirement plans all set. Looks like I only have to work another 5 years after I die........
    Quote Quote  
  4. Banned
    Join Date
    Oct 2014
    Location
    Northern California
    Search PM
    I appreciate your help.

    The slide however needs to be continuous and the videos need to go in and out playing, assuming they are long enough.
    Quote Quote  
  5. Yes, you can do it manually, but I think he wants to do "automatically" and have more flexible options

    Are you against doing it in After Effects ?

    It's probably the "best" way to do this IMO with an expression. It's "easier" because you can use any number of source videos , import them all together at once (e.g. a folder) and link them together automatically through a position expression . You can control the animation of everything through parenting to a single null object or even the 1st video . It's flexible in that the same "rig"/project can be used for any dimensions (you can specify different position offsets through an expression controller) , and you have more options to move in other directions, or link up in other directions with one or two clicks
    Quote Quote  
  6. RE: avisynth options

    It's possible to do it in avisynth using StackHorizontal(a,b,c,d,....) and animate it that way using animate(). But you might run into memory problems. e.g for 50 1920x1080 "strips" , that essentially becomes a big 960000 width "composition" .

    You can use transpush() from v.c mohan's transall plugin, because it's a transition plugin, and requires an "overlap" of videos (overlap can't be "zero"), so it might get tricky doing the timing

    You also have to load each video into avisynth (with something like AE, you can import a folder at once, basically one or two clicks)

    (I'm assuming you're paying the "Adobe Tax" and thus have access to AE)
    Quote Quote  
  7. Member racer-x's Avatar
    Join Date
    Mar 2003
    Location
    3rd Rock from the Sun
    Search Comp PM
    Originally Posted by newpball View Post
    I appreciate your help.

    The slide however needs to be continuous and the videos need to go in and out playing, assuming they are long enough.
    Something more like this?

    ***Edit I left some errors in that file because I was rushing, but you get the picture. I'll leave you in the capable hands of PoisonDeathray. This is boring for me anyway.
    Image Attached Files
    Last edited by racer-x; 30th Nov 2014 at 17:58.
    Got my retirement plans all set. Looks like I only have to work another 5 years after I die........
    Quote Quote  
  8. Example with AviSynth:

    Code:
    #pan an overlay
    function pan_ovr(clip bg, clip ovr, int xpos)
    {
        xpos = (xpos/2)*2
        overlay(bg, ovr, x=xpos, y=0)
    }
    
    
    # make background video
    bg=ColorBars(width=1920, height=1080, pixel_type="YV12")
    
    #make an overlay by stacking variations of small copies of the background
    v1=bg.BilinearResize(640,360)
    v2=v1.Tweak(hue=100).FlipVertical()
    v3=v1.Tweak(hue=200)
    row=StackHorizontal(v1,v2,v3)
    ovr=StackVertical(row, row.Invert(), row.FlipHorizontal())
    
    # pan ovr from right edge
    Animate(1, 960, "pan_ovr", bg,ovr,1920, bg,ovr,0)
    
    Trim(0,960)
    All videos were synthesized within AviSynth so you don't need any video sources to run this script. Of course, you would build your own background and overlay by importing your own videos and stacking them.
    Last edited by jagabo; 30th Nov 2014 at 19:02.
    Quote Quote  
  9. Banned
    Join Date
    Oct 2014
    Location
    Northern California
    Search PM
    Originally Posted by poisondeathray View Post
    Yes, you can do it manually, but I think he wants to do "automatically" and have more flexible options

    Are you against doing it in After Effects ?

    It's probably the "best" way to do this IMO with an expression. It's "easier" because you can use any number of source videos , import them all together at once (e.g. a folder) and link them together automatically through a position expression . You can control the animation of everything through parenting to a single null object or even the 1st video . It's flexible in that the same "rig"/project can be used for any dimensions (you can specify different position offsets through an expression controller) , and you have more options to move in other directions, or link up in other directions with one or two clicks
    Interesting.

    I am not very well versed in AE but that is a great suggestion and also stimulates me to get more into AE.

    So I can automatically specify that the prior video is the parent and define that it is, say +600, pixels the right, paste that expression to all the videos and then animate the first video and everything should fall into place? PP has a limit of -32678 to 32767 so if we take a space of 600 pixels for one column with a video we can only place about 50 videos (seems like a bit depth limit so nesting sequences probably does not work). Is there a similar limit for AE if you know? By the way as an aside, would AE also allow you to tie volumes to location, so I could maximize the volume of a clip when it is center screen and decrease it outside the center and finally let it go to zero when it is off screen?

    Scalability could be an issue, when I rendered the 13 videos I got 24GB of memory usage (and 99% GPU usage which is nice thing to see the GPU being utilized fully occasionally). Now granted that is probably due to scaling. I suppose the best strategy would be to pre scale, process and trim the videos first before I load them.
    Last edited by newpball; 30th Nov 2014 at 19:27.
    Quote Quote  
  10. Originally Posted by newpball View Post

    I am not very well versed in AE but that is a great suggestion.
    Unfortunately there is a bit of a learning curve, but AE is made to handle this type of stuff. It's the "gold standard" for 2D animation / motion graphics

    So I can automatically specify that the prior video is the parent and define that it is, say +600, pixels the right, paste that expression to all the videos and then animate the first video and everything should fall into place?
    Yes, you can specify the offset for each layer, with an expression controller (you don't have to do it manually for each layer) , and everything will fall into place. It's an index-1 expression (each layer gets offset by the value you specify, takes into account the previous layer offset. Think of it like n+1) . Because everything is "linked" to a controller, not "hardcoded" it's a very flexible way of project design. This reduces the amount of work you might have to do later on down the road if you or client changes their mind about something. e.g. Let's say you change your mind and want to go left to right instead , but using the same order of videos (because Wimbleton comes after the French, etc...). No problem , you just swap the offset (-600) and the subseqent layers get flipped to the other side automatically. Or lets say you want 800. No problem, 1 controller. Manually arranging them in PP or other programs, or hardcoding values (a,b,c,d,e,f,g) you'd have to specify it instead so it's stackhorizontal (g,f,e,d,c,b,a) . "Hardcoding" reduces flexibility, limits your options

    PP has a limit of -32678 to 32767 so if we take a space of 600 pixels for one column with a video we can only place about 50 videos (seems like a bit depth limit so nesting sequences probably does not work). Is there a similar limit for AE if you know?
    No limits that I know of.

    By the way as an aside, would AE also allow you tie volumes to location, so I could increase the volume of a clip when it is center screen and decrease and finally go to zero when it is off screen?
    Yes, you can link parameters to control different parameters through expressions . e.g. you can have the "x" position of a layer affect the volume; you can have the volume of a soundtrack affect the position, scale etc....(audio reactive), those sorts of things

    Another way you might do this is through the animation timing (in general, in any program), if the motion is constant (you have known constants like FPS, width of "slices", animation rate, so you should know (or be able to figure out) exactly where everything is at a given point in time)

    Scalability could be an issue, when I rendered the 13 videos I got 24GB of memory usage (and 99% GPU usage which is nice thing to see the GPU being utilized fully occasionally). Now granted that is probably due to scaling. I suppose the best strategy would be to pre scale, process and trim the videos first before I load them.
    What do you mean by "Scalability" exactly ?



    One way I was thinking of doing it was to take 10 videos at a time and then take follow up batches with a single full screen overlap (the time it takes from a pixel to go from the extreme right to the extreme left of the frame) and then 'seam' the videos together.

    Yes those are good workarounds in general along with the prescaling, trimming, pre-rendering etc... Basically anything to reduce resources or operations in any program. The "prototypical" scenario is 20+ megapixel photos - if you don't need the resolution for reframing, it's often better to batch resize them first if you only need 1920x1080
    Quote Quote  
  11. Banned
    Join Date
    Oct 2014
    Location
    Northern California
    Search PM
    Okay, so I am trying to learn this.

    I import all my videos.
    Select them all and stack them on top of each other in a composition.
    Then I create a null layer.
    Then I create an expression for the first layer:

    Code:
    x=thisComp.layer(index-1).transform.position[0] - 600;
    y=transform.position[1];
    [x,y]
    And try to copy this to all layers below.

    Should this link them to the null and thus if I animate the null everything will follow?

    Edited to add: that seems to work
    Last edited by newpball; 30th Nov 2014 at 23:51. Reason: Add code box
    Quote Quote  
  12. There are several ways to do it, but I would use an expression controller (slider) for the null. This way you can have an easily accessible offset so changes can be made on the fly (flexibility), instead of having to copy & paste each time you want to make a change. One for X, one for Y (e.g. you might choose to scroll up/down instead of left/right), and it only takes a few extra seconds to set this up. You can rename them XOffset and YOffset (or any name you want). All you have to do is alt-click the "stopwatch" for the position property for the first layer and pickwhip it to the effect slider, or if you want, enter it manually

    It will look something like this:
    Code:
    X = thisComp.layer("Null 1").effect("XOffset")("Slider");
    Y = thisComp.layer("Null 1").effect("YOffset")("Slider");
    thisComp.layer(index-1).position + [X,Y]
    The way you copy & paste expressions is select the property (position in this case), Edit=> copy expression only, select all the position properties by shift selecting and pushing "p" then edit=>paste

    EDIT : I should have put it in a "code" box, the message board is displaying weird typos
    Last edited by poisondeathray; 30th Nov 2014 at 23:47.
    Quote Quote  
  13. Banned
    Join Date
    Oct 2014
    Location
    Northern California
    Search PM
    Originally Posted by poisondeathray View Post
    There are several ways to do it, but I would use an expression controller (slider) for the null. This way you can have an easy accessible offset so changes can be made on the fly (flexibility), instead of having to copy & paste each time. One for X, one for Y (e.g. you might choose to scroll up/down instead of left/right), and it only takes a few extra seconds to set this up. You can rename them XOffset and YOffset (or any name you want). All you have to do is alt-click the "stopwatch" for the position property for the first layer and pickwhip it to the effect slider, or if you want, enter it manually

    It will look something like this:
    X = thisComp.layer("Null 1").effect("XOffset")("Slider");
    Y = thisComp.layer("Null 1").effect("YOffset")("Slider");
    thisComp.layer(index-1).position + [X,Y]

    The way you copy & paste expressions is select the property (position in this case), Edit=> copy expression only, select all the position properties by shift selecting and pushing "p" then edit=>paste
    Yes I see what you mean.

    Thanks to you all folks, this helped me a lot!

    Quote Quote  
  14. Encoding (with x264 cli) 10 videos (actually 10 instances of the same video with different trims, one for the background, nine in the mosaic) with the following script used about 1.9 GB of memory:

    Code:
    #pan an overlay
    function pan_ovr(clip bg, clip ovr, int xpos)
    {
        xpos = (xpos/2)*2
        overlay(bg, ovr, x=xpos, y=0)
    }
    
    
    bg=ffVideoSource("Star Trek Insurection.mkv").Trim(100,1100)
    
    v1=ffVideoSource("Star Trek Insurection.mkv").BilinearResize(640,360).Trim(1000,2000)
    v2=ffVideoSource("Star Trek Insurection.mkv").BilinearResize(640,360).Trim(2000,3000)
    v3=ffVideoSource("Star Trek Insurection.mkv").BilinearResize(640,360).Trim(3000,4000)
    v4=ffVideoSource("Star Trek Insurection.mkv").BilinearResize(640,360).Trim(5000,6000)
    v5=ffVideoSource("Star Trek Insurection.mkv").BilinearResize(640,360).Trim(7000,8000)
    v6=ffVideoSource("Star Trek Insurection.mkv").BilinearResize(640,360).Trim(9000,10000)
    v7=ffVideoSource("Star Trek Insurection.mkv").BilinearResize(640,360).Trim(10000,11000)
    v8=ffVideoSource("Star Trek Insurection.mkv").BilinearResize(640,360).Trim(12000,13000)
    v9=ffVideoSource("Star Trek Insurection.mkv").BilinearResize(640,360).Trim(13000,14000)
    
    # stack all the videos, 3x3
    ovr=StackVertical(StackHorizontal(v1,v2,v3), StackHorizontal(v4,v5,v6), StackHorizontal(v7,v8,v9))
    
    # pan ovr from right to left
    Animate(1, 480, "pan_ovr", bg,ovr,1920, bg,ovr,0)
    
    Trim(0,480)
    You might be able to get another 9 videos with 32 bit AviSynth. Moving to 64 bit AviSynth should allow a lot more.

    <edit>
    I was able to get 18+1 videos encoded with x264, about 2.6 GB memory usage. VirtualDub wouldn't load the script though. Maybe it's not compiled with large memory (>2GB) support?
    Image Attached Files
    Last edited by jagabo; 1st Dec 2014 at 10:16.
    Quote Quote  
  15. Member racer-x's Avatar
    Join Date
    Mar 2003
    Location
    3rd Rock from the Sun
    Search Comp PM
    Great job on that video Jagabo. It looks great and is hard to believe it was all done in a commandline.

    Anyway I made a tutorial on animating multiple objects at once by grouping them into scenes in Aviutl. If anyone is interested here is a link: https://forum.videohelp.com/attachments/28942-1417569088/Group_Animation_tut.mp4

    And here is an example video.
    Image Attached Files
    Got my retirement plans all set. Looks like I only have to work another 5 years after I die........
    Quote Quote