
Tue, 06/01/2004 - 11:56
Forums:
Hi, I manage a list of interactive object for vizualisation and I need to store some data (pointer) in the interactive object themselves to identify them from my application.
What is the best way to do it ?
Is there a free data member in AIS object to store this information ?
Regards
Jerome
Tue, 06/01/2004 - 15:57
We use the SetOwner and GetOwner method of AIS_InteractiveObject.
Francois.
Tue, 06/01/2004 - 16:20
I agree but the SetOwner and GetOwner methods return/get a "const Handle(Standard_Transient)& " and my object don't inherits from Standard_Transient. I try to make casts but don't find any solution.
Is there another way ?
Jerome
Tue, 06/01/2004 - 17:10
I don't see any other way but to attach a derived class from Handle(Standard_Transient). You could create a wrapper derived from Handle(Standard_Transient) that will hold a pointer to your object.
Good Luck,
Francois.