“hujiajun” ab7739e41e 增加自动化脚本 2 mesiacov pred
..
Editor ab7739e41e 增加自动化脚本 2 mesiacov pred
Plugins ab7739e41e 增加自动化脚本 2 mesiacov pred
Runtime ab7739e41e 增加自动化脚本 2 mesiacov pred
Samples~ ab7739e41e 增加自动化脚本 2 mesiacov pred
UI ab7739e41e 增加自动化脚本 2 mesiacov pred
CHANGELOG.md ab7739e41e 增加自动化脚本 2 mesiacov pred
CHANGELOG.md.meta ab7739e41e 增加自动化脚本 2 mesiacov pred
Editor.meta ab7739e41e 增加自动化脚本 2 mesiacov pred
LICENSE.md ab7739e41e 增加自动化脚本 2 mesiacov pred
LICENSE.md.meta ab7739e41e 增加自动化脚本 2 mesiacov pred
Plugins.meta ab7739e41e 增加自动化脚本 2 mesiacov pred
README.md ab7739e41e 增加自动化脚本 2 mesiacov pred
README.md.meta ab7739e41e 增加自动化脚本 2 mesiacov pred
Runtime.meta ab7739e41e 增加自动化脚本 2 mesiacov pred
UI.meta ab7739e41e 增加自动化脚本 2 mesiacov pred
UnityVideoRenderTexture.renderTexture ab7739e41e 增加自动化脚本 2 mesiacov pred
UnityVideoRenderTexture.renderTexture.meta ab7739e41e 增加自动化脚本 2 mesiacov pred
package.json ab7739e41e 增加自动化脚本 2 mesiacov pred
package.json.meta ab7739e41e 增加自动化脚本 2 mesiacov pred

README.md

Unity Web Video Player

npm version

A video player plugin for Unity WebGL applications. Unity's builtin VideoPlayer can struggle to work with WebGL builds especially on mobile browsers. This package uses Web-native video elements to read the video source and exposes basic video controls to Unity. You can use video URLs either from StreamingAssets path or web servers (permissing CORS). While minimal, the plugin aims to be a complete video player for web across browsers and platforms. Key features include:

  • Start, Stop, Pause, Resume, (Un)Mute, APIs along with respective callback events.
  • Resampling of source video texture to preserve aspect ratio or arbitrarly stretch to match target texture size.
  • Fetch and set video player timestamps.
  • Supports both in-built and scriptable rendering pipeline.

Importing in Unity

To install this package in Unity you'll first have to add a new Scoped Registry. Head over to Edit>Project Settings>Package Manager and add the new registry details as follows -

Name: npmjs
URL: https://registry.npmjs.org
Scope(s): com.nfynt

After this head to Window>Package Manager and select My Registries under the Packages: options. This will list all the available package on npm, find Web Video Player and select the latest version available and hit install 🚀.

Project Demo

Issues

Submit issues on Github Repo with appropriate label as bug\enhancement\help wanted.

Authors

Shubham