What's new

ViewTransform, IsPerspective, SetViewTransform problems

heyheyjc

Member
Any calls to ViewTransform and IsPerspective on an IADDesignSession seem to generate the following exception:

Additional information: Unable to cast COM object of type 'DXUTILSLib.DXContextClass' to interface type 'DXUTILSLib.IDXContext'. This operation failed because the QueryInterface call on the COM component for the interface with IID '{3A93C1C0-B712-11D3-8A9E-00C04F5E8CDB}' failed due to the following error: Bad variable type. (Exception from HRESULT: 0x80020008 (DISP_E_BADVARTYPE)).

This occurs in both VS2010 Pro, and VS2013 Express.
To reproduce, use the following code in a vb.net project referencing AlibreX.dll, run on an open assembly in GeoMagic:

Dim oHook As IAutomationHook = GetObject(, "AlibreX.AutomationHook")
Dim oRoot As IADRoot = oHook.Root
Dim oSession As IADDesignSession = oRoot.TopmostSession
Dim oTransform As IADTransformation = oSession.ViewTransform

The last line will fail.

Also, calls to SetViewTransform don't seem to do anything.

Ta!

Jake.
 

heyheyjc

Member
Thanks Ralf, but it's completely internal to Geomagic (at least as far as I know).

Travis, you monitoring this forum?

J
 
Top