Open dongle opened 6 years ago
I'm also having issues with the VideoPlayer component playing too slowly. I'm rendering a 360 scene, but inside that scene there is a VideoPlayer component playing on a 2D TV screen.
I'm using GenericFrameRecorder's latest version on this repo as of now (0fffbdaa6a505271ead2acf977a9d0509192589d). I'm in Unity 2018.1.0f2
@dongle Did you ever figure out a fix?
I never figured out a fix. I wound up running the project while screencapturing it which worked well-enough in this case but limits me for future projects.
That's a decent hack. And now I'm wondering if my solution will be to create an game window output mimicking 360 video capture. Terrifying, but it might be my only option.
Hi, I have the same problem and the same request. As I see it, the VideoPlayer outputs the video in realtime but the GenericFrameRecorder takes longer/shorter to render a frame thus resulting in lagging or sped up image sequences. I imagine that the videoplayer needs a function which scales the time accordingly. I want to record a 360° stereoscopic video and it's nearly impossible to get the videos inside the scene and the recorded endresult to the same speed... Any fix?
I wrote a piece of code on a video object that pauses the playing video, then manually increments a frame each time a frame is rendered in Unity.
void Update() {
...
if (kioskVideoPlayer.isActiveAndEnabled) {
kioskVideoPlayer.Pause();
kioskVideoPlayer.StepForward();
}
}
Great solution! Works well for me
Sorry to add to this post 2 years later, but running into this issue. The code to manually increment each frame works well, only now I've lost the ability to loop the video. Simply adding videoPlayer.isLooping doesn't quite work since it will only loop once .Play() has been called (or so it would seem). Was just taking shots in the dark and added .Play() after .StepForward() hoping that it would trigger the loop function on the last frame, and it did, however once it loops it plays at the wrong speed again.
Thought I could manually reset the frames as well however I'm a bit confused by the frame and frame count using long/ulong to store their values. If anyone has any guidance on a fix for this it'd be greatly appreciated! Again sorry to dig up an old thread, hopefully it might help someone else as well.
For everybody interested in network synced/manually-driven video playback: http://u3d.as/2KgC
I wrote a piece of code on a video object that pauses the playing video, then manually increments a frame each time a frame is rendered in Unity.
void Update() { ... if (kioskVideoPlayer.isActiveAndEnabled) { kioskVideoPlayer.Pause(); kioskVideoPlayer.StepForward(); } }
You saved my life, my job, and my mental health. Thank you s2
What happened?
I have a unity scene with a gameobject with a videoplayer component. In the editor and the standalone player, the video plays at the correct speed. (Eg, it is a nine minute video and it plays for nine minutes from start to finish.) When using the recorder with 30fps constant settings, the video is over around the 5500th frame (it should fill the entire span of 16200 frames for a 540 second recording).
Is it reproduceable?
Yes – tried with several videos.
Released package version / tag?
0.2 from Asset Store
Unity version, operating system, target platform (standalone windows, mac, iOS, PS4...)?
Unity 2018.1f