Hi @Hoang_Dang ,
I’ve reviewed your video playback issue and identified two adjustments that should resolve the black screen problem.
What I Found
-
Missing playback trigger: Since you’ve set
autoplay = false, the video loads but doesn’t start playing automatically. -
Video format compatibility: ShakaPlayer requires adaptive streaming formats like DASH manifests rather than direct MP4 files.
Suggested Changes
Please try these modifications:
1. Add the play() call
In your initVideoPlayer function, add this line after loading the content:
await shakaPlayer.current.load(content, true);
console.log('✅ Shaka content loaded');
// Add this line:
await shakaPlayer.current.play();
console.log('▶️ Playback started');
2. Use a compatible video format
Replace your current video URL with this DASH format example:
const content = {
secure: false,
uri: 'https://storage.googleapis.com/shaka-demo-assets/angel-one/dash.mpd', // DASH format example
drm_scheme: '',
drm_license_uri: '',
};
Would you be able to give these changes a try? Let me know if you run into any other issues.
Regards,
Aishwarya