# Get a black screen when trying to display a video in Chrome

**URL:** <https://mediasoup.discourse.group/t/get-a-black-screen-when-trying-to-display-a-video-in-chrome/4427>\
**Category:** Off Topic\
**Created:** [August 2, 2022, 1:56pm UTC](https://mediasoup.discourse.group/t/get-a-black-screen-when-trying-to-display-a-video-in-chrome/4427 "2022-08-02T13:56:12Z")\
**Posts on this page:** 1\
**Showing post:** 14

<div class="post-metadata">

**Author:** ![BronzedBroth](https://avatars.discourse-cdn.com/v4/letter/b/ad7895/32.png) [@BronzedBroth](https://mediasoup.discourse.group/u/BronzedBroth)\
**Post date:** [August 2, 2022, 6:52pm UTC](https://mediasoup.discourse.group/t/get-a-black-screen-when-trying-to-display-a-video-in-chrome/4427/14 "2022-08-02T18:52:04Z")

</div>

Auto-play is restricted if you do not interact with the page first before loading these videos.

```auto
window.AudioContext = window.AudioContext || window.webkitAudioContext;
let audioCtx = new window.AudioContext();
if (audioCtx.state === 'suspended') {
  // If suspended user hasn't interacted with page
} else {
  // User had interacted with page.
}

```

Regardless of above I still check for interaction by button click, a modal popup before joining the chat or viewing any videos.

---

_[View the full topic](https://mediasoup.discourse.group/t/get-a-black-screen-when-trying-to-display-a-video-in-chrome/4427)._
