OpenSG

Last updated
OpenSG
Written in C++
Operating system Windows, Linux, Solaris, OS X
Type Scene graph
License LGPL
Website sourceforge.net/projects/opensg/

OpenSG is a scene graph system to create real-time graphics programs, e.g. for virtual reality applications. It is developed following Open Source principles, LGPL licensed, and can be used freely. It runs on Windows, Linux, Solaris and OS X and is based on OpenGL.

Contents

Its main features are advanced multithreading and clustering support (with sort-first and sort-last rendering, amongst other techniques), although it is perfectly usable in a single-threaded single-system application as well.

It is not part of Khronos Group.

History

It was started, just like many other systems, at the end of the scenegraph extinction in 1999 when Microsoft and SGI's Fahrenheit graphics API project died. Given that there was no other scene graph system on the market nor on the horizon with the features the authors wanted, they decided to start their own.

OpenSG should not be confused with OpenSceneGraph which is entirely different scene graph API, somewhat similar to OpenGL Performer. Development on both started about the same time, and both chose similar names.

Technology

OpenSG is a scene graph like many others, but with a number of unique features that set it apart from others. It features a blocked state management system to reduce the overhead for state change optimization, highly flexible traversal and other mechanisms to allow run-time exchange and enhancement of core data structures, but the most unusual aspect is its multi-threading approach. [1]

Scene graphs are notoriously hard targets for multi-threading, as they contain very large data structures easily consuming hundreds of megabytes of memory. Duplicating these is not an option due to the large overhead. Many scene graphs just lock individual nodes to prevent data corruption due to parallel writes, but that is only a partial solution. The state of the scene graph is represented by the whole scene graph, only protecting individual nodes can still lead to inconsistent results (e.g. when running an asynchronous physics simulation only updating parts of the graph will lead to partial simulation steps being displayed). OpenSG uses selective multi-buffering, by duplicating the small parts of the graph for each thread that needs to be protected while sharing the bulk data like vertex arrays and texture images, and only duplicating these using a copy on write mechanism. Synchronization of the changes for individual threads is done using a change list approach that allows minimal overhead.

The same mechanism also allows highly flexible and effective clustering. To synchronize an application running on several machines, only the changes for each frame are sent to each machine and integrated into the local scene graph. This way the distinction between local and remote changes is almost invisible. An application that wants to run on a cluster just needs to open a ClusterWindow that can distribute all changes across the cluster and can very easily drive a Powerwall or a CAVE without having to worry about distribution protocols and other complications.

People

The project was started by Dirk Reiners, Gerrit Voss and Johannes Behr. it has received contributions by many other people, most notably by Carsten Neumann, who currently functions as the main maintainer.

Related Research Articles

OpenGL Cross-platform graphics API

OpenGL is a cross-language, cross-platform application programming interface (API) for rendering 2D and 3D vector graphics. The API is typically used to interact with a graphics processing unit (GPU), to achieve hardware-accelerated rendering.

Scene graph

A scene graph is a general data structure commonly used by vector-based graphics editing applications and modern computer games, which arranges the logical and often spatial representation of a graphical scene. It is a collection of nodes in a graph or tree structure. A tree node may have many children but only a single parent, with the effect of a parent applied to all its child nodes; an operation performed on a group automatically propagates its effect to all of its members. In many programs, associating a geometrical transformation matrix at each group level and concatenating such matrices together is an efficient and natural way to process such operations. A common feature, for instance, is the ability to group related shapes and objects into a compound object that can then be manipulated as easily as a single object.

Fahrenheit was an effort to create a unified high-level API for 3D computer graphics to unify Direct3D and OpenGL. It was designed primarily by Microsoft and SGI and also included work from an HP-MS joint effort.

X3D is a royalty-free ISO/IEC standard for declaratively representing 3D computer graphics. File format support includes XML, ClassicVRML, Compressed Binary Encoding (CBE) and a draft JSON encoding. X3D became the successor to the Virtual Reality Modeling Language (VRML) in 2001. X3D features extensions to VRML, the ability to encode the scene using an XML syntax as well as the Open Inventor-like syntax of VRML97, or binary formatting, and enhanced application programming interfaces (APIs).

In computer science, a lock or mutex is a synchronization primitive: a mechanism that enforces limits on access to a resource when there are many threads of execution. A lock is designed to enforce a mutual exclusion concurrency control policy, and with a variety of possible methods there exists multiple unique implementations for different applications.

OpenGL Performer, formerly known as IRIS Performer and commonly referred to simply as Performer, is a commercial library of utility code built on top of OpenGL for the purpose of enabling hard real-time visual simulation applications. OpenGL Performer was developed by SGI which continues to maintain and enhance it. OpenGL Performer is available for IRIX, Linux, and several versions of Microsoft Windows. Both ANSI C and C++ bindings are available.

OpenGL++ was a graphics library written in C++ that supported object-oriented data structures on top of the OpenGL 3D graphics system. The project started as the result of a partnership between SGI, IBM and Intel, and later, Digital Equipment Corporation. It was intended to provide a higher level API than the "bare metal" support of OpenGL, as well as being an implementation for Java3D. Work on OpenGL++ ended when SGI decided to partner with Microsoft instead, leading to the Fahrenheit project, which also died.

QuickDraw 3D 3D graphics API developed by Apple Inc.

QuickDraw 3D, or QD3D for short, is a 3D graphics API developed by Apple Inc. starting in 1995, originally for their Macintosh computers, but delivered as a cross-platform system.

The Khronos Group, Inc. is an open, non-profit, member-driven consortium of 170 organizations developing, publishing and maintaining royalty-free interoperability standards for 3D graphics, virtual reality, augmented reality, parallel computation, vision acceleration and machine learning. The open standards and associated conformance tests enable software applications and middleware to effectively harness authoring and accelerated playback of dynamic media across a wide variety of platforms and devices. The group is based in Beaverton, Oregon.

Parallel rendering is the application of parallel programming to the computational domain of computer graphics. Rendering graphics can require massive computational resources for complex scenes that arise in scientific visualization, medical visualization, CAD applications, and virtual reality. Recent research has also suggested that parallel rendering can be applied to mobile gaming to decrease power consumption and increase graphical fidelity. Rendering is an embarrassingly parallel workload in multiple domains and thus has been the subject of much research.

OpenSceneGraph

OpenSceneGraph is an open-source 3D graphics application programming interface, used by application developers in fields such as visual simulation, computer games, virtual reality, scientific visualization and modeling.

GDK

GDK is a library that acts as a wrapper around the low-level functions provided by the underlying windowing and graphics systems. GDK lies between the display server and the GTK library, handling basic rendering such as drawing primitives, raster graphics (bitmaps), cursors, fonts, as well as window events and drag-and-drop functionality.

UNIGINE is a proprietary cross-platform game engine developed by UNIGINE Company, used in simulators, virtual reality systems, serious games and visualization. UNIGINE can support large open worlds including entire planets. It has an advanced 3D renderer that supports OpenGL 4 and DirectX 11. UNIGINE SDK releases an update every three to four months.

Immediate mode in computer graphics is a design pattern of API design in graphics libraries, in which

oneAPI Threading Building Blocks, is a C++ template library developed by Intel for parallel programming on multi-core processors. Using TBB, a computation is broken down into tasks that can run in parallel. The library manages and schedules threads to execute these tasks.

In computer science and visualization, a canvas is a container that holds various drawing elements. It takes its name from the canvas used in visual arts. It is sometimes called a scene graph because it arranges the logical representation of a user interface or graphical scene. Some implementations also define the spatial representation and allow the user to interact with the elements via a graphical user interface.

Mantle (API) Low-overhead rendering API

Mantle was a low-overhead rendering API targeted at 3D video games. AMD originally developed Mantle in cooperation with DICE, starting in 2013. Mantle was designed as an alternative to Direct3D and OpenGL, primarily for use on personal computers, although Mantle supports the GPUs present in the PlayStation 4 and in the Xbox One. In 2015, Mantle's public development was suspended and in 2019 completely discontinued, as DirectX 12 and the Mantle-derived Vulkan rose in popularity.

GTK Scene Graph Kit

GTK Scene Graph Kit (GSK) is the rendering and scene graph API for GTK introduced with version 3.90. GSK lies between the graphical control elements (widgets) and the rendering.

Vulkan is a low-overhead, cross-platform API, open standard for 3D graphics and computing. Vulkan targets high-performance real-time 3D graphics applications, such as video games and interactive media. In contrast to the older OpenGL and Direct3D 11 APIs, Vulkan is intended to offer higher performance and more efficient CPU and GPU usage. It provides a considerably lower-level API for the application than the older APIs, making Vulkan comparable to Apple's Metal API and Microsoft's Direct3D 12. In addition to its lower CPU usage, Vulkan is designed to allow developers to better distribute work among multiple CPU cores.

References

  1. Voß, G.; Behr, J.; Reiners, D.; Roth2, M. (2002-01-01). "A Multi-thread Safe Foundation for Scene Graphs and Its Extension to Clusters". Proceedings of the Fourth Eurographics Workshop on Parallel Graphics and Visualization. EGPGV '02. Aire-la-Ville, Switzerland, Switzerland: Eurographics Association: 33–37. ISBN   1-58113-579-3.