AC17 API_CircleType.origC doesn't work?
Anonymous
Not applicable
Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎2014-07-01
01:53 PM
- last edited on
‎2023-08-01
02:28 PM
by
Doreena Deng
‎2014-07-01
01:53 PM
Hey All,
I try to read out the center coordinates of a circle, but it always gives 0,0. Can anyone confirm whether it is a bug, and is there any workaround?
Thanks:
Andor
I try to read out the center coordinates of a circle, but it always gives 0,0. Can anyone confirm whether it is a bug, and is there any workaround?
Thanks:
Andor
Labels:
- Labels:
-
Add-On (C++)
2 REPLIES 2

Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎2014-07-01 03:57 PM
‎2014-07-01
03:57 PM
Hi Andor,
Thanks for pointing out this issue! Unfortunately it's a little bug, circle.origC and circle.r and others are all zero.
But it's only cosmetic bug, you can get all informations about the circle in the element.arc structure (arc.origC and arc.r).
Check out my example code:
Regards,
Tibor
Thanks for pointing out this issue! Unfortunately it's a little bug, circle.origC and circle.r and others are all zero.
But it's only cosmetic bug, you can get all informations about the circle in the element.arc structure (arc.origC and arc.r).
Check out my example code:
GSErrCode err; GS::Array<API_Guid> circleList; // Get all circles err = ACAPI_Element_GetElemList (API_CircleID, &circleList); if (err != NoError) { ErrorBeep ("ACAPI_Element_GetElemList ()", err); return; } WriteReport ("Number of total circles: %u", (GS::UIntForStdio) circleList.GetSize ()); // Enumerate circles for (GS::Array<API_Guid>::ConstIterator it = circleList.Enumerate (); it != NULL; ++it) { API_Element element; BNZeroMemory (&element, sizeof (API_Element)); element.header.typeID = API_CircleID; element.header.guid = *it; // Get informations about the circle err = ACAPI_Element_Get (&element); if (err != NoError) { ErrorBeep ("ACAPI_Element_Get ()", err); return; } WriteReport ("Circle center point: (%.2f,%.2f)", /* !!! use .arc instead of .circle !!!*/ element.arc.origC.x, element.arc.origC.y); WriteReport ("Circle radius: %.2f", /* !!! use .arc instead of .circle !!!*/ element.arc.r); }
Regards,
Tibor
Anonymous
Not applicable
Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎2014-07-01 04:03 PM
‎2014-07-01
04:03 PM
Thanks a lot. Btw circle.r works for me, only the center was the issue..