3D Lake Scene
Mapped with Photos from an iPhone
Swipe to View the 3D Background
The texture map for this lake scene
originated with panoramic
photographs taken with an iPhone.
WebGL Scenes: Responsive Web Design
explains how to create three dimensional backgrounds
from panoramic photographs.
WebGL Scenes with Responsive Web Design
Example WebGL environments
demonstrate how to display a 3D background with basic shaders,
cube environment, and one texture graphic.
This method avoids use of skyboxes, multiple image files, and separate shaders.
Skybox shaders require the
textureCube() function. The e-book's
sampler2D instead of
samplerCube allows many WebGL projects
to render with just one program.
Program switching involves more code as well as
Examples tested well with iPhone 6, Android phone and tablet, Windows PCs with WebGL enabled browsers, and Windows Phone 8.1.