Exit
  • Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
  • 한국 커뮤니티
0

PathFinder and GetPluginArtResultArt

Enthusiast ,
May 12, 2009 May 12, 2009

Could anybody give me information about pathfinder and how this tool does work!

I am trying to export the result art of paths after having joining them with pathfinder (without Expand).

The resulted object is a kPluginArt. I do not care about EditGroup, So I retrieve the ResultGroup

and then do a treewalk to export each child of this group. The structure is correct, but paths do not have style.

(No stroke, no fill).

If I use Distortion Tool on paths, the resulted object will be a kPluginArt. If I do the same operations as explained above, this

will work.path of the resulted group will have style.

So, what is the difference between those plugins?

And what could I do to retrieve style of resultArt' paths for pathfinder tool.

Thx,

Thomas.

TOPICS
SDK
1.5K
Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines

correct answers 1 Correct answer

Guide , May 20, 2009 May 20, 2009

What are the properties of the result group in the pathfinder example? You've got the path information showing for the path, but not for its parent. Alternately, I'd check the PluginArt itself. You can stick those stroke & fill properties on the damnedest things (even layers I think!) and it all trickles down. If its rendering with those colours, something has the stroke & fill set, you just need to climb up from the art parent-by-parent until you find out who.

Translate
Adobe
Guide ,
May 12, 2009 May 12, 2009

This is just a guess, but the style may be on the result group object. You can verify this behaviour for yourself fairly easily -- create two paths and then group them. Select the group and assign a style. You should see that the paths don't change. Now individually select the paths and use the Appearance panel to delete their stroke & fill. As you do so, you should see the inherited style 'shine through'.

That may be what's happening in your pathfinder example. If that doesn't help, let me know and maybe we can figure this out together.

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Enthusiast ,
May 13, 2009 May 13, 2009

I have made  screen captures for each example. (Pathfinder, Distortion). The Artwork Browser showing the structure and helping me for debugging.

On each capture, I have underlined what is important for me. (ResultGrp' children), and artstyle of this children.

As you could notice, in the pathfinder example, there is no Fill and Stroke (for the underlined path).

Whereas in the other example, there is one.

So, using only the resultGrp, in the pathfinder example, is it possible to retrieve the correct fill and stroke?

PS: I hope being clear!

Thomas.

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Guide ,
May 20, 2009 May 20, 2009

What are the properties of the result group in the pathfinder example? You've got the path information showing for the path, but not for its parent. Alternately, I'd check the PluginArt itself. You can stick those stroke & fill properties on the damnedest things (even layers I think!) and it all trickles down. If its rendering with those colours, something has the stroke & fill set, you just need to climb up from the art parent-by-parent until you find out who.

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Enthusiast ,
May 25, 2009 May 25, 2009
LATEST

I have found a solution to solve my problem.

As you said, I check "plugin" to retrieve styledArt, and export styledArt instead of resultGrp childs.

Here it is some lines, which might be helpful (or not 😞

1: retrieve plugin revision number.

            long major, minor = 0;
            result = sAIPluginGroup->GetPluginArtVersion(art, &major, &minor);
            aisdk::check_ai_error(result);       

2: get plugin name.

            char* pluginName;
            result = sAIPluginGroup->GetPluginArtName(art, &pluginName);
            aisdk::check_ai_error(result);           

3: check if Pathfinder v1.0 is used, if so, do stuff.

            string strPluginName(pluginName);
            int equal = strPluginName.compare("Pathfinder Suite");
            if(equal == 0 && major == 1)
            {
                //retrieve  Styled Art.
                AIArtHandle styledArt;
                result = sAIArtStyle->GetStyledArt(art, &styledArt);
                aisdk::check_ai_error(result);

                //if(styledArt != art)
                {                   
                    GraphicGroup* styledArtGroup = new GraphicGroup();
                    result = styledArtGroup->SetArt(styledArt);
                    aisdk::check_ai_error(result);

                    // Do a recursive treewalk.

                    result = ProcessArtwork::ProcessNode(styledArt, group, false);   
                    aisdk::check_ai_error(result);
                }
            }

I guess this is not the most beautiful way to do that, but it works.

Thx, Thomas

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines