View Single Post
Old 24th December 2013, 05:04 AM   #3
Andy
Administrator
Professional user
 
Andy's Avatar
 
Join Date: Jun 2003
Posts: 4,401
Default Re: Plug-in features for 3-d print modeling

You should probably use this one:

Prototype void add_undoable_change_select_mode(int newmode, char *undotext) // remembers selection and changes to new mode



Quote:
Originally Posted by jentron View Post
Is it possible to switch selection modes from C++? I don't see a prototype in the SDK header but see a few candidate functions in the binary:
  • set_new_select_mode_ui
  • set_new_select_mode
  • add_undoable_change_select_mode
  • set_select_mode_ui %s
  • set_select_mode
I assume I should do something like:
add_undoable_change_select_mode("My Plugin thing");
set_select_mode(SELECT_SURFACE);

But I don't know what the prototype should look like or which of the 4 sets is the 'best' to use?

Thanks,

Ron

(Extrude by normal switches to surface mode and leaves the new surfaces selected. I would like to emulate that. Also, in the watertightness plug-in I would like to switch to surface mode and leave any "bad" surfaces selected.)
Andy is offline   Reply With Quote