Hello Ventuzians!
THE FORUMS ARE CLOSED!

Please join our discord server HERE!! << click me :D

We are shutting our Ventuz Forum, but don't worry, it will all be archived for you to search in if you have a query. From now on, please add all your comments, questions or observations into our Discord Server

Thanks for the great time - see you on discord!!
Dee, Karol, Daniel and the whoooole Product and Support team!

Movie Clip Buffer

Please report bugs in this group. We will maybe populate a list of known bugs with a possibly modified description at a later time.

Moderator: Support

Post Reply
chriss0212
Posts: 666
Joined: 18 Jan 2012, 20:56
Location: wuppertal
Contact:

Movie Clip Buffer

Post by chriss0212 » 23 May 2016, 16:22

Hi,

i have a movie clip playing an *mp4 file. It is configured to loop and have a buffer of 200 frames. When it comes to the loop the buffer jumps from 200 to 0 and needs to fill up again. Wouldn't it be more sense full, if the buffer starts to cache frames starting at 0 200 frames before the loop point comes? Problem is not only Buffer runs out also cpu goes up on the looping point.

greets

christian

User avatar
Götz_B
Posts: 180
Joined: 21 May 2013, 13:01

Re: Movie Clip Buffer

Post by Götz_B » 24 May 2016, 09:38

Im sure we optimized exactly that in V4 already. :?
Lets doublecheck...

User avatar
Dierk Ohlerich
Posts: 74
Joined: 10 Jul 2012, 09:01
Location: Hamburg, Germany

Re: Movie Clip Buffer

Post by Dierk Ohlerich » 24 May 2016, 10:55

Assuming nothing weird happens, the movie clip node does prebuffer the loop-start-point, but this is not visualized. then it will start decoding from were the prebuffered loop point ends, and this is visualized in the performance statistics.

There are many reasons for a spike in CPU. First the cpu stops decoding when the last frame has been decoded, and then does no decoding until the buffer is used up and the last frame is displayed. When the loop-point is reached all free cpu time will be used to decode the frames after the loop as fast as possible - spiking the CPU. This should not be a problem because in the end the CPU does not more work as if the loop was not present.

If you have long group-of-pictures (GOP), something really bad can happen. Imagine 10 buffers and 30 GOP. Then the first 10 frames after the loop-start-point. As soon as the loop jumps back, the 10 buffers will be played back. Decoding starts at frame 10, but since the GOP is 30 the decoder jumps to the start of the GOP (frame 0) and decodes the same 10 frames that are in the loop buffer - more work is done as if the loop was not present and the CPU spike is a problem. Solution: more prebuffer.

-- Dierk
-- Dierk Ohlerich

chriss0212
Posts: 666
Joined: 18 Jan 2012, 20:56
Location: wuppertal
Contact:

Re: Movie Clip Buffer

Post by chriss0212 » 25 May 2016, 08:41

Hi Dierk,
There are many reasons for a spike in CPU. First the cpu stops decoding when the last frame has been decoded, and then does no decoding until the buffer is used up and the last frame is displayed. When the loop-point is reached all free cpu time will be used to decode the frames after the loop as fast as possible - spiking the CPU. This should not be a problem because in the end the CPU does not more work as if the loop was not present.
If i understand it correct:
i Have a Movie lets say 500 frames and i buffer 100 frames.

If the movie is running it has bufferd 100 frames and "some" frames for the loop start. if i rech frame 400 the movie node is just using the buffer until it is empty at frame 500...and on the looping point it jumps to frame number 0 use the (don't know how many) prbuffered frames and in the samte time the movie node is loading and decoding the difference from the pre buffered frames to frame 100?

for me this makes not realy sense because hi have realy big spikes in the cpu power at this moment!

for me it would make sense always prebuffer next 100 frames. what means if the movie is on frame 410 frames 0-9 are already prebuffered and decoded and on 450 frames 0-49 are already buffered and decoded. for my understanding there would be no spike.

greets

christian

sandercox
Posts: 46
Joined: 06 Feb 2015, 09:42

Re: Movie Clip Buffer

Post by sandercox » 31 May 2016, 09:10

My expectations of the behavior would be the same as Christian. The buffer is just filled with the number frames it needs next (if set to only forward buffer) or divide that between a backward buffer and a forward buffer. Maybe behavior could be different when loop flag is not set on the movie but not sure if that would be really expected.

Post Reply