English 中文(简体)
What language should I learn to prepare for WebGL?
原标题:

I am thinking about making a 3D game with WebGL (just for conceptual purposes, for now), but all I have never done anything in 3D and have only programmed in PHP for the most part. From what I understand, WebGL is Javascript, which I use heavily in all of my projects, but it is also my understanding that it is very different from regular JavaScript. If I wanted to get a head start to begin trying to figure out how to make 3D applications with WebGL, would there be a certain language that would help me to grasp how to do that better?

最佳回答

To be honest, you re probably better off diving right in rather than trying to learn another language first. Most WebGL programming is in JavaScript, but some is in GLSL (the GL Shader Language, for the part of the code that runs on your graphics card) and while you could learn that by trying out some other version of OpenGL, that wouldn t have any obvious advantages over just diving right in to WebGL directly. It s easy to download a browser that supports it.

I ve been teaching myself WebGL by translating some old OpenGL tutorials and documenting things as I go along; like you I have no real 3D background, so you might find them useful.

问题回答

There s only one language to learn. JavaScript. It s the only language you can use WebGL from.

If you are new to 3D use a library. A very popular one is three.js. 2 others are GLGE and SceneJS

I recommend making some JavaScript programs that use the Canvas2D feature before moving on to 3D. The WebGL API is exciting, but there will be other parts to your programs.

Take a look at C, the native language of OpenGL, buy the red book and play around a little. It s nice to see where WebGL is influenced from.

Processing is a nice sandbox to learn OpenGL.
It is available for Windows, Linux and Mac OS X.
It offers:

and it s free

WebGL isn t different from JavaScript, it is JavaScript. If you want to learn WebGL just dive in. I suggest visiting the learning WebGL tutorials. Next choose a WebGL library or framework. This StackOverflow.com answer has a list of WebGL libraries to choose from.





相关问题
3D Engine for Driving Simulation [closed]

Is there any open-source 3D graphics and physics engine specialized in driving simulation? Something like a configurable game engine targeted at games that involve driving, or something more ...

How to rotate 3d object on Z axis only?

We used 3DTools (http://3dtools.codeplex.com) to draw a 3d line, it allows user rotate it by mouse. I have question, how to limit user can rotate it on Z axis only? or on X axis, Y axis only? <...

WPF 3d rotation animations

I have a few 3d rectangles on my screen that I want to pivot around the Y axis. I want to press down with the mouse, and rotate the 3d object to a max rotation, but when the user moves their mouse, ...

Java - Zoom / 3D Data Visualization Libraries

What are the best libraries/frameworks for doing 3D and/or Zoom interfaces in Java? I d like to be able to do some prototyping of creating new types of interfaces for navigating within data and ...

Using Unreal 3 Engine within a .NET application

Now that the Unreal Development Kit for Unreal 3 engine is free I am thinking about utilizing it for an appication. Do you think it is possible to emebedd a Unreal 3 powered 3D window into a .NET (WPF ...

WPF convert 2d mouse click into 3d space

I have several geometry meshes in my Viewport3D, these have bounds of (w:1800, h:500, d:25). When a user clicks in the middle of the mesh, I want the Point3D of (900, 500, 25)... How can I achieve ...

热门标签