Message: Re: Lifetime of touchables Not Logged In (login)
 Next-in-Thread Next-in-Thread
 Next-in-Forum Next-in-Forum

None Re: Lifetime of touchables 

Forum: Geometry
Re: Question Lifetime of touchables (Nicola Mori)
Re: Warning Re: Lifetime of touchables (Michael H. Kelsey)
Re: Question Re: Lifetime of touchables (Nicola Mori)
Date: 02 Aug, 2014
From: John Allison <John Allison>

I don't know if this is gong to help...

We have this problem in visualisation. A user may want to identify an unique touchable and change its vis attributes, for example. You have to save the whole path, associate a new vis attribute with it, then when traversing the geometry in order to draw the detector, pick it out during traversal. This is done within the visualization and modeling categories so its not easy to access from general user code. I think the key thing to learn from this is that you have to save the complete geometry path and the properties - transformation in particular - can only be ascertained by re-traversing the geometry.

Before you get into all this, think about whether you can store what you want in the hit. E.g., the physical volume pointer, the current transformation, the relevant copy numbers, and other properties. Later, you can print or histogram properties and even draw it on top of the normal detector by writing a DrawHIts (providing the colour of your choice and and a transformation) and "/vis/scene/add/hits".

Hope this helps.

Inline Depth:
 1 1
 All All
Outline Depth:
 1 1
 2 2
 All All
Add message: (add)

1 Ok: Re: Lifetime of touchables   (Nicola Mori - 02 Aug, 2014)
 Add Message Add Message
to: "Re: Lifetime of touchables"

 Subscribe Subscribe

This site runs SLAC HyperNews version 1.11-slac-98, derived from the original HyperNews


[ Geant 4 Home | Geant 4 HyperNews | Search | Request New Forum | Feedback ]