Open sirkitree opened 4 years ago
Do you have the Player.log/error.log for these crashes? You should be able to find them at %USERPROFILE%\AppData\Local\Temp\Solirax\NeosVR\Crashes
.
I haven't been able to replicate it yet, but given what I am seeing, I think it's most likely just the standard libVLC crashing that's been an issue for a long time now. The Player.log/error.log would likely confirm this too if you have them.
Unfortunately these crashes are coming from the UMP libVLC wrapper library, so fixing it is out of our hands at the moment, as this library hasn't been updated in a really long while.
Currently I'm waiting on the official libVLCsharp library to get to usable state, so we can swap over to it as our general playback engine, but that's probably still going to take a while: https://code.videolan.org/videolan/vlc-unity
For the time being, I'd strongly recommend re-encoding the videos so the Unity Native playback can be used instead. Using MP4 with H.264 and AAC audio should work well for this.
Thanks! I've switched the engine in-world through the inspector and it seems to be stable.
Would it be possible to have Youtube Dl import perfer the Unity Playback meanwhile? This is an issue for some users currently.
I believe it already does prefer Unity's playback engine where/when it can, @TehTurk. The issue is the Unity playback engine passes off decoding to system codecs, and if it's a file type it can't recognize/process, it'll actually crash Unity, or have other playback issues, e.g. screeching audio as it tries to process nonsense data. So Unity's playback engine can only be used for a very narrow range of codecs where support is near guaranteed. For everthing else, we need to rely on libVLC.
Just to update, I'm planning to switch to the official libVLCsharp library as soon as possible, but we're currently waiting on this fix to go live: https://code.videolan.org/videolan/vlc-unity/-/issues/84
Once that's out that should unblock the integration and I can do the swap (assuming no other problems arise).
That would be good. It's reached the point where I've had to disable all video players in most my worlds now as I and anyone that joins will crash out in a few minutes at most. Oddly enough some worlds are completely unaffected so there seems to be some secondary action that triggers the crash, but nothing immediately stands out as being the cause. I have around 10 crash logs from incidents if they'd be of any use.
The crash logs unfortunately don't help in this case. The UMP library is a binary blob, so I can't make any fixes to it myself and the authors haven't updated it in well over a year, so I think the project is pretty much abandoned now.
From what I could guess, it happens when you have more than one video and with some special condition, the crashes/high CPU usage seems to come from some thread synchronization resources, so it's probably some kind of race condition on shared resources.
Race conditions can be heavily system/situation dependent too. E.g. there was one with UIX that wouldn't affect most people, but would reliably break UIX within seconds for a few users, so we might be dealing with similar case, but without access to source to fix it.
If that issue with the official libVLCsharp was fixed already we'd have swapped already, it's pretty high priority.
It looks like the libvlc fix was already merged upstream: https://code.videolan.org/videolan/vlc/-/commit/850c708678992a21c6111abb9c79135a4dc618cd
Maybe libvlc.dll
and libvlccore.dll
(and associated plugins) just needs to be replaced with the latest build? https://code.videolan.org/videolan/vlc/-/jobs/485768/artifacts/file/nightlies/vlc-4.0.0-dev-win64-2a988cc4.7z
I've tried updating the binaries manually before, but that didn't seem to resolve the issue.
I've noticed that this seems to happen when you try to mix both in one world. If they're all libvc or they're all unity then you last much longer (but do eventually crash).
Taking this one on - some work has already been done, but there's still a good ways to go.
Is there any development on this, and will it support build in subtitles from a mkv file
Working with some new video textures on some mandala meshes, I've had multiple crashes since video handling was changed the other week.
Here are the logs from the last two consecutive crashes:
The general workflow of these sessions:
Here is the video files I am using:
Here is the mesh I am using:
Here is a link to an uploaded world: