Computer Graphics and Multimedia Software - Knowledge Sharing

Tuesday, November 8, 2016

Develop a working osgART application

What is a Scene Graph?

Tree-like structure for organising a virtual world, e.g. VRML
Hierarchy of nodes that define: Groups (and Switches, Sequences etc…) Transformations, Projections, Geometry …

And states and attributes that define:

  •  Materials and textures
  •  Lighting and blending
Benefits for performance

  •   Structuring data facilitates 
    • optimization:- Culling, state management, etc
What is a Open Scene Graph (OSG)?

Open-source scene graph implementation
Based on OpenGL
Object-oriented C++ following design pattern principles
Used for simulation, games, research, and industrial projects
Maintained by Robert Osfield | Documentation project: www.osgbooks.com
Uses the OSG Public License (similar to LGPL)

What is a osgART?

OSG + ARTookit = osgART
osgART adds AR to Open Scene Graph
Current version 2.0, Open Source

To add Video see-through AR:
  •  Integrate live video
  •  Apply correct projection matrix
  •  Update tracked transformations in real-time
Develop a working osgART application from scratch?

Use ARToolKit 2.72 
     library for tracking and 
     video capture
Install OSG

Tutorial 1 : Basic OSG Viewer | OSG 
Install osg (.exe) to your computer
Run basic viewer - located in osg folder in C:\\Program Files (Windows)

Tutorial 2: Adding Video | OSG + ARToolkit
Add a video plugin
Load, configure, start video capture…
Add a video background
Create, link to video, add to scene-graph

Tutorial 3: Tracking | OSG + ARToolkit
Add a Tracker plugin
 Load, configure, link to video
 Add a Marker to track
 Load, activate
 Tracked node
 Create, link with marker via tracking callbacks
 Print out the tracking data

Tutorial 4: Adding Content | OSG + ARToolkit
Now put the tracking data to use!
Add content to the tracked transform 
Basic cube code
e.g. Wavefront (.obj), OpenFlight (.flt), 3D Studio (.3ds), COLLADA
Replace the simple cube with a 3D model
Models are loaded using the osgDB::readNodeFile() function


OSGART sample project by other researchers


Share:

2 comments:

Malaysia Augmented Reality

Its incredibly difficult to discover the undiscovered. Here will see how I can help you. Cheers - Ajune (comp.utm.my/ajune)
ajune@utm.my. Powered by Blogger.