eclipsesource / eclipsesource/tabris-js
Video not running from built in app
- Dominant language
- JavaScript
- Stars
- 1.4k
- Forks
- 171
- PR merge metrics
- No merged PRs in 30d
Description
### Problem description
I have a small 4mb video inside my built app (like images). It is not fetched from network, but inside the apk itself. When i used the simple example snippet below, it is not playing the video. Just a black screen is shown with the button as coded.
Ready event is not fired, but open is fired.
### Expected behavior
The video should play, immediately.
I verified the relative path of the video. It is perfectly there. and apk size is also increased accordingly when i built.
### Environment
- 2.x nightly
- Xiomi Note 3
- OS: Android 6.0
### Code snippet
```javascript
const {Button, Video, ui} = require('tabris');
let video = new Video({
left: 0, top: 0, right: 0, bottom: '#button 16',
url: './src/videos/myvideo.mp4',
controlsVisible: false
}).on('stateChanged', event => button.text = event.value !== 'pause' ? '❚❚' : '▶')
.appendTo(ui.contentView);
let button = new Button({
id: 'button',
centerX: 0, bottom: 16,
text: '❚❚'
}).on('select', () => video.state === 'play' ? video.pause() : video.play())
.appendTo(ui.contentView);
```
Contributor guide
Assessment
This issue has not been assessed yet.