manim-sideview icon indicating copy to clipboard operation
manim-sideview copied to clipboard

Manim Video Generation Issues: Frame Rate Errors, Preview Stalling, and Incorrect Duration Recognition

Open LuluTimDou opened this issue 10 months ago • 2 comments

Problem Description: Hello sideview, I'm encountering some issues while generating videos with Manim in VSCode, and I hope to find a solution here.

Background: I've been using Manim to generate videos in VSCode, and everything was working perfectly fine initially. The animations were smooth, and the previews in VSCode were functioning correctly. Today, I suddenly started experiencing problems, even though I haven't manually modified any configuration files or made any changes to the settings.

System:Windows 11 Python version: 3.13.2 Manim version: Manim Community v0.19.0 FFmpeg version: N-118448-g43be8d0728-20250208 built with gcc 14.2.0 (crosstool-NG 1.26.0.120_4d36f27)

Specific Issues: VSCode Preview Stalling: When previewing animations in VSCode, the animations fail to play smoothly and stall halfway through.

Frame Rate Issues: When playing the generated videos with PotPlayer, videos intended to be at 60fps are being played at 15fps, causing the animations to appear much slower. PotPlayer is unable to correctly recognize the video duration. The progress bar finishes, but the video continues to play.

Manually Setting Frame Rate: If I manually set the frame rate to 15fps in the code, the generated videos play correctly, and PotPlayer can accurately recognize the video length. However, the preview in VSCode still stalls.

Attempts to Resolve the Issue: I have reinstalled VSCode, Manim, and FFmpeg, but the problem persists. I haven't modified any configuration files or made any manual adjustments.

Key Points: Everything was working fine before today. The issues started today without any manual modifications to configuration files. I hope that members of the Manim community can help me analyze the possible causes of this problem and provide some solutions. Thank you very much for your assistance!

I just test this code, the video should last 4 sec

from manim import *

class SomeAnimations(Scene):

    def construct(self):

        square = Square()

        self.play(FadeIn(square))

        self.play(Rotate(square, PI/4))

        self.play(FadeOut(square))

        self.play(Wait())

LuluTimDou avatar Feb 11 '25 14:02 LuluTimDou

This is the original video you uploaded to the Discord server. It is exactly 4 seconds long and plays fine in all players, including a freshly installed PotPlayer on my computer (Windows 10). There is nothing wrong with the file as far as I can tell.

https://github.com/user-attachments/assets/cffe6967-5478-4e2a-9336-c086e1b0b1dd

uwezi avatar Feb 11 '25 17:02 uwezi

Hi @LuluTimDou does this still appear to be an issue?

Rickaym avatar Jul 24 '25 03:07 Rickaym