Community Tip - Did you know you can set a signature that will be added to all your posts? Set it here! X
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.