Suddenly, the videos in most RenPy games are stuck in one second loops

Serpico1616

Newbie
Dec 22, 2018
27
20
Title says it all and I cannot seem to find anyone else (on google) that is having this problem.
About two weeks ago, I noticed that whenever a video plays in a renpy game, it "loops" about every second and lasts for the duration of how long the video is supposed to play for.
This happens for fresh installed or old games. With or without "unren". On an SSD or HDD.
Newest drivers installed, windows updated.
The only thing I have changed in this comp recently was moving the page file from one ssd to another, I can't imagine that being the issue but I've run out of ideas.
If I extract the WEBM video file from the game, and play it on VLC, it works fine.
These games have all worked without issue for years until now.

ANYONE HAVE ANY IDEAS???
 

Meaning Less

Engaged Member
Sep 13, 2016
3,539
7,178
I've seen a few threads about it, here and here. But none of them seemed to find a solution or if they did they never mentioned it (aside from a clean windows install).
 

Serpico1616

Newbie
Dec 22, 2018
27
20
Thanks for the links, I couldn't find them when I looked lol
Yeah no solutions yet, but some of the guys were even having issues months ago.
I just don't understand what could have changed... when nothing at all has changed.
 

desmosome

Conversation Conqueror
Sep 5, 2018
6,344
14,552
Ok I fixed the issue. It was a soundcard setting of all things. Apparently having the audio quality set to 384khz something in renpy to lose it's mind lol. Hopefully this works for others!

How do I mark this as SOLVED?
Can you explain how you fixed it?
 

Serpico1616

Newbie
Dec 22, 2018
27
20
Can you explain how you fixed it?
My soundcard has a setting to change the audio quality and it goes up to 384khz. Lowering it to 192khz fixed the problem.
I changed it through the sound cards control panel but I just checked, you can do it through Windows too.
Go to the Control Panel, then click Sound. Find your output device in the list and right click on it and select Properties.
A new window will pop up, click on the Advanced tab. You'll then see what quality it's set at. Pick anything that isn't 384khz.

Most integrated sound cards wont have the option to go that high unless you spent some money and there is no reason it would ever default to that setting either. Let me know if any of that helps.
 

desmosome

Conversation Conqueror
Sep 5, 2018
6,344
14,552
My soundcard has a setting to change the audio quality and it goes up to 384khz. Lowering it to 192khz fixed the problem.
I changed it through the sound cards control panel but I just checked, you can do it through Windows too.
Go to the Control Panel, then click Sound. Find your output device in the list and right click on it and select Properties.
A new window will pop up, click on the Advanced tab. You'll then see what quality it's set at. Pick anything that isn't 384khz.

Most integrated sound cards wont have the option to go that high unless you spent some money and there is no reason it would ever default to that setting either. Let me know if any of that helps.
My laptop has an integrated audio and realtek. I believe realtek is being used by default. The only place I can find anything with khz settings is in general speaker properties rather than a specific window for the sound card. The speaker properties only had a few options between 44100 and 48000 Hz in 16 and 24 bits. None of those options seemed to work. I'm not sure if my issue is really the audio, but I'll try to look into a bit more.

When I try to open realtek audio manager, it's not opening. The drivers are saying it's the latest version, so I'm not sure what's the deal. I mean, the drivers are from 2018, but when I do search for new update, it says best driver is installed. If I manually download the latest driver from the microsoft update catalog, it still says my current 2018 driver is the best one.

I don't have any audio issues, so it's kind of a pain in the ass to troubleshoot this angle when I'm not sure if it's the problem to begin with. I mean, my highest bit rate is 48 khz lol.

Edit:
I have a problem with lagging videos, rather than looping issue. And only on some specific renpy games. So it might be a different case. It plays fine if I unpack it and run in VLC, but in the renpy game, it's super laggy and skipping most of the frames.
 
Last edited:

Serpico1616

Newbie
Dec 22, 2018
27
20
Yes those are the same settings as the ones I was talking about and any of those options are the most common and would work. It doesn't sound like we are having the same issue, although you haven't mentioned what problem you were having.
 

desmosome

Conversation Conqueror
Sep 5, 2018
6,344
14,552
Yes those are the same settings as the ones I was talking about and any of those options are the most common and would work. It doesn't sound like we are having the same issue, although you haven't mentioned what problem you were having.
Was late with the edit.

I have a problem with lagging videos, rather than looping issue. And only on some specific renpy games. So it might be a different case. It plays fine if I unpack it and run in VLC, but in the renpy game, it's super laggy and skipping most of the frames.
 

Serpico1616

Newbie
Dec 22, 2018
27
20
Yeah different issue, mine was more to do with ren'py and audio codecs, at least I think.
Something maybe worth isolating is which videos file types are causing you the lag.
A lot of games use .WEBM or .AVI, or both I guess.
Maybe you can narrow down what the problem is you find out which file type is the problematic one. Unless it's both, but that helps too.
Also see if the size or length of the video file has anything to do with it.
 
  • Like
Reactions: desmosome

desmosome

Conversation Conqueror
Sep 5, 2018
6,344
14,552
Yeah different issue, mine was more to do with ren'py and audio codecs, at least I think.
Something maybe worth isolating is which videos file types are causing you the lag.
A lot of games use .WEBM or .AVI, or both I guess.
Maybe you can narrow down what the problem is you find out which file type is the problematic one. Unless it's both, but that helps too.
Also see if the size or length of the video file has anything to do with it.
It was webm, but I've had some lag before on other games which I'm not sure what the file type was. Also, I'm positive that not all games using webm lag.

I'm just wondering what it is about renpy that causes videos to lag on some games.
 

Serpico1616

Newbie
Dec 22, 2018
27
20
Remember that outside of the game, videos need to be unpacked before they are played.
But when you are playing the game, it loads that whole archive or image file into the RAM so if you only have like 4gb of RAM, that could be an issue. Or check to see if your page file is set correctly. That would be my first guess.
I'm also certainly no expert on how these games work.
 

desmosome

Conversation Conqueror
Sep 5, 2018
6,344
14,552
Remember that outside of the game, videos need to be unpacked before they are played.
But when you are playing the game, it loads that whole archive or image file into the RAM so if you only have like 4gb of RAM, that could be an issue. Or check to see if your page file is set correctly. That would be my first guess.
I'm also certainly no expert on how these games work.
If its an issue with ram, would unpacking the archive help? I mean, I tried it and it still lagged the same. Plus, I tried the compressed game which is only like 300 MB and it lagged the same way too.
 

Winterfire

Forum Fanatic
Respected User
Game Developer
Sep 27, 2018
5,497
8,035
If its an issue with ram, would unpacking the archive help? I mean, I tried it and it still lagged the same. Plus, I tried the compressed game which is only like 300 MB and it lagged the same way too.
Unpacking would help slightly if you have a hdd instead of a ssd. Not in a noticeable amount I'd bet.

As for compressed games... That won't matter. Compressed is only "good" for size and distribution if you got bad internet, but not really. I am against third party compressions because, from my experience, there's a good chance they will break webm so you'll end up wasting your time and redownloading the not compressed version anyways. I'd avoid.

When it comes to RAM, compression/size does not matter, width and height does.