I am working on porting OpenManip to OpenSG 2, and I have run into a
difference WRT OpenSG 1.x that I cannot resolve. In OpenSG 1.x, the
following worked (where mRenderAction is an OSG::DrawActionBase*):

   OSG::Camera* cam = mRenderAction->getCamera();
   OSG::CameraPtr camPtr(cam);

I have not found a way to construct an OSG::CameraPtr from an OSG::Camera*,
and I am wondering if this is being done by design. In other words, is this
prevention of OSG::FCPtr<> construction from a raw pointer deliberate? The
closest I came was to try OSG::Camera::constructPtr(), but this method is
protected.

The OSG::CameraPtr is needed because the pointer is sorted in that form
elsewhere in the code. It might be possible to eliminate the need for the
OSG::CameraPtr, but since I don't know the internal workings of
OSG::FCPtr<>, I do not know how far-reaching the side effects of that may be.

Should this be considered a design flaw in OpenManip, or am I just missing
how to construct the OSG::CameraPtr that I need?

 -Patrick


-- 
Patrick L. Hartling
VP Engineering, Infiscape Corp.
http://www.infiscape.com/

Attachment: signature.asc
Description: OpenPGP digital signature

-------------------------------------------------------------------------
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
_______________________________________________
Opensg-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/opensg-users

Reply via email to