Copy link to clipboard
Copied
Hi Friends,
I have migrated a Plugin from CS4 to CC2018.
I have using TransformArt function for transform Group of arts from one Document into New Document.
In CS4 it was work fast.
But in CC2018 should have take more time to complete the transformation process.
Transformation should be
Sample code given in below.
artCenter.h = center.h; //artBounds.left + (artBounds.right-artBounds.left) / 2;
artCenter.v = center.v; //artBounds.bottom + (artBounds.top-artBounds.bottom) / 2;
// Move object to center.
sAIRealMath->AIRealMatrixSetTranslate(&artMatrix, -artCenter.h, -artCenter.v);
// Translate object.
sAIRealMath->AIRealMatrixConcatTranslate(&artMatrix, tx, ty);
// Rotate object.
sAIRealMath->AIRealMatrixConcatRotate(&artMatrix, theta);
// Scale object.
sAIRealMath->AIRealMatrixConcatScale(&artMatrix, sx, sy);
// Move the object back to the center.
sAIRealMath->AIRealMatrixConcatTranslate(&artMatrix, artCenter.h, artCenter.v);
result = sAITransformArt->TransformArt(art, &artMatrix, lineScale, transformFlags| kTransformChildren);
sAIDocument->RedrawDocument();
How can it be solved?
I need to improve speed of transform art function process.
Is there any difference in the TransformArt Function between CS4 and CC2018?
or
If any Preference Setting values want to change in CC2018 to improve speed?
With Regards,
Vicky.
Are you calling sAIDocument->RedrawDocument() inside a loop for every piece of art? That would probably slow it down. I don't think you need to call sAIDocument->RedrawDocument() at all. If you do need to call it, only call it once after transforming all the art.
Copy link to clipboard
Copied
Are you calling sAIDocument->RedrawDocument() inside a loop for every piece of art? That would probably slow it down. I don't think you need to call sAIDocument->RedrawDocument() at all. If you do need to call it, only call it once after transforming all the art.