Zubanov Alexei, 2006 Aug 07 – Sep 28 [email protected] QtROOT package extension with Coin3D lib.

11
Zubanov Alexei, 2006 Aug 07 – Sep 28 [email protected] QtROOT package extension with Coin3D lib

Transcript of Zubanov Alexei, 2006 Aug 07 – Sep 28 [email protected] QtROOT package extension with Coin3D lib.

Page 1: Zubanov Alexei, 2006 Aug 07 – Sep 28 zubanov@jinr.ru QtROOT package extension with Coin3D lib.

Zubanov Alexei, 2006Aug 07 – Sep 28

[email protected]

QtROOT package extensionwith Coin3D lib

Page 2: Zubanov Alexei, 2006 Aug 07 – Sep 28 zubanov@jinr.ru QtROOT package extension with Coin3D lib.

Outline

Zubanov Alexei, Extension QtRoot package, 2006

● STAR Needs & Current Tools

● Coin3D lib Advantages

● Implementation

● Steps

● New QtRoot Class Tree

● Examples of New Viewer Using

●Different Styles

●Selection (Picking)

●Manipulation

● Summary

2

Page 3: Zubanov Alexei, 2006 Aug 07 – Sep 28 zubanov@jinr.ru QtROOT package extension with Coin3D lib.

Introduction: STAR needs

Zubanov Alexei, Extension QtRoot package, 20063

Online display

Multiple scene representation modes

Event reconstruction

Detector & Tracks detailed information retrieval

Simulation

Geometry checks

Easy navigation through detector structure: e.g. transparency etc.

Page 4: Zubanov Alexei, 2006 Aug 07 – Sep 28 zubanov@jinr.ru QtROOT package extension with Coin3D lib.

Introduction: Existing Tools

ROOTQtRootTCanvas

TQtCanvasTVirtualViewer3D (abstract)

GLViewer x3d

TQtRootViewer3D

GLViewer System

TBuffer3D

TObject3DView

1

1

Great, but no hardware acceleration support means no online display!

2

2

Great, but lacks features that STAR needs right away: transparency problem, no object selection (“pick” scene object ability)

3

3 Excellent, a bit hard to extend and implement new features required bygrowing STAR needs!

Zubanov Alexei, Extension QtRoot package, 20064

Page 5: Zubanov Alexei, 2006 Aug 07 – Sep 28 zubanov@jinr.ru QtROOT package extension with Coin3D lib.

Solution: Coin3D integration into default Root environment

ROOTQtRootTCanvas

TQtCanvasTvirtualViewer3D (abstract)

GLViewer x3d

TQtRootViewer3D

GLViewer System

TBuffer3D

CoinViewer System

TObject3DView

Main features provided by Coin3D : ● True transparency. (10 transparency types)● More scene representation modes (7)● Arbitrary count of interactive light sources● Selectors & Manipulators● Level of Details support (distance objects displayed in low quality)● Engines to create Animated scene

When you use a high level graphic library (like Coin3D), you don't need to think about creating simple things which request a lot of coding.

The library provide many embedded nice opportunities.

Zubanov Alexei, Extension QtRoot package, 20065

Page 6: Zubanov Alexei, 2006 Aug 07 – Sep 28 zubanov@jinr.ru QtROOT package extension with Coin3D lib.

Implementation: QtRoot Class Tree, new modules created

Created modules

1 2

3

1 Main viewer window:sweet GUI design

2 Interface, to havechance to work like ROOT plugin

3 Coin3D factory:it creates a Coin3Dspecific object tree

Zubanov Alexei, Extension QtRoot package, 20066

Integrated as standard ROOT viewer!

Does not need any extra steps to use within STAR framework!

Page 7: Zubanov Alexei, 2006 Aug 07 – Sep 28 zubanov@jinr.ru QtROOT package extension with Coin3D lib.

Implementation: new features available for STAR collaboration

Many new draw styles: great for publications!

Zubanov Alexei, Extension QtRoot package, 20067

Now: ability to select specific tracks! Great for reconstruction QA!

(e.g.: track highlighted by red above)

Simple transparency example, useful for geometry checks!

Basic geometry view: as good as existing tools (even better quality available!)

Page 8: Zubanov Alexei, 2006 Aug 07 – Sep 28 zubanov@jinr.ru QtROOT package extension with Coin3D lib.

Possible future advance : object manipulators

Zubanov Alexei, Extension QtRoot package, 20068

Near future : powerful object manipulation.Great for detector R&D projects!

Page 9: Zubanov Alexei, 2006 Aug 07 – Sep 28 zubanov@jinr.ru QtROOT package extension with Coin3D lib.

Summary

Done:✔ Main question answered: Can we use Coin3D to help physicists in

visualization? YES!✔ “Smart” Viewer developed (part of QtRoot package) as standard dynamic

load ROOT library:✔Draws geometry from ROOT, WRL, IV files. Stores back in WRL, IV formats✔Selects scene objects (detectors parts, tracks). ✔Nice pictures for publications: export to JPG, PS formats✔Qt-based: emits proper signals (supports Signal-Slot mechanism). Base requirement for Object Editor.

✔ Can be used in STAR right away! NO extra efforts needed, “one-liner” config change to allow STAR-wide usage.

Possible To Do List (to be decided by STAR S&C council) :➢ Create Object Editor. Additional tool for changing properties of selected objects (color, style,

size)➢ Add “Track filter” option, see only interesting tracks➢ Add “Geometry filter” option, see only interesting geometry parts➢ Complete Event Display application with new viewer features

9Zubanov Alexei, Extension QtRoot package, 2006

Work will be continued in Dubna, Russia. PPL-STAR review deadline: Feb'07

Page 10: Zubanov Alexei, 2006 Aug 07 – Sep 28 zubanov@jinr.ru QtROOT package extension with Coin3D lib.

Information sources

"C++ GUI Programming with Qt3" by Jasmin Blanchette and Mark Summerfiled

The Inventor Mentor: Programming Object-Oriented 3D Graphics with Open Inventor™, Release 2

ROOT User's Guide: ftp://root.cern.ch/root/doc/Users_Guide_5_12.pdf

Qt class reference: http://www.trolltech.com/developer/documentation

Coin3D class reference: http://doc.coin3d.org/Coin-dev/

SoQt class reference: http://doc.coin3d.org/Coin-dev/

Qt Reference Documentation (programming techniques): http://doc.trolltech.com/4.1/

Zubanov Alexei, Extension QtRoot package, 200610

QtRoot package: http://root.bnl.gov/

Qt & ROOT by V.Fine

"Cross-Platform Qt-Based Implementation of the Low Level GUI Layer of ROOT " talk by V.Fine

Page 11: Zubanov Alexei, 2006 Aug 07 – Sep 28 zubanov@jinr.ru QtROOT package extension with Coin3D lib.

Information

Zubanov Alexei, Extension QtRoot package, 200611

This package is the part of the QtRoot package, see installation guide at :http://root.bnl.gov/QtRoot/How2Install4Unix.html#installroot

Documentation available at:http://www.star.bnl.gov/~zubanov/

ROOT available at:http://root.cern.ch/

Coin3D and SoQt available at:http://www.coin3d.org/lib/