Presentation is loading. Please wait.

Presentation is loading. Please wait.

3D graphics in Erlang Jakob Cederlund -

Similar presentations


Presentation on theme: "3D graphics in Erlang Jakob Cederlund -"— Presentation transcript:

1 3D graphics in Erlang Jakob Cederlund - jakob@gnodata.se
Björn Gustavsson - Dan Gudmundsson -

2 3D graphics in erlang 3D graphics with hardware acceleration
OpenGL - an open version of SGI’s GL Reasonable API Open standard Cross platform (Wintel, Linux, Sun, Mac) Widespread support from hardware SDL - a library supplementing OpenGL with interaction, 2D graphics and more

3 erlang and 3D graphics erlang high level language
3D graphics needs symbolic language Fast development Performance critical code mostly in 3D hardware and drivers

4 ESDL An erlang driver that interfaces with SDL
Supports most OpenGL calls Fast Optimized C driver Uses binary syntax Available as download from contrib area Written by Dan Gudmundsson

5 ESDL erlang 3D program esdl-driver esdl SDL lib OpenGL 3D hardware

6 Wings - a 3D modeller in erlang
Uses erlang as functional language Fast development Good performance Powerful Innovative user interface Inspired by Nendo Written by Björn Gustavsson Some inspiration from Jakob Cederlund

7 Wings Most of the erlang code not performance critical
Some functions optimized Winged-edge structure for 3D objects Uses gb_trees and gb_sets (included in OTP R8)

8 Wings - features Powerful modelling
Every operation applicable to several objects at the same time Imports and exports to different formats Wavefront 3D studio Easy to do easy things As opposed to other 3D modellers

9 Wings - development Functional Only one process
Process dictionary used in for GUI state Some things suprisingly easy to do Multiple undo, with shared data Only updates appriopriate parts of the model Continues after crash, e.g. to save work Just a catch, saves dump to file Library functions used gb_sets and gb_trees (R8) sofs - Sets OF Sets (R8) digraph and digraph_utils

10 Wings - development cont.
Funs used a lot special fold operations to iterate over model elements Optimization after implementation and testing Data structures hidden, used via functions Most user commands uses primitive commands Example inset Extrude Scale

11 Wings - examples Rendered in Bryce, composited in PhotoShop

12 Wings - examples cont. Modelled in only 5 minutes!
Rendered afterwards in Bryce

13 Wings - performance Most things fast enough
Optimized floating point in R8 Some things take time Smooth Dissolve Used as primitive by many commands erlang fast enough, even for interactive tasks

14 Wings - future Long to-do list
Ongoing development, bugfixing and new features Future features Plug-ins, both in erlang and C More export formats, e.g. renderman Cameras, multiple views Materials, textures New platforms (MacOSX)

15 Wings - availability Open source Full source on sourceforge
Compiled versions Currently requires otp, esdl and SDL Stand-alone erlang version with installer will be available shortly Documentation and examples Home page


Download ppt "3D graphics in Erlang Jakob Cederlund -"

Similar presentations


Ads by Google