VideoHelp Forum

+ Reply to Thread
Results 1 to 16 of 16
Thread
  1. Member
    Join Date
    Aug 2021
    Location
    Sweden
    Search Comp PM
    Hi

    I have been using Virtualdub when I want to alter the framerate in a certain part of a video.

    First I cut out the part/parts from the whole video I want to alter, then I reopen the part I want to alter.
    I alter the framerate to slowmotion or faster then original (original 30 fps or 29.97 fps). After that I open the altered part again and convert it to the same framerate as original.
    Finally I merge the different parts again. (For this last step I use another program than Virtualdub).
    The new video will have certain parts going faster then original and certain parts going slower.

    I like Virtualdub but the last version is from oktober 2013. I'm looking for something newer. A program that can do the same as I use Virtualdub for, but newer.

    I have tried Avidemux but the slowest framerate it can produce is 1 fps. I'm looking for something much slower.

    I have also tried Virtualdub2. in this new "version" It seems not possible to use the "Direct stream copy" option when saving the altered video (after changing the framerate). Instead you must use the "recompress" or "processing" mode. If you do that the altered video part will grow to a huge size.
    For exampel: a cut part of a video is 200 kB. After altering and saving with "Direct stream copy" the altered part will be about 500 kb - 1500 kB. But when you use the "processing" mode the new file will be a few GB.
    That means when I alter a few parts in video and then finally merge it again the whole video has grown from about 50 MB to 25 GB!!! Not acceptable with so big files. There must be another way.

    I have searched for several weeks now. Is there anyone who can give me a tip about a program that can do these things I want to do?
    Quote Quote  
  2. Originally Posted by PB_71 View Post
    If you do that the altered video part will grow to a huge size.
    That's because you're not choosing and configuring a video codec. You can make it as small as you like. Instead, you're getting uncompressed video, not what you want.
    Quote Quote  
  3. Skip to 5'24 and 7'45 and 8'35 in this video of mine.

    I show how to export and talk about file sizes.

    Perhaps you are not choosing the right settings when you export

    https://www.youtube.com/watch?v=4JBwafVNAVE
    Last edited by super8rescue; 17th Aug 2021 at 05:34.
    Quote Quote  
  4. Originally Posted by PB_71 View Post
    I have also tried Virtualdub2. in this new "version" It seems not possible to use the "Direct stream copy" option when saving the altered video (after changing the framerate).
    It works exactly the same with VirtualDub2. But the input must be AVI and you must use the AVI source filter when you open the video (just like the original VirtualDub).
    Last edited by jagabo; 17th Aug 2021 at 10:26.
    Quote Quote  
  5. Member
    Join Date
    Aug 2021
    Location
    Sweden
    Search Comp PM
    First, I want to thank everyone that has answered in this thread.
    The last few days I’ve been struggling to solve the problem, without success.

    I have downloaded Virtualdub2 again.
    I open a video and now I choose a codec under: video > Compression…

    I cut out the parts like before and when I save I must use “Full processing mode” or recompress because I can’t figure out how to use the “Direct stream copy” (I get a fault message “The source video stream uses a compression algorithm which is not compatible with AVI files”).
    Like Manono said; when choose a codec it will alter the size of the file. I have tried all the codec in the list and the files will be smaller than before, but still very big. A file that is about 1 MB before altering will with different kinds of codec be between 30-500 MB after. In uncompressed mode, which I used before, it became several GB.

    The best result I get is when I use the same codec as the original file. I used that one.

    One thing all codec have in common is when I save the file with Full processing mode it will take much more time before the process is done. In “Direct stream copy” it took about 2-4 seconds. Now, depending on which codec I use, it takes about from 1 minute to almost an hour.
    I can’t wait 40 minutes for processing a video that is only 30 seconds long. Bad choice!

    Like I said I decided to use the same codec as the original video. I changed the frame rate of one part of the video that I had previously cut out to 0.01 fps. After that, when I looked at the video, the picture had disappeared.
    (That change was possible in the previous Virtualdub when using Direct stream copy.)

    I don’t know how to solve the problem in Virtualdub2.
    So much effort and so little result…

    Does anyone know how to change the framerate with success in Virtualdub2?
    Is it possible to use the Direct stream copy mode instead of Full processing mode so it will go faster to process the video?
    Quote Quote  
  6. Member
    Join Date
    Mar 2008
    Location
    United States
    Search Comp PM
    Open the file with mediainfo and post the details here
    Quote Quote  
  7. you can only do a direct stream copy if it is a direct copy
    Any filters or change of framerate and it is not a direct stream copy, so this explains why you can't use direct stream copy.
    Quote Quote  
  8. Originally Posted by PB_71 View Post
    Virtualdub2 a... when choose a codec it will alter the size of the file. I have tried all the codec in the list and the files will be smaller than before, but still very big. A file that is about 1 MB before altering will with different kinds of codec be between 30-500 MB after.
    Some of the codecs are antiquated, don't compress well, and shouldn't be used: Intel IYUV, Microsoft RLE Microsof6t Video1. Some are lossless and result in big files but no quality loss: FFMPEG x265 lossless, FFMPEG FFV1 lossless, FFMPEG huffyuv lossless, and Lagarith. Some are meant for retaining high quality (not lossless) but don't compress very much: FFMPEG Apple ProRes, GoPro Cineform, Cedocida DV. Then there are the high compression codecs, most of which can be configured somewhere between very high compression with low quality and very low compression with high quality: FFMPEG VP8, FFMPEG VP9, FFMPEG x265 (8 and 10 bit), x264 (8 and 10 bit), Xvid. Of those, only Xvid should be used in AVI. Some of the others can be used in AVI but you're asking for trouble.

    Originally Posted by PB_71 View Post
    depending on which codec I use, it takes about from 1 minute to almost an hour.
    Most of the high compression codecs let you configure for high speed, high compression, and high quality. You can get any two of the three. Not all three.

    Originally Posted by PB_71 View Post
    Is it possible to use the Direct stream copy mode instead of Full processing mode so it will go faster to process the video?
    Yes, if your source is the right codec and you cut on the right frames. Upload a small sample (less than 500 MB) to this web site for analysis.
    Quote Quote  
  9. Member
    Join Date
    Aug 2021
    Location
    Sweden
    Search Comp PM
    I opened an old video, just like before, and began to cut it in 3 parts:
    Beginning (part 1)
    Middle part. The part I then want to alter (part 002)
    The end (part 3)

    Under video > Compression I selected XviD MPEG-4 Codec. All parts were saved with full processing mode.

    My intention
    With part 1 and 3 I do nothing.

    I open part 002. My intention with part 002 is to alter the frame rate to very slow, 0.01 fps. I save it with full processing mode. The altered part will have the name part 02.

    I open part 02 again and convert it back to the same frame rate as part 1 and 3. In this case 24 fps. I do this so I can merge it with the other parts. The converted part will have the name part 2. I save it with full processing mode.

    (I have done these steps with the “old” Virtualdub probably 100 times or more on different videos and it have never been any problems. But with the old Virtualdub I saved the parts with direct stream copy.)

    The result
    Cutting and saving the 3 parts were no problem. The trouble began with part 02. After saving it I tried to watch it but the picture was gone.

    Converting part 02 back to 24 fps was not possible. Probably because the picture had disappeared. I got an error code when I tried to save it:

    Image
    [Attachment 60452 - Click to enlarge]



    Information about the video:
    Image
    [Attachment 60453 - Click to enlarge]


    I attach all parts of the video except part 2 which I couldn't save.
    Image Attached Files
    Quote Quote  
  10. Member
    Join Date
    Mar 2008
    Location
    United States
    Search Comp PM
    What is the original running time of part 2 and what is the desired running time after the frame rate change(s)
    Surely you can use Avisynth for this ?
    Quote Quote  
  11. Upload the original video too. So we can try to replicate your problem.
    Quote Quote  
  12. Member
    Join Date
    Aug 2021
    Location
    Sweden
    Search Comp PM
    Image
    [Attachment 60472 - Click to enlarge]

    This is just an example video. The important thing is that I can find out how to make these changes.

    About the running time: I guess you mean part 002? It is just a few frames, 3 or 4 I think. I want the running time to be about 3-4 minutes after changing.
    The reason that I want to start using Virtualdub2 is because Virtualdub isn't developed any more. That goes for Avisynth too.
    The last version of Virtualdub is from October 2014 and Avisynth May 2016. I'm looking for something newer.
    Quote Quote  
  13. Originally Posted by PB_71 View Post

    About the running time: I guess you mean part 002? It is just a few frames, 3 or 4 I think. I want the running time to be about 3-4 minutes after changing.
    If it's just a few frames, it's basically going to be still image, or frame pause - not slow motion

    If you want it to slowly change, you need to generate new in-between frames - such as motion interpolation

    What about audio ? If duration increases for a section , it's going to be out of sync

    The reason that I want to start using Virtualdub2 is because Virtualdub isn't developed any more. That goes for Avisynth too.
    The last version of Virtualdub is from October 2014 and Avisynth May 2016. I'm looking for something newer.
    avisynth plus fork is actively developed
    https://github.com/AviSynth/AviSynthPlus/releases

    more recent beta releases are on doom9 forum
    Quote Quote  
  14. Member
    Join Date
    Aug 2021
    Location
    Sweden
    Search Comp PM
    Yes, this example will be still image. I will then merge it with the other parts of the video, which are not still image. (look what I have wrote earlier).
    In most cases I will add the sound after, or add a new sound.

    Avisynth: Yes you're right. I was a little quick to judge avisynth. I have read a lite more about it and it seems a little too complicated for me. I'm quite new
    to video editing.

    If you look at the top of this thread I have described what I want to do. Cut a part or some parts of a video, change the framerate and then merge with the other parts again.
    In Virtualdub this was easy, but in other programs it seems to be almost impossible...
    Quote Quote  
  15. What you want to do can be made trivial in AviSynth with this:

    Code:
    function SlowMoAt(clip v, int start, int end, float speed)
    {
    	# start slow motion at frame number start
    	# continue until frame number end (inclusive)
    	# slow that section to desired speed
    
    	p1 = Trim(v, 0, start-1)
    	p2 = Trim(v, start, end).AssumeFPS(speed, sync_audio=true).ResampleAudio(v.AudioRate).ConvertFPS(v.framerate)
    	p3 = Trim(v, end+1, 0)
    
    	p1++p2++p3
    }
    
    AviSource("Menace.avi") # load source video
    SlowMoAt(427, 429,  0.01) # start, end, speed
    If you put the SlowMoAt() function in an AVSI file in AviSynth's plugins folder the script can be reduced to:

    Code:
    AviSource("Menace.avi") 
    SlowMoAt(427, 429,  0.01) # start, end, speed
    You just open the script in an editor or encoder that supports AviSynth, like VirtualDub2, and encode.

    SlowMoAt.AVSI:
    Code:
    function SlowMoAt(clip v, int start, int end, float speed)
    {
    	# start slow motion at frame #start
    	# continue until frame# end (inclusive)
    	# slow that section to desired speed
    
    	p1 = Trim(v, 0, start-1)
    	p2 = Trim(v, start, end).AssumeFPS(speed, sync_audio=true).ResampleAudio(v.AudioRate).ConvertFPS(v.framerate)
    	p3 = Trim(v, end+1, 0)
    
    	p1++p2++p3
    }
    Image Attached Files
    Quote Quote  
  16. Member
    Join Date
    Aug 2021
    Location
    Sweden
    Search Comp PM
    First, thank you for trying to help me but I don’t understand anything of what you wrote. It is clear to me that I must understand the lines you have wrote or else I can’t do the changes I want. This was just an example video. In the next video I maybe want it to go faster or cut it in 10 parts instead of 3 with some parts going faster and some slower and none of them with the same frame rate as the following part. To do that I must understand every one of the programming lines.

    The truth is, I have no programming skills at all. Absolutely none.

    I downloaded AviSynth and installed it and read the example scripts but I didn’t understand any of it. I have also watched some clips at youtube about AviSynth but that didn’t help me either.
    But what I do have learned about this is that it will probably take me several weeks or a few months before I have learned so much about script that I can do these changes on my own.
    Is there really no other way to solve this problem?
    Quote Quote