THE POST BELOW IS MORE THAN 5 YEARS OLD. RELATED SUPPORT INFORMATION MIGHT BE OUTDATED OR DEPRECATED
On 10/02/2012 at 07:56, xxxxxxxx wrote:
I'm not sure if I understand you correctly.
But it sounds like you might want to use the convert tool with SMC.
Here's an example that will select the edges around the selected polygons.
The advantage to doing it this way- VS.- using the CallCommand() is you don't have to switch into edge mode first to select the edges.
import c4d
from c4d import utils
def main() :
obj = doc.GetActiveObject()
bc = c4d.BaseContainer()
bc.SetData(c4d.MDATA_CONVERTSELECTION_LEFT, 2) #ConvertSelection's Left "Polygons" option in memory
bc.SetData(c4d.MDATA_CONVERTSELECTION_RIGHT, 1) #ConvertSelection's Right "Edges" option in memory
bc.SetData(c4d.MDATA_CONVERTSELECTION_TOLERANT, True) #Select the selection->ConvertSelection's "Tolerant" option in memory
utils.SendModelingCommand(c4d.MCOMMAND_CONVERTSELECTION, list = [obj], mode = c4d.MODIFY_ALL, bc=bc, doc = doc)
if __name__=='__main__':
main()
-ScottA