Comments (3)
In my very brief experimentation, videos do auto-play on Desktop. Getting videos to play on Mobile is an entirely different beast, as it needs to be tied to a user action directly, or else the browsers ignore it.
from panolens.js.
The videos only autoplay on desktop if I modify your library to set the autoplay parameter. I am aware of the issues on a mobile and have not found a way to prevent the user action, but the control widget satisfies this requirement for me.
I added autoplay to the options parameter in your VideoPanorama constructor as can be seen below to ensure that the videos autoplay on a browser, but would like this added to your original code if possible.
PANOLENS.VideoPanorama.prototype.load = function ( src, options ) {
......
this.videoElement.muted = options.muted || false;
this.videoElement.loop = ( options.loop !== undefined ) ? options.loop : true;
this.videoElement.autoplay = ( options.autoplay !== undefined ) ? options.autoplay : true;
this.videoElement.src = src;
this.videoElement.load();
....
}
from panolens.js.
Good catch! Autoplay option was initially missing because it needs additional event dispatching handler to the control widget. I've added the autoplay support in v2-dev (f285e77) and (f315aee)
from panolens.js.
Related Issues (20)
- Overwrite default ControlBar style
- Video playback without sound HOT 1
- How to move around 3d added in panorama in VR mode
- Blurred image
- viewer.setPanorama shows black in case of cube panorama
- Stitch line visible after texture update
- Panolens offline HOT 2
- Side scrolling and zooming
- How can a script find out which scene is currently loaded? HOT 1
- add logo in README.md for panolens.js
- '@types/panolens@*' is not in this registry. HOT 1
- What is the space model for positioning infospots [ e.g. in .setposition(x,y,z)] HOT 1
- Infospot sink in Panorama. HOW can i fix this?
- Lag on mobile phone
- How can I change viewer when update state in ReactJS? HOT 1
- PANOLENS is not defined ... HOT 2
- Panolens in react website , sensor control does not work in mobile phone
- Infospot custom icon not working in latest IOS 16.4.1 HOT 3
- Raycastingpoint NaN on Mobile Device after OnTap
- Coordinate systems do not match between two copies of a panorama HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from panolens.js.