|
马上注册,结交更多同行朋友,交流,分享,学习。
您需要 登录 才可以下载或查看,没有帐号?注册
x
#include <uf.h>
#include <uf_ui.h>
#include <uf_exit.h>
#include "uf_modl.h"
extern DllExport void ufusr( char *parm, int *returnCode, int rlen )
{
/* Initialize the API environment */
if( UF_initialize() )
{
/* Failed to initialize */
return;
}
UF_FEATURE_SIGN sign = UF_NULLSIGN;
double origin[3] = {0,0,0};
char* height = "5";
char* diam = "8";
double direction[3] = {0,0,5};
tag_t cyl1;
UF_MODL_create_cyl1(sign,origin,height,diam,direction,&cyl1);
char* height2 = "50";
char* diam2 = "4";
tag_t cyl2;
UF_MODL_create_cyl1(sign,origin,height2,diam2,direction,&cyl2);
tag_t cyl_ent;
logical retain_target_body=FALSE;
logical retain_tool_body=FALSE;
UF_MODL_unite_bodies_with_retained_options (cyl1,cyl2,retain_target_body,retain_tool_body,&cyl_ent);
/* Terminate the API environment */
UF_terminate();
}
extern int ufusr_ask_unload( void )
{
return( UF_UNLOAD_IMMEDIATELY );
}
|
|