- 积分
- 5172
- 明经币
- 个
- 注册时间
- 2003-4-18
- 在线时间
- 小时
- 威望
-
- 金钱
- 个
- 贡献
-
- 激情
-
|
You can directly call lisp function from ObjectARX application using acedInvoke(...).
See example:
=========LISP code start============== (defun myfun() (setq myfunret 2) ) ; ; If you want to be able to invoke this function from an external ObjectARX ; application, you can use vl-acad-defun to make the function accessible. ; (vl-acad-defun 'myfun) =========LISP code end===============
=========C++ code start============== int call_lisp_function(void) { resbuf *rb_in = acutBuildList(RTSTR,"myfun",RTNONE); resbuf *rb_out = NULL; int rc = acedInvoke(rb_in,&rb_out); acutRelRb(rb_in); acutRelRb(rb_out); acedGetSym("myfunret",&rb_out); return (RSRSLT) ; }
=========C++ code end===============
|
|