cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
Showing results for 
Search instead for 
Did you mean: 

Community Tip - Need help navigating or using the PTC Community? Contact the community team. X

Retrieving pan and zoom factor data for all combined states of a Creo model

DO_1054494
7-Bedrock

Retrieving pan and zoom factor data for all combined states of a Creo model

Hello.

 

I am using Pro/TOOLKIT in a Windows executable application to analyze the current CAD file opened in a Creo 8.0.2.0 session.

Here there is a skeleton of the used functions.

 

ProEngineerConnect() ;

ProMdlCurrentGet() ;

if (ProMdlCombstatesGet(ProSolid(Model), &arCombinedStates) == PRO_TK_NO_ERROR &&
ProArraySizeGet(arCombinedStates, &iNumberOfCombinedStates) == PRO_TK_NO_ERROR)

{
for (int iCombinedState = 0; iCombinedState < iNumberOfCombinedStates; iCombinedState++)

{
AnalyzeCombinedState(Model, arCombinedStates[iCombinedState]);

}

}

 

void AnalyzeCombinedState(const ProMdl Model, ProCombstate CombinedState)
{

if (ProCombstateDataGet(&CombinedState, sName, &arItems, &iCrossSectionClipOption, &bExploded) == PRO_TK_NO_ERROR &&
ProArraySizeGet(arItems, &iNumberOfItems) == PRO_TK_NO_ERROR)
for (int iItem = 0; iItem < iNumberOfItems; iItem++)
switch (arItems[iItem].type)
{
case PRO_VIEW:
ProView View;
ProMatrix Matrix;

if (ProViewFromModelitemGet(&arItems[iItem], &View) == PRO_TK_NO_ERROR &&
ProViewMatrixGet(Model, View, Matrix) == PRO_TK_NO_ERROR)
{

 

At this point, I got the transformation matrix "Matrix" of the view attached to the combined state "CombinedState".

But, how can I retrieve the pan and zoom factor data attached to this combined state ???

 

ProWindowCurrentMatrixGet() can not be applied because it works on the current window and, in my case, I need the pan an zoom factor data of all the combined states, whatever the current window is.

 

Thank you for your help.

Regards.

 

0 REPLIES 0
Top Tags