Impressive !

It opens the door for online CAD applications...

Thank you Thomas !



Le 28/01/2011 10:48, Thomas Paviot a écrit :
Dear all,

I've been working for months on the upcoming WebGL technology (www.khronos.org/webgl/ <http://www.khronos.org/webgl/>). I'm convinced it will bring CAD in another paradigm.

During this time, I read a lot of doc, specs, benchmarked a few webgl libraries (GLGE, spidergl, threejs, o3d). And I also had to dive into javascript (disgusting), CSS (awful) and OpenGL (nightmare).

I uploaded to the repository a very first draft of a script enabling the export of a TopoDS_Shape to WebGL. The result is an html page that can be viewed in a web browser supporting the WebGL specs (Chrome 8, Firefox 4 Beta 10, Minefield, Webkit).

Source code is available at : http://code.google.com/p/pythonocc/source/browse/branches/webgl
Online webgl demo: http://webgl.pythonocc.org
Youtube screencast: http://www.youtube.com/watch?v=0GXbfzWV8qk
Website post: http://www.pythonocc.org/news/experimental-webgl-renderer-towards-cad-in-a-browser/

The python script takes a TopoDS_Shape and generate a javascript named 'shape.js'. This script is loaded by the html file.

Note that this work is still a draft, and very basic. Of course you're welcome to download/modify/improve the code, for instance: add shaders, icons, optimize computations etc.

The html page easily can be served by a simple http server, or a django instance (or cherrypy or whatelse) to develop an 'HTTP visualization server'.

From my tests, using WebGL provides many advantages over OpenGL: the modeling and rendering processes are separated, there's no need to install/load an heavy GUI manager, shaders or beautiful effects can easily be added, WebGL implementations are much better than the OCC one etc.

Hope you'll like it, and much looking forward to reading your feedbacks/suggestions/questions etc.

Best Regards,

Thomas


_______________________________________________
Pythonocc-users mailing list
Pythonocc-users@gna.org
https://mail.gna.org/listinfo/pythonocc-users
_______________________________________________
Pythonocc-users mailing list
Pythonocc-users@gna.org
https://mail.gna.org/listinfo/pythonocc-users

Reply via email to