Movies extremely fast

Discuss how to use the Ren'Py engine to create visual novels and story-based games. New releases are announced in this section.
Forum rules
This is the right place for Ren'Py help. Please ask one question per thread, use a descriptive subject like 'NotFound error in option.rpy' , and include all the relevant information - especially any relevant code and traceback messages. Use the code tag to format scripts.
Post Reply
Message
Author
SaladDressing
Regular
Posts: 27
Joined: Mon Sep 17, 2018 1:43 pm
Contact:

Movies extremely fast

#1 Post by SaladDressing »

Hello everyone,
so I added two little movies to my project, both with 60 fps. The first goes 0.6s and the second 0.25s.

Code: Select all

$ renpy.movie_cutscene("crash_1.mp4")
show img-13
"FUUUUUUUUUCK!!!!"
$ renpy.movie_cutscene("crash_2.mp4")
What now happens is that both movies play extremely fast. They play so fast, that you can't even see them (like showing an image without a pause statement).
What can I do against that?
Thx for your help!

User avatar
Imperf3kt
Lemma-Class Veteran
Posts: 3791
Joined: Mon Dec 14, 2015 5:05 am
itch: Imperf3kt
Location: Your monitor
Contact:

Re: Movies extremely fast

#2 Post by Imperf3kt »

It's probably the length?
0.25 seconds is itself, extremely fast... Almost twice as fast as a human eye blink.
Literally, if you blink, you will miss it.
Warning: May contain trace amounts of gratuitous plot.
pro·gram·mer (noun) An organism capable of converting caffeine into code.

Current project: GGD Mentor

Twitter

SaladDressing
Regular
Posts: 27
Joined: Mon Sep 17, 2018 1:43 pm
Contact:

Re: Movies extremely fast

#3 Post by SaladDressing »

Imperf3kt wrote: Wed Nov 07, 2018 3:00 pm It's probably the length?
0.25 seconds is itself, extremely fast... Almost twice as fast as a human eye blink.
Literally, if you blink, you will miss it.
And what about the second? I don't think you can miss it. Also I watched both movies with a movie player and you clearly notice it.

User avatar
Imperf3kt
Lemma-Class Veteran
Posts: 3791
Joined: Mon Dec 14, 2015 5:05 am
itch: Imperf3kt
Location: Your monitor
Contact:

Re: Movies extremely fast

#4 Post by Imperf3kt »

Can you explain a bit more about "you can't even see them", do they not show at all?
Warning: May contain trace amounts of gratuitous plot.
pro·gram·mer (noun) An organism capable of converting caffeine into code.

Current project: GGD Mentor

Twitter

SaladDressing
Regular
Posts: 27
Joined: Mon Sep 17, 2018 1:43 pm
Contact:

Re: Movies extremely fast

#5 Post by SaladDressing »

Imperf3kt wrote: Thu Nov 08, 2018 1:23 pm Can you explain a bit more about "you can't even see them", do they not show at all?
At the first movie it just skips to the next screen and at the scond it loads for a short amount of time and then the game ends.

User avatar
Imperf3kt
Lemma-Class Veteran
Posts: 3791
Joined: Mon Dec 14, 2015 5:05 am
itch: Imperf3kt
Location: Your monitor
Contact:

Re: Movies extremely fast

#6 Post by Imperf3kt »

Hmm. Can we see the few lines before and after the movies are supposed to play?
If they're just dialogue, you can replace them with gibberish if you aren't comfortable sharing them.
Warning: May contain trace amounts of gratuitous plot.
pro·gram·mer (noun) An organism capable of converting caffeine into code.

Current project: GGD Mentor

Twitter

SaladDressing
Regular
Posts: 27
Joined: Mon Sep 17, 2018 1:43 pm
Contact:

Re: Movies extremely fast

#7 Post by SaladDressing »

Imperf3kt wrote: Thu Nov 08, 2018 4:09 pm Hmm. Can we see the few lines before and after the movies are supposed to play?
If they're just dialogue, you can replace them with gibberish if you aren't comfortable sharing them.
So far I have only this. (It was supposee to be a test)

Code: Select all

label start:
      show start_1
      pause
      show start_2
      pause
      show start_3
      pause
      $ renpy.movie_cutscene("crash_1.mp4")
      show img-13
      "FUUUUUUUUUCK!!!!"
      $ renpy.movie_cutscene("crash_2.mp4")
      return

SaladDressing
Regular
Posts: 27
Joined: Mon Sep 17, 2018 1:43 pm
Contact:

Re: Movies extremely fast

#8 Post by SaladDressing »

SaladDressing wrote: Thu Nov 08, 2018 5:42 pm
Imperf3kt wrote: Thu Nov 08, 2018 4:09 pm Hmm. Can we see the few lines before and after the movies are supposed to play?
If they're just dialogue, you can replace them with gibberish if you aren't comfortable sharing them.
So far I have only this. (It was supposee to be a test)

Code: Select all

label start:
      show start_1
      pause
      show start_2
      pause
      show start_3
      pause
      $ renpy.movie_cutscene("crash_1.mp4")
      show img-13
      "FUUUUUUUUUCK!!!!"
      $ renpy.movie_cutscene("crash_2.mp4")
      return
I found out that renpy is skipping these movies.
I tried another video format (.webm) and this works, but extremely laggy and the quality is awful.
Any ideas?

User avatar
Imperf3kt
Lemma-Class Veteran
Posts: 3791
Joined: Mon Dec 14, 2015 5:05 am
itch: Imperf3kt
Location: Your monitor
Contact:

Re: Movies extremely fast

#9 Post by Imperf3kt »

How did you convert the files? Are they laggy and low quality in other media players?

Sorry about not replying, as you found, MP4 files aren't supported.
Warning: May contain trace amounts of gratuitous plot.
pro·gram·mer (noun) An organism capable of converting caffeine into code.

Current project: GGD Mentor

Twitter

SaladDressing
Regular
Posts: 27
Joined: Mon Sep 17, 2018 1:43 pm
Contact:

Re: Movies extremely fast

#10 Post by SaladDressing »

Imperf3kt wrote: Sun Nov 11, 2018 2:00 pm How did you convert the files? Are they laggy and low quality in other media players?

Sorry about not replying, as you found, MP4 files aren't supported.
I found out I was using the wrong codecs. I tried to convert the videos with video editing software and video converter. But everytime I convert to .webm the last few frames are missing. I tried it with a lot of different software but it is always the same. So I moved on to .ogg where the quality is quite good if you lower the compression, but it isn't displayed in renpy, even with the right codec, or it is laggy/shows green stripes while playing the movie. I also tried mp4 with the xvid codec which is compatible with renpy but this one is also not displayed in renpy.

To your question: The movies are just fine in media players.

User avatar
trooper6
Lemma-Class Veteran
Posts: 3712
Joined: Sat Jul 09, 2011 10:33 pm
Projects: A Close Shave
Location: Medford, MA
Contact:

Re: Movies extremely fast

#11 Post by trooper6 »

Note: the video must have an audio track...that track can be blank, but there has to be an audio track.
A Close Shave:
*Last Thing Done (Aug 17): Finished coding emotions and camera for 4/10 main labels.
*Currently Doing: Coding of emotions and camera for the labels--On 5/10
*First Next thing to do: Code in all CG and special animation stuff
*Next Next thing to do: Set up film animation
*Other Thing to Do: Do SFX and Score (maybe think about eye blinks?)
Check out My Clock Cookbook Recipe: http://lemmasoft.renai.us/forums/viewto ... 51&t=21978

User avatar
Imperf3kt
Lemma-Class Veteran
Posts: 3791
Joined: Mon Dec 14, 2015 5:05 am
itch: Imperf3kt
Location: Your monitor
Contact:

Re: Movies extremely fast

#12 Post by Imperf3kt »

MP4 is not supported... Even if you use XVID inside it.
Please look here for all supported formats.
https://www.renpy.org/doc/html/movie.html

For various reasons, other formats may work or seem to work, but in such cases it is only coincidental and things might stop working at any time for any reason.


Personally, I suggest vp9 in a matroska (.mkv) container with a blank.ogg audio track.


Note: MPEG-4 part 2, is AVI
MPEG-4 part 10 is MP4 and licensed (not free/profoundly expensive - up to 9.75 million dollars per year!!! )
http://www.mpegla.com/main/programs/AVC ... ement.aspx
http://www.mpegla.com/main/programs/AVC ... avcweb.pdf
Warning: May contain trace amounts of gratuitous plot.
pro·gram·mer (noun) An organism capable of converting caffeine into code.

Current project: GGD Mentor

Twitter

SaladDressing
Regular
Posts: 27
Joined: Mon Sep 17, 2018 1:43 pm
Contact:

Re: Movies extremely fast

#13 Post by SaladDressing »

Imperf3kt wrote: Sun Nov 11, 2018 7:06 pm MP4 is not supported... Even if you use XVID inside it.
Please look here for all supported formats.
https://www.renpy.org/doc/html/movie.html

For various reasons, other formats may work or seem to work, but in such cases it is only coincidental and things might stop working at any time for any reason.


Personally, I suggest vp9 in a matroska (.mkv) container with a blank.ogg audio track.


Note: MPEG-4 part 2, is AVI
MPEG-4 part 10 is MP4 and licensed (not free/profoundly expensive - up to 9.75 million dollars per year!!! )
http://www.mpegla.com/main/programs/AVC ... ement.aspx
http://www.mpegla.com/main/programs/AVC ... avcweb.pdf
Ohhh I understand no. Thank you for the help!
trooper6 wrote: Sun Nov 11, 2018 6:03 pm Note: the video must have an audio track...that track can be blank, but there has to be an audio track.
That might be the problem. I always cleared the audio track. I'll try converting the videos now using ffmpeg.

SaladDressing
Regular
Posts: 27
Joined: Mon Sep 17, 2018 1:43 pm
Contact:

Re: Movies extremely fast

#14 Post by SaladDressing »

I've been able to convert the videos with ffmpeg to .webm using vp8 and vorbis. Anyways, the last few frames are missing. I also tried other software but always the same frames at the end of the movies are missing. Any idea why?
Renpy plays the movies just fine

User avatar
Imperf3kt
Lemma-Class Veteran
Posts: 3791
Joined: Mon Dec 14, 2015 5:05 am
itch: Imperf3kt
Location: Your monitor
Contact:

Re: Movies extremely fast

#15 Post by Imperf3kt »

Are the frames missing in other media players?
Can you install a program called "media info" and open the files with it, copying the data it gives as text? (text output isn't the default, you'll have to set it as such)

It should look something like this:
ID : 1
Format : VP9
Codec ID : V_VP9
Duration : 5mn 12s
Width : 312 pixels
Height : 240 pixels
Display aspect ratio : 4:3
Frame rate mode : Constant
Frame rate : 30.000 fps
Default : Yes
Forced : No

Audio
ID : 2
Format : Opus
Codec ID : A_OPUS
Duration : 5mn 12s
Channel(s) : 2 channels
Channel positions : Front: L R
Sampling rate : 48.0 KHz
Compression mode : Lossy
Title : Stereo
Default : Yes
Forced : No
Warning: May contain trace amounts of gratuitous plot.
pro·gram·mer (noun) An organism capable of converting caffeine into code.

Current project: GGD Mentor

Twitter

Post Reply

Who is online

Users browsing this forum: Ahrefs [Bot], decocloud