Clone wiki

Coin / Design overview

You are here: HomeDocumentationMac information pageSc21 → Design overview

Design overview

This document is based on the notes for the TechTalk we held at the Siggraph conference in Los Angeles. You can download the slides here if you like.

State of the Union

Sc21 is a Mac OS X framework, written in Objective-C++, for the integration of Coin with Cocoa. (If you are new to Cocoa and Objective-C++, here is a short description.)

The following image shows how Sc21 fits into the system:


Model - View - Controller

Objective-C's dynamic nature makes it possible to split programs into components that pass messages to each other at runtime, but are not dependant on each other in any other way. A widely used approach is the Model-View-Controller design; Sc21 also uses this design pattern.

The minimum number of elements required in an Sc21 application are

  1. the model/scene to render: SCSceneGraph
  2. the view in which to render: an object conforming to the SCDrawable protocol
  3. the controller doing the actual rendering: SCController

In addition, most useful applications require some user interaction: Event processing is done by an eventhandler (or actually, an eventhandler chain; see eventhandling).