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

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