This week I've been looking at getting an unreal project onto a web browser, and I've found three ways of doing so.
The first requires UE4.23 and can run Firefox. In UE4 you can package the project as an HTML5 file
Once packaged the file can be hosted from a local web server, the webpage displays the unreal viewport as a window in the center of the screen (with an optional full-screen mode) and is interactive. the output looks something like this, once each of the code files are organized into a server you can click the project connected to a webpage and it should open to a blank web page with a small window showing the unreal engine viewer.
The next method uses a plug-in from Animech that converts unreal files to glTF, this can be done in UE4 or UE5. plugin documentation here. this MUST be downloaded, the other plug-ins mentioned are packaged in with Unreal, this is the only one that is not directly supported by Unreal engine. this method allows for levels in a project file to be exported as glTF and integrated into a web page. the documentation for this method is almost non-existent, the link I provided is more of a description than anything, I can't find any tutorials or explanations on how it works, just that is exports glTF files, once you have the file there are multiple ways they can be used, for example we need an interactive viewer so we could implement the files using code like this:
which creates a similar view to what's used in Sketchfab, more info on how to use glTF files can be found here.
The final method involves pixel streaming.
To start you need to install node.js and then check you have open network ports for communication (the default is port 80 and port 8888). in the unreal project enable the pixel streaming plug-in. In the level editor>play, set the launch parameters (the ports) then you can package the project for Windows. after it is successfully packaged you can edit the properties of the application to match the port information as well as host options. I started running into issues here, for some reason, I'm not able to package a UE5 file, I updated my SDK but I get an error stating "no targets have been found". if I had been able to package the file correctly then the next steps for this method would be to set up a local webserver and set that to the same network port so that you can stream data (pixels) from an unreal file to a webpage, one the server is set up you paste the desktop IP address into the browser, and play the file in unreal engine, this should start the stream. full documentation for this process can be found here.
The last thing I've been working on is Nikki divided up the snazzy maps with me, were duplicating the information we have from Google to a more custom map that Nikki designed, however, I don't seem to have access to the map style. this is something that can be published, and she was given a style code that should allow me to access the designs she created, I'm not sure why I can't access her designs but she's aware of this and we're going to troubleshoot the issue next group meeting.
Comments
Post a Comment