Join the discussion
Write your take first — we'll ask for email only when you're ready to publish.
- Hacker News
- Blocked because I don't use cookies. Ok, I've always preferred mpv anyway.by ekjhgkejhgk
- Why do you do this to yourself?by xena
- I've 3rd party cookies blocked and it works just fine. Have you disabled all cookies?!by nisiddharth
- I wish Unity's built-in videoplayer wasn't such a disappointment. The performance on Windows is god awful. Have had to write a mass video reference recompressor/in-scene replacer that just attempts to pick the best compression flags and reduces resolution just avoid dropping frames playing ~1080p videos on multi-core PC's with discrete GPU's. Mac was fine playing even the overly high res original footage, high 2000+ pixel portrait tutorial videos.
Wrote a proper double-buffering video/audio player in Unity using parts of an ffmpeg wrapper over ten years ago. Seems silly they never did anything similar officially, just used lackluster platform API's.
by maxlin - Completely agree! Unfortunately this is the Unity MO.
A tool that's a bit half baked.
They have been doing a hell of a lot better lately though.
by thsbrown - Sidenote:
Video game programming with unity was an absolute nightmare to try and get working with any kind of gitops and or with multiple people working on the same code base a couple of years ago
Wonder if that changed ?
by happyPersonR - They acquired Plastic SCM around 2020 and I believe they integrated it into the engine, but that was shortly after I stopped using Unityby 1bpp
- Unity native files are still pretty much a nightmare to merge. With that said I find it's not too hard to break things up in a way that multiple people can work on separate pieces of the game so the actual files don't need to be merged.
While plasticSCM has come a long way, I still find it a bit buggy and hard to work around. I miss the more advanced features of git.
by thsbrown - I don't know why, but on windows, the first time I start VLC after a windows boot, it takes about 5s to 8s to open a video file, any sort of video file
I suspect it's a graphics driver issue, or something else
by jokoon - It's caused by a stale plugin cache, which somehow triggers a blocking windows defender scan on application launch.
I only managed to figure that out thanks to this[1] reddit comment, which also includes a solution:
No windows defender exclusion required.Noticed this a while back with 3.0.23. Managed to troubleshoot via debug logs. Basically the plugin cache goes stale and has to rebuild itself every first launch. No clue why. To fix: go to C:\Program Files\VideoLAN\VLC (or wherever you installed) with a terminal in administrator mode. run the command: ./vlc-cache-gen.exe "C:\Program Files\VideoLAN\VLC\plugins" That will rebuild the plugins.dat file which should fix it.[1]: https://old.reddit.com/r/VLC/comments/1skofwx/vlc_3023_windo...
by krono - Forgive me for my ignorance - but my understanding is that VLC is a frontend for ffmpeg, and even ffmpeg is 'just' a wrapper for hardware video decoders such as NVDEC when viewing supported codecs, like h264/5.by torginus
- My understanding is that VLC and FFMpeg are both projects which develop in house codecs and also incorporate codecs developed by third parties.by mastax
- Just in case you only read the headline and were confused, this is libVLC which underpins the VLC player.by bananaboy
- VRChat folks will love this. Videoplayers are embedded into Unity scenes aka "maps" as a regular imported lib. The videoplayer is a drawn surface where users can see video playback. Most commonly used for streaming live music from a stream like Twitch.by hparadiz
- Can a unity dev/game dev help elucidate why you'd use vlc in unity?
For cutscene playback?
by fusslo - Unity video player leaves a lot to be desired.
The standout option for a more elaborate video handling was typically AVPro. It's a really good option, with that said with vlc stepping up hopefully it's no longer strictly necessary.
by thsbrown - RTSP support, twitch-style in-game visio, any kind of non-game Unity apps (there are many), 360 video playback, mediaplayer in VR headset, simulators of all kinds, etc..by martz
- Unity includes its own video player implementation ( https://docs.unity3d.com/Manual/Video.html ), so presumably you'd mainly want to use VLC for wider range of supported codecs?by csande17
- For a sandbox game this is very useful, where you can spawn video players in-game. For social games (like VRChat) this is also great since synced video playback is a very popular feature for people to watch content together in VR.by harrisoned
- To everybody else being confused: This is about Unity the game engine, not Unity the desktop environment.by Hendrikto
- Unity (the DE) was discontinued 9 years ago..by tokai
- Recently added support for Linux to VLC for Unity, with full hardware decoding.
It uses OpenGL rendering through GLX and EGL, with DMA-BUF texture sharing to pass video frames efficiently to Unity’s renderer.
Only x86_64 is supported at this time. In the future, I will add ARM64 support as well as Vulkan.
by martz - Thank you very much.by SurajMishra
- Would it not be more efficient to create the decoder in-process, then you could feed it the bitstream via a compute buffer, and the video would be rendered to a texture.by torginus
- Don't forget to build 'correct' ELF64 binaries for broad elf(glibc)/linux distro support (-static-libgcc -static-libstdc++, and tight glibc ABI version control with binutils VERSION scripts).
At least those build options should be default.
by sylware - On a similar note: Godot VLC (<https://github.com/xiSage/godot-vlc>), because let's not pretend we don't remember the Unity terms change controversy.by tmtvl
- yes this is good too, actually started contributing to this :)by martz
- Context about the Unity terms change controversy: https://www.gamedeveloper.com/business/unity-is-killing-its-...
> Initially, the Runtime Fee sought to charge developers a per install tariff once projects had passed certain milestones. It was a decision that left many users reeling, resulting in a colossal backlash (…)
How users reacted: https://old.reddit.com/r/OutOfTheLoop/comments/16h9lnw/whats...
> Any install, any reinstall, any installation on a second device, each and every one slap the dev with a fee. It gets dumber, because that cracked copy of your game on the high seas still incurs a fee when the pirate installs it. You might think we're at peak stupidity. You might think anyone who makes anything with Unity is a "fucking idiot" (the CEO certainly does), but we're not done yet. It's retroactive. (…)
by thih9