1

I have a video with these specifications:

  • 4320x2160p
  • 60 fps
  • 20.0 Mb/s bitrate
  • AVC format (x264)

Since my smartphone can play videos up to 30 fps at that resolution, I need a fast way to reduce the frame rate to 30 fps without changing any other aspect (same bitrate, same duration).

Is there a way to do this without re-encoding the entire video?

7
  • Unlikely, because keyframes will change. Video draws the changes between keyframes, not the entire frame, so to reduce the frame count would mean some data would be missing.
    – Tetsujin
    Commented Sep 29, 2021 at 18:20
  • Please consider if you really need to convert your video. This is a typical task that should be done during decoding. The avisynth framework might have such a playback feature as the solution for your problem only consists of dropping the drawing of every second frame.
    – r2d3
    Commented Sep 29, 2021 at 18:36
  • @r2d3 I need to create a new file containing the video with a lower framerate, because the smartphone that should play the video is not powerful enough to play a 60 FPS video. I tried with another video of the same resolution, same bitrate and 30 FPS and it works perfectly. How can I use avisynth to do what I need?
    – matteof93
    Commented Sep 29, 2021 at 19:04
  • Please edit your question adding the new info such as what your goal is, or new questions. That way relevant details are available for community members who want to pitch in, without the need of digging them out from comments. Commented Sep 29, 2021 at 19:20
  • matteof93, please update your freshly disclosed requirements as Peregrino69 said. I can't tell you if Avisynth is available on smart phone platforms. Please Avisynth on a regular computer. Avisynth provides many video manipulations on the fly so that you won't have to reencode a video.
    – r2d3
    Commented Sep 29, 2021 at 20:47

1 Answer 1

3

As your smartphone is not able to play a video with 60 frames/second my initial proposal to use Avisynth on a smartphone fails because the frames have to be decoded anyway. That means that there is no other way then to reencode your videos on a computer.

Modern videos rely on saving videos as a series of I-frames, P-frames and B-frames. I-frames, also called keyframes in the commentaries to your question contain full pictures. P (like "predictive") contain difference information with regards to preceding frames. B-frames are bidirectional. This is the only known way to achieve the desired storage reduction. Your goal can only achieved by decoding all frames, even those that you want to drop because those frames serve as reference for difference information to calculate other frames. This series has to be reencoded then.

If your question is about self-recorded videos instead of other ones that are already highly compressed you would need a camera that allows you to choose a format that only records I-frames. That comes at a cost of increased storage space. I-frames are completely independent of another. Starting from there you would save the decoding processing time and simple encode every second frame into a new video. The new video would be either computationally cheap by just containing every second I-frame or you would reencode your source into something like h264. That would cost you processing time but save you storage space for the final result.

There is no escape for you from that universe of computation time against storage space where you live in.

2
  • Thank you so much for the explanation!
    – matteof93
    Commented Sep 29, 2021 at 21:05
  • I am happy that you appreciate it. :)
    – r2d3
    Commented Sep 29, 2021 at 21:19

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .