User Tools

Site Tools



This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
proton:html5_setup [2018/07/28 14:20] – [About and situation] sethproton:html5_setup [2018/07/28 14:20] (current) – [Compiling the examples for HTML5 with Enscripten from Windows] seth
Line 1: Line 1:
 ====Compiling the examples for HTML5 with Enscripten from Windows ==== ====Compiling the examples for HTML5 with Enscripten from Windows ====
 +So Flash is dead and HTML5 is the way forward.  Fine.  There are a few gotchas but overall we've finally reached a place where most stuff renders and sounds ok across the popular browsers with only a few hiccups.
 +RTSimpleApp not using a custom Proton template looks like this:
 +You will take a speed hit and you don't get full access to the user's hardware and networking, but that's the price you pay for being able to pass around programs that can't infect someones computer.
 +The good news is getting your Proton SDK based games to export to HTML5 is very easy and only requires setting up the makefile and maybe a couple lines in your App.cpp file.
 +== See it in action ==
 +  * [[|See RTConsole as HTML5 with SET USE_HTML5_CUSTOM_MAIN=0]]
 +  * [[|See RTBareBones as HTML5 with custom template CustomMainFullTemplate.htm]]
 +  * [[|See RTSimpleApp as HTML5 with custom template CustomMain3-2AspectRatioTemplate.html]]
 +By changing a few values in **<Project name>/html5/build_release.bat** you can set a custom template to use instead of the default Emscripten one.  The custom templates have nice loading bars, let the app respond to changing screen sizes and other bonuses.
 +Note:  Even though the custom templates don't have a text window that show LogMsgs, you can still view them by using Chrome's More tools->Developer options and clicking the "Console" tab.  (Firefox has a similar feature)
 +RTBareBones using a custom Proton template but with the Chrome console open looks like this:
proton/html5_setup.txt · Last modified: 2018/07/28 14:20 by seth