<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Is there another way to remove entities from selection set when user box select? in ObjectARX Forum</title>
    <link>https://forums.autodesk.com/t5/objectarx-forum/is-there-another-way-to-remove-entities-from-selection-set-when/m-p/12223453#M1458</link>
    <description>&lt;LI-CODE lang="cpp"&gt;void CMyAcEdSSGetFilter::ssgetAddFilter(int ssgetFlags, AcEdSelectionSetService&amp;amp; service, 
	const AcDbObjectIdArray&amp;amp; selectionSet, const AcDbObjectIdArray&amp;amp; subSelectionSet)
{
	auto stampBeg = std::chrono::steady_clock::now();
	AcGeIntArray arr;
	//arr.setLogicalLength(subSelectionSet.length());
	for (auto i = 0; i &amp;lt; subSelectionSet.length(); i++)
	{
		service.remove(i);
	}
	//service.remove(arr);
	auto stampEnd = std::chrono::steady_clock::now();
	double time_second = std::chrono::duration&amp;lt;double&amp;gt;(stampEnd - stampBeg).count();
}&lt;/LI-CODE&gt;&lt;P&gt;up code sample is worked. But from test case ：remove all 260000 entities in Autocad2018 costs 15 second. It's NOT&amp;nbsp;&lt;/P&gt;&lt;P&gt;acceptable.&lt;/P&gt;&lt;P&gt;Is there another way to remove entities by filters? like filter by AcRxClass?&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Thu, 07 Sep 2023 01:59:20 GMT</pubDate>
    <dc:creator>xiaozhihui1992</dc:creator>
    <dc:date>2023-09-07T01:59:20Z</dc:date>
    <item>
      <title>Is there another way to remove entities from selection set when user box select?</title>
      <link>https://forums.autodesk.com/t5/objectarx-forum/is-there-another-way-to-remove-entities-from-selection-set-when/m-p/12223453#M1458</link>
      <description>&lt;LI-CODE lang="cpp"&gt;void CMyAcEdSSGetFilter::ssgetAddFilter(int ssgetFlags, AcEdSelectionSetService&amp;amp; service, 
	const AcDbObjectIdArray&amp;amp; selectionSet, const AcDbObjectIdArray&amp;amp; subSelectionSet)
{
	auto stampBeg = std::chrono::steady_clock::now();
	AcGeIntArray arr;
	//arr.setLogicalLength(subSelectionSet.length());
	for (auto i = 0; i &amp;lt; subSelectionSet.length(); i++)
	{
		service.remove(i);
	}
	//service.remove(arr);
	auto stampEnd = std::chrono::steady_clock::now();
	double time_second = std::chrono::duration&amp;lt;double&amp;gt;(stampEnd - stampBeg).count();
}&lt;/LI-CODE&gt;&lt;P&gt;up code sample is worked. But from test case ：remove all 260000 entities in Autocad2018 costs 15 second. It's NOT&amp;nbsp;&lt;/P&gt;&lt;P&gt;acceptable.&lt;/P&gt;&lt;P&gt;Is there another way to remove entities by filters? like filter by AcRxClass?&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 07 Sep 2023 01:59:20 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/objectarx-forum/is-there-another-way-to-remove-entities-from-selection-set-when/m-p/12223453#M1458</guid>
      <dc:creator>xiaozhihui1992</dc:creator>
      <dc:date>2023-09-07T01:59:20Z</dc:date>
    </item>
    <item>
      <title>Re: Is there another way to remove entities from selection set when user box select?</title>
      <link>https://forums.autodesk.com/t5/objectarx-forum/is-there-another-way-to-remove-entities-from-selection-set-when/m-p/12223819#M1459</link>
      <description>&lt;P&gt;have you tried acedSSDel? have a look at ArxDbgSelSet in ARXDBG&lt;/P&gt;</description>
      <pubDate>Thu, 07 Sep 2023 06:41:32 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/objectarx-forum/is-there-another-way-to-remove-entities-from-selection-set-when/m-p/12223819#M1459</guid>
      <dc:creator>daniel_cadext</dc:creator>
      <dc:date>2023-09-07T06:41:32Z</dc:date>
    </item>
    <item>
      <title>Re: Is there another way to remove entities from selection set when user box select?</title>
      <link>https://forums.autodesk.com/t5/objectarx-forum/is-there-another-way-to-remove-entities-from-selection-set-when/m-p/12223894#M1460</link>
      <description>&lt;P&gt;May be, I raise a conflict with this problem.&amp;nbsp;&lt;/P&gt;&lt;P&gt;I am NOT use acedSSGet api or raise a command to lead user pick , but the&amp;nbsp;&lt;/P&gt;&lt;DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;command in "Quiescent State" . There NO command running, then user pick.&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;I want to remove the entities before the entities put into the pick first selection set.&lt;/SPAN&gt;&lt;/DIV&gt;&lt;/DIV&gt;</description>
      <pubDate>Thu, 07 Sep 2023 07:22:59 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/objectarx-forum/is-there-another-way-to-remove-entities-from-selection-set-when/m-p/12223894#M1460</guid>
      <dc:creator>xiaozhihui1992</dc:creator>
      <dc:date>2023-09-07T07:22:59Z</dc:date>
    </item>
    <item>
      <title>Re: Is there another way to remove entities from selection set when user box select?</title>
      <link>https://forums.autodesk.com/t5/objectarx-forum/is-there-another-way-to-remove-entities-from-selection-set-when/m-p/12224669#M1461</link>
      <description>&lt;P&gt;In your code&lt;/P&gt;
&lt;LI-CODE lang="cpp"&gt;for (auto i = 0; i &amp;lt; subSelectionSet.length(); i++)
	service.remove(i);&lt;/LI-CODE&gt;
&lt;P&gt;you are calling&amp;nbsp;&lt;FONT face="courier new,courier"&gt;AcEdSelectionSetService::remove(int index)&lt;/FONT&gt;.&lt;/P&gt;
&lt;P&gt;But there is also the method&amp;nbsp;&lt;FONT face="courier new,courier"&gt;AcEdSelectionSetService::remove(const AcArray&amp;lt;int&amp;gt;&amp;amp; indices)&lt;/FONT&gt;, which might be more performant. Try this:&lt;/P&gt;
&lt;LI-CODE lang="cpp"&gt;AcArray&amp;lt;int&amp;gt; indices;
int count = subSelectionSet.length();
indices.setLogicalLength(count);
for (int i = 0; i &amp;lt; count; i++)
	indices[i] = i;
service.remove(indices);&lt;/LI-CODE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 07 Sep 2023 13:24:04 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/objectarx-forum/is-there-another-way-to-remove-entities-from-selection-set-when/m-p/12224669#M1461</guid>
      <dc:creator>tbrammer</dc:creator>
      <dc:date>2023-09-07T13:24:04Z</dc:date>
    </item>
    <item>
      <title>Re: Is there another way to remove entities from selection set when user box select?</title>
      <link>https://forums.autodesk.com/t5/objectarx-forum/is-there-another-way-to-remove-entities-from-selection-set-when/m-p/12226147#M1462</link>
      <description>&lt;P&gt;Yes.&lt;/P&gt;&lt;P&gt;Test results:&lt;/P&gt;&lt;P&gt;remove (const AcArray&amp;amp; indices)&amp;nbsp;&lt;/P&gt;&lt;P&gt;[&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp; Total entities: 264792&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp;remove costs: 15.5 sec&lt;/P&gt;&lt;P&gt;]&lt;/P&gt;&lt;P&gt;remove (int index)&lt;/P&gt;&lt;P&gt;[&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp;Total entities: 264792&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp; remove costs: 15.8 sec&lt;/P&gt;&lt;P&gt;]&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Machine：&lt;/P&gt;&lt;P&gt;windows 10 profession 10.0.19045&lt;/P&gt;&lt;P&gt;cpu: Intel core i7-10700&lt;/P&gt;&lt;P&gt;memory:&amp;nbsp; 16GB 2400MHZ&lt;/P&gt;</description>
      <pubDate>Fri, 08 Sep 2023 01:31:26 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/objectarx-forum/is-there-another-way-to-remove-entities-from-selection-set-when/m-p/12226147#M1462</guid>
      <dc:creator>xiaozhihui1992</dc:creator>
      <dc:date>2023-09-08T01:31:26Z</dc:date>
    </item>
  </channel>
</rss>

