Wayback Machinekoobas.hobune.stream
May JUN Jul
Previous capture 12 Next capture
2021 2022 2023
1 capture
12 Jun 22 - 12 Jun 22
sparklines
Close Help
  • Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
  • Asset Store
  • Get Unity

UNITY ACCOUNT

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account
  • Blog
  • Forums
  • Answers
  • Evangelists
  • User Groups
  • Beta Program
  • Advisory Panel

Navigation

  • Home
  • Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
    • Blog
    • Forums
    • Answers
    • Evangelists
    • User Groups
    • Beta Program
    • Advisory Panel

Unity account

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account

Language

  • Chinese
  • Spanish
  • Japanese
  • Korean
  • Portuguese
  • Ask a question
  • Spaces
    • Default
    • Help Room
    • META
    • Moderators
    • Topics
    • Questions
    • Users
    • Badges
  • Home /
avatar image
0
Question by MayIAsk · Jul 21, 2017 at 02:23 PM · androidwebglbrowserhtmlhtml5

Can I display an Unity WebGL Game in Unity Editor ?

Hello,

I'm trying to put a HTML5 game (made with Unity WebGL export) in an Android app. I'm using a webview and the webview is correctly loading and displaying except my WebGL game, I see the loader and a white screen right after. It seems that the game never finish loading in Editor.. What is wrong with it, the web browser ? Unity ?

When I build it (APK), it says that it could not run and I should try to download Firefox (I have Firefox as default browser) but still not showing up.

Is there a Unity preferences to use a specific browser when I open URLs ?

Thank you for your time/help.

Comment
Add comment
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users

1 Reply

· Add your reply
  • Sort: 
avatar image
1

Answer by tanoshimi · Jul 21, 2017 at 02:36 PM

WebGL is not supported on mobile browsers, as documented at https://docs.unity3d.com/Manual/webgl-browsercompatibility.html

I'm not sure what you're trying to achieve - if you want to target Android devices, make an Android build.

Comment
Add comment · Show 4 · Share
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users
avatar image Bunny83 · Jul 21, 2017 at 03:07 PM 0
Share

This is generally true, however the Firefox for android is able to run WebGL on Android. However a native webview won't. The firefox ships it's own HT$$anonymous$$L rendering engine.

avatar image MayIAsk · Jul 21, 2017 at 03:14 PM 0
Share

Thank you for your comment. I didn't want to make an Android build because I want to use this game on PC/$$anonymous$$ac and on Android with the same link through WebGL. That's why I use UniWebView to display the HT$$anonymous$$L page that contains the WebGL game on mobile devices.

About Firefox, I'm sure it can run WebGL on Android, the problem is that it keep saying that I need to install it on my device even if I already have it as default browser...

avatar image Bunny83 MayIAsk · Jul 21, 2017 at 03:18 PM 0
Share

I don't get it. If you have a webGL game hosted on a webserver, you can simply open that webpage in firefox on your android device. There' no need to create a seperate android App that displays a webview. Again a webview can't run a WebGL application since a WebView doesn't support webGL and not even javascript. As you can read on the webview documation page if you want to view interactive content it's recommended to open the contant externally inside an actual browser.

edit
Just to be clear. Here i have my mandelbrot renderer as WebGL build hosted on a free hoster. You can reach it by this link here from a browser but it works exactly the same if i open that link inside firefox on my Nexus7. Though much much slower. WebGL is extremely demanding and limited. Running such content on a weak device such as an android phone or tablet does not work out well.

avatar image MayIAsk Bunny83 · Jul 24, 2017 at 08:18 AM 0
Share

Thank you for answering Bunny. I wanted a webview with a WebGL game inside to avoid closing the actual app and opening a browser. I want my WebGL (HT$$anonymous$$L5) games that I use on the web into my android app either without going on a browser. That's why I use the plugin UniWebView that handle javascript. I was just wondering if I could do it even if it's a WebGL games inside the webview.

Your answer

Hint: You can notify a user about this post by typing @username

Up to 2 attachments (including images) can be used with a maximum of 524.3 kB each and 1.0 MB total.

Follow this Question

Answers Answers and Comments

140 People are following this question.

avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image

Related Questions

Unity iOS Android: open local HTML in Browser 1 Answer

Open a local html file in the Android's default browser 1 Answer

Need tip on better UI.Text control to control the paragraph alignment using tags. 1 Answer

Unity webgl or threejs or babylonjs ? Which one is the best for me? 1 Answer

VideoPlayer not playing in WebGL Build 0 Answers


Enterprise
Social Q&A

Social
Subscribe on YouTube social-youtube Follow on LinkedIn social-linkedin Follow on Twitter social-twitter Follow on Facebook social-facebook Follow on Instagram social-instagram

Footer

  • Purchase
    • Products
    • Subscription
    • Asset Store
    • Unity Gear
    • Resellers
  • Education
    • Students
    • Educators
    • Certification
    • Learn
    • Center of Excellence
  • Download
    • Unity
    • Beta Program
  • Unity Labs
    • Labs
    • Publications
  • Resources
    • Learn platform
    • Community
    • Documentation
    • Unity QA
    • FAQ
    • Services Status
    • Connect
  • About Unity
    • About Us
    • Blog
    • Events
    • Careers
    • Contact
    • Press
    • Partners
    • Affiliates
    • Security
Copyright © 2020 Unity Technologies
  • Legal
  • Privacy Policy
  • Cookies
  • Do Not Sell My Personal Information
  • Cookies Settings
"Unity", Unity logos, and other Unity trademarks are trademarks or registered trademarks of Unity Technologies or its affiliates in the U.S. and elsewhere (more info here). Other names or brands are trademarks of their respective owners.
  • Anonymous
  • Sign in
  • Create
  • Ask a question
  • Spaces
  • Default
  • Help Room
  • META
  • Moderators
  • Explore
  • Topics
  • Questions
  • Users
  • Badges