Search Unity

  1. Welcome to the Unity Forums! Please take the time to read our Code of Conduct to familiarize yourself with the forum rules and how to post constructively.
  2. The 2023.1 beta is now available for testing. To find out what's new, have a look at our 2023.1 feature highlights.
    Dismiss Notice

WS connection close on WebApp build from NPM Black screen on WebBrowserSample

Discussion in 'Unity Render Streaming' started by vrSim_NRT, Apr 5, 2022.

  1. vrSim_NRT


    Feb 8, 2022

    I have downloaded the webserver from Unity Edit->Render Streaming-> Download Web App. Then run the server using command
    .\webserver -w
    Then if I play the WebBrowserInput Scene from Sample in unity and check the videoPlayer url on localhost in browser then streaming in done properly I could see unity scene in browser.
    But, if I downloaded the WebApp sourceCode and then run the server using following commands:
    cd WebApp
    npm install
    npm run build
    npm run start
    Then it seems the connection is not happening between untiy and browser. Unity console says "WS connection closed" while in browser when I hit play on VideoPlayer url in localhost black screen remains there.
    Is there anything that I am missing in the process?
    Please help me how to make customize webapp? I was actually trying to send customized data on stream.
  2. kannan-xiao4


    Unity Technologies

    Nov 5, 2020
    I think you need command argument about websoket.
    Can you try this `npm run start -- -w` ?