|
马上注册,结交更多同行朋友,交流,分享,学习。
您需要 登录 才可以下载或查看,没有帐号?注册
x
我最近在UG平台上做逆向工程的二次开发,需要把点云数据显示在UG界面上,怎么做都显示不出来,实在想不出来办法了,所以在这里向各位高手请教,帮我看一下下面的一段程序:谢谢!
我的邮箱:libo_conquer@163.com
void DisplayDialog()
{
AFX_MANAGE_STATE(AfxGetStaticModuleState());
FILE *myfile;
double solid_pnts_in[3];
double solid_pnts_out[3];
tag_t point;
tag_t points;
tag_t feature_tag;
myfile = fopen("D:\\a1.dat", "r+"); // 打开文件
rewind(myfile);
while (!feof(myfile))
{
fscanf(myfile, "%f %f %f\n", &solid_pnts_in[0], &solid_pnts_in[1],
&solid_pnts_in[2]);
solid_pnts_out[0] = (double)solid_pnts_in[0];
solid_pnts_out[1] = (double)solid_pnts_in[1];
solid_pnts_out[2] = (double)solid_pnts_in[2];
UF_CURVE_create_point(solid_pnts_out, &point);
UF_MODL_create_points_feature(1,&points, &feature_tag);
}
fclose(myfile);
} |
|