Posted: 20th Jan 2018 6:36
Can we add seamless looping to the PlayVideo() stuff?

Here is a loop-able video for testing:
https://www.videezy.com/backgrounds/5046-bright-glass-4k-motion-background-loop
Posted: 7th Feb 2022 21:37
Just wanted to bump this request. Can we get seamless video looping?

I've tried doing it manually, but was unable to do so without the playback stuttering.
Posted: 9th Feb 2022 2:48
Sorry not aware of any commands that can help, have you tried a different format for the video? I myself am right now using WMV for windows but that may not be best...
Posted: 9th Feb 2022 22:17
This actually works for me, I get a completely seemless loop:

+ Code Snippet
LoadVideo("Bright_Glass_4K_Motion_Background_Loop.mp4")

do
	PlayVideo()
	Sync()
loop


You could add controls like this:
+ Code Snippet
LoadVideo("Bright_Glass_4K_Motion_Background_Loop.mp4")

global loop

function PlayLoop()
	loop= 1
endfunction

function StopLoop()
	loop=0
endfunction

do
	if loop
		PlayVideo()
	endif
	
	Sync()
loop
Posted: 14th Feb 2022 1:19
can play outside the main loop and sleep gives it time to acess and play the file or it can exit before it sarts if it takes a second to play
+ Code Snippet
playvideo()
	sleep(10)
	a=1
	while a=1
		if GetVideoPlaying(num)=0
			a=2
		endif
		sync()
	endwhile
endfunction 
Posted: 19th May 2022 5:25
Interesting, just putting PlayVideo() or PlayVideoToImage() in the loop does appear to make it loop seamlessly. And here I was trying to detect when the video had ended and playing again.

EDIT: Upon further testing, there is still a bit of a stutter.

However, is spamming PlayVideo() every frame really ideal? Will this not cause any issues?