VideoHelp Forum


Try DVDFab Video Downloader and rip Netflix video! Or Try DVDFab and copy Blu-rays! or rip iTunes movies!
+ Reply to Thread
Results 1 to 16 of 16
Thread
  1. Hello,

    I am in process of trying to restore/remaster some old footage. One thing i want but i have not found a proper solution is a good way to compare the original with the restoration result.

    Previously i've used the method of taking a screenshot of the same frame, but there has to be a better way, we are infact in 2021 and not 2001!

    I found this application (Video of the app in use: https://www.youtube.com/watch?v=ZAq3I8VduFg ) and the idea behind it is great but it doesn't work for 99.9% of the file formats i try it with, anyone know anything siimilar that has the capability of comparing 2 videos where you have a slider in the middle that you can move back and fourth to see the exact difference?

    Thanks!
    Quote Quote  
  2. Member
    Join Date
    Jul 2018
    Location
    Italy
    Search Comp PM
    create a .avs file with the command stackhorizontal(video1, video2)
    open the file in VirtualDub

    video1 and video2 must be same colors space and same height
    Last edited by lollo; 5th Apr 2021 at 08:09.
    Quote Quote  
  3. Member
    Join Date
    Jul 2018
    Location
    Italy
    Search Comp PM
    If you wish dynamic comparison

    Fixed cursor animation (not moving with mouse)

    avisynth animate and alpha_mask (search the forum), example attached

    Moving cursor with mouse:

    without using expensive video editing software the only way I found is html5 (requires conversion to h264, mp4 container)
    https://codemyui.com/video-comparison-slider-animation-using-html5/

    I can send my scripts if you wish

    P.S. I will check that "video comparator" you linked...
    Image Attached Files
    Last edited by lollo; 5th Apr 2021 at 08:13.
    Quote Quote  
  4. I put the "before" and "after" on two tracks in my NLE (Vegas) and can either place them side-by-side, like the AVISYnth StackHorizontal function, or I can press the mute button for the top track while the video plays and "A/B" between them while they are playing.

    With AVISynth scripts I often use the simple trick of interleaving the before and the after by assigning the variable "source" to the video that is fed to the script and "output" to the video that results from all the things done by the script. I then use this simple code to interleave them.

    Code:
    Interleave(source, output)
    I can then walk through the video, one frame at a time, and simply press the right & left keys to go back and forth between the original and the altered version. This really makes the differences pop out.
    Quote Quote  
  5. Another option is avspmod tabs using avisynth. The number keys hotswap the version loaded in each tab. It's easier to compare more than 2 versions or filter chains and keep track of original frame numbers and timecode in the status bar (if you use interleave, the original frame numbering change). Built in color picker with x,y coordinates, so you can read off R,G,B, and Y,U,V and hex values

    Natron has a A/B compare interactive wipe viewer like that video in the first post. You can drag the wipe, change angle and opacity. Or if you have more than 2 inputs, you can swap with number keys for each read node like avspmod. It supports most video formats using libavformat (like ffmpeg). But natron a node based compositor and probably not intuitive to use for most people. It's a free/open source clone of nuke
    Quote Quote  
  6. thanks for all the tips, i feel like all these solutions are rather complex, having to write custom scripts each time you want to do a compare.

    would be real damn nice to have something like in the video i linked where you simply just drag and drop 2 videos on the application and voila you have an instant compare where you can drag between to see the exact difference, wishful thining i guess With all these custom ways and scripts i feel like just taking a screenshot may be the easiest solution still.
    Quote Quote  
  7. Originally Posted by lollo View Post
    If you wish dynamic comparison

    Fixed cursor animation (not moving with mouse)

    avisynth animate and alpha_mask (search the forum), example attached

    Moving cursor with mouse:

    without using expensive video editing software the only way I found is html5 (requires conversion to h264, mp4 container)
    https://codemyui.com/video-comparison-slider-animation-using-html5/

    I can send my scripts if you wish

    P.S. I will check that "video comparator" you linked...
    Sort of close but to much work to do the compare, i do a lot of testing so having to do a lot of work for each compare just adds too much overhead, a simple frame screenshot seems to still be the most efficient way of doing it i guess

    I guess you could also use something like "Awesomeplayer" to play 2 files at the same time side by side, which works sorta nice.
    Quote Quote  
  8. Member
    Join Date
    Jul 2018
    Location
    Italy
    Search Comp PM
    do a lot of work for each compare just adds too much overhead
    For the second option, once you have written the html code, you just change the reference to the files (<10 seconds!)

    The avisynth method requires more writing if you want to overlap the moving cursor with different scenes. In addition you cannot move the cursor. But it works with lossless avi files.

    edit: added html5 example
    Image Attached Files
    Last edited by lollo; 5th Apr 2021 at 13:28.
    Quote Quote  
  9. Originally Posted by VidNew23 View Post
    thanks for all the tips, i feel like all these solutions are rather complex, having to write custom scripts each time you want to do a compare.

    would be real damn nice to have something like in the video i linked where you simply just drag and drop 2 videos on the application and voila you have an instant compare where you can drag between to see the exact difference, wishful thining i guess With all these custom ways and scripts i feel like just taking a screenshot may be the easiest solution still.


    You don't have to write a script, if you're only viewing - you can drop and drag videos into avspmod, and if you setup extension templates, it will automatically fill in the source filter, path and names. Say you want "MOV" files to open with LSmashVideoSource - You fill in the template LSmashVideoSource(***) for MOV - whenever you drop a MOV it will fill in the script. If you drag and drop 2 or more videos, it will automatically open each in a separate tab filled in with paths and names. I always like the "original" in tab 1, so it's like windows selections when you group select - select the last one first and it will appear in tab 1. One issue with avspmod is it will stop playing if you swap tabs. But you can drag the slider, and hit number keys to swap, or change the hotkey to play/stop

    You can drop and drag videos into natron and they will automatically open a read node and connect a pipe to the viewer. If you drag 2 videos, the 1st node will automatically be connected, but the 2nd requires you to click on the node and assign number key such as "2" to connect to viewer. One issue with natron is it's designed and optimized for image sequences and VFX. "Video" formats can open (it uses ffmpeg libraries), but it's not optimized (slower ). But if you for some reason like that interactive wipe slider, it works

    If you use the screenshot to compare - it's quite limited and "clunky". What if you want to compare other frames ? Say you see something that needs to be "fixed" - so what are you going to do about it ? What is your process of "restore/remaster some old footage?" Are you going back and forth between programs? If part of your "restoration" is using a script anyways, it makes sense to do it in avspmod because you can adjust the script, refresh (f5). Maybe stronger denoise settings in one tab, compared to higher saturation in another, etc...you can preview the results without having to encode an actual video and wasting time going back and forth a dozen times to tweak settings, or hours to encode
    Quote Quote  
  10. I'm a Super Moderator johns0's Avatar
    Join Date
    Jun 2002
    Location
    canada
    Search Comp PM
    Another way to show 2 different videos playing at the same time is to use mpc-hc and in options set the open options to have a new player for each video played.
    I think,therefore i am a hamster.
    Quote Quote  
  11. Originally Posted by VidNew23 View Post
    all these solutions are rather complex, having to write custom scripts each time you want to do a compare
    It can be all be done in a batch file. You can drag/drop two videos onto the batch file.

    For example:
    Code:
    echo v1 = LWLibavVideoSource("%~dpnx1", cache=false) > comp2.avs
    echo v2 = LWLibavVideoSource("%~dpnx2", cache=false) >> comp2.avs
    echo StackHorizontal(v1, v2) >> comp2.avs
    echo #Interleave(v1, v2) >> comp2.avs # alternate method
    "G:\Program Files\VirtualDub2\VirtualDub64.exe" comp2.avs
    del comp2.avs
    You have to change the path to the player/editor. And you must have AviSynth installed. If you put the batch file in your Send To folder you select a pair of files, right click on one, and select Send To -> comp2.bat (or whatever you name the batch file).
    Quote Quote  
  12. Video Restorer lordsmurf's Avatar
    Join Date
    Jun 2003
    Location
    dFAQ.us/lordsmurf
    Search Comp PM
    That Youtube video tool is broken, download corrupt. At least it was for me.

    Avisynth is what I use. There's no one-size-fits-all script, but something like this:
    Code:
    clip1=AVISource("c:\X.avi",false)
    clip2=AVISource("c:\Z.avi",false)
    StackHorizontal(clip1.crop(0, 0, 0, 0), clip2.crop(0, 0, 0, 0))
    Simple side-by-side.
    Image Attached Files
    Quote Quote  
  13. You can easily show a left/right split in AvISynth too.
    Code:
    function ShowSplit(clip v1, clip v2, int x)
    {
        x = x / 2 * 2 # in case chroma subsampling
        StackHorizontal(crop(v1,0,0,x,-0), crop(v2,x,0,-0,-0))
    }
    
    v1 = LWLibavVideoSource("video1.mkv", cache=false) 
    v2 = LWLibavVideoSource("video2.mkv", cache=false) 
    ShowSplit(v1, v2, v1.width/2)
    That shows video1 on the left and video2 on the right, split down the middle. You can split anywhere along the x axis. There's no interactivity in the split position though. You have to change the script if you want to change the position.

    And again, you could make a batch file that automatically builds the script and starts an editor/player for you.
    Quote Quote  
  14. Member
    Join Date
    May 2005
    Location
    Australia
    Search Comp PM
    I guess you could also use something like "Awesomeplayer" to play 2 files at the same time side by side, which works sorta nice.
    You can do the same with VDub, with frame-accurate step-thru. Open two VDubs, make them each exactly the same size (Windows drag left to edge, drag right to edge) then set the View to Page Layout>Auto Size.
    Quote Quote  
  15. Originally Posted by poisondeathray View Post
    You don't have to write a script, if you're only viewing - you can drop and drag videos into avspmod, and if you setup extension templates, it will automatically fill in the source filter, path and names. Say you want "MOV" files to open with LSmashVideoSource - You fill in the template LSmashVideoSource(***) for MOV - whenever you drop a MOV it will fill in the script. If you drag and drop 2 or more videos, it will automatically open each in a separate tab filled in with paths and names. I always like the "original" in tab 1, so it's like windows selections when you group select - select the last one first and it will appear in tab 1. One issue with avspmod is it will stop playing if you swap tabs. But you can drag the slider, and hit number keys to swap, or change the hotkey to play/stop

    I never knew you could drag and drop videos and images in it. That is great to know. I have always manually made a script to load my video or image in it. This is the best avisynth editor, and comparing tool I know of. That just makes it even more effortless.
    Quote Quote  
  16. Originally Posted by VidNew23 View Post
    thanks for all the tips, i feel like all these solutions are rather complex, having to write custom scripts each time you want to do a compare.

    would be real damn nice to have something like in the video i linked where you simply just drag and drop 2 videos on the application and voila you have an instant compare where you can drag between to see the exact difference, wishful thining i guess
    Please re-read my post above:

    https://forum.videohelp.com/threads/401381-Program-to-compare-2-video-files-to-see-res...on#post2615947

    That's exactly what I said I do using my NLE (Vegas).
    Quote Quote  



Similar Threads