Lesson goal: Obtaining WebGLHome
To render 3D graphics in your web browser, you need a WebGL-enabled browser. Here's what we know:
- Chrome: Runs WebGL without modification.
- Firefox: To activate WebGL type
about:config into the address bar, search for
webgl, and set
- Safari: To activate WebGL in Safari 5.1, go to the Advanced section of Safari preferences and check "Show Develop menu in menu bar",
then on the Develop menu check "Enable WebGL".
- Internet Explorer: Internet Explorer does not include WebGL, but there is a WebGL plug-in available
If everything is working, click the
button below. You should see two spheres orbiting each other at the bottom of this browser screen (you might
have to scroll down to see them.)
Now you try. Try to get WebGL working on your browser. If in doubt, just download and use Chrome.
Type your code here:
Does your code work? Want to run it on your iPhone?
Here's your code:
- Use [Control]-[C] (Windows) or [⌘]-[C] (MacOS) to copy your code.
- Paste it using [Control]-[V] (Windows) or [⌘]-[V] (MacOS) into
- Then click the "Use on iPhone" button that you'll see.