NX11+VS2013

     #include <uf.h>
#include <uf_modl.h>
#include <NXOpen/Face.hxx>
#include <uf_ui.h>
#include <NXOpen/NXObjectManager.hxx>
#include <NXOpen/Edge.hxx> UF_initialize(); //获取选择面控件选择的对象
PropertyList* FaceSelectProps = face_select0->GetProperties();
std::vector<NXOpen::TaggedObject *> Faces = FaceSelectProps->GetTaggedObjectVector("SelectedObjects");
delete FaceSelectProps;
FaceSelectProps = NULL; for (int i = ; i < Faces.size(); i++)
{
NXOpen::Face *MyFace = dynamic_cast<NXOpen::Face *>(Faces[i]); std::vector<tag_t> FaceNum;
uf_loop_p_t Loop_List;
UF_MODL_ask_face_loops(MyFace->Tag(), &Loop_List);//查询面的边界 int LoopNum;
UF_MODL_ask_loop_list_count(Loop_List, &LoopNum);//查询面的边界链表数量 int LoopChildType;
int Num1;
uf_list_p_t LoopChildList;
char msg[];
std::vector<tag_t> edge;
UF_MODL_create_list(&LoopChildList);//创建链表
for (int j = ; j < LoopNum; j++)
{
UF_MODL_ask_loop_list_item(Loop_List, j, &LoopChildType, &LoopChildList);//查询面的边界类型
if (LoopChildType == )//类型为内边界的时候
{
UF_MODL_ask_list_count(LoopChildList, &Num1);//查询链表数量 for (int n = ; n < Num1; n++)
{
tag_t objTag = NULL_TAG;
UF_MODL_ask_list_item(LoopChildList, n, &objTag);//获取链表里的tag
edge.push_back(objTag);
}
} } sprintf_s(msg, "当前有%d个孔", edge.size());
uc1601(msg, ); UF_MODL_delete_list(&LoopChildList);
UF_MODL_delete_loop_list(&Loop_List);
} UF_terminate();

NX二次开发-UFUN获取面的内外边界UF_MODL_ask_loop_list_item的更多相关文章

  1. NX二次开发-UFUN获取NX系统默认导出CGM的选项设置UF_CGM_ask_default_export_options

    文章转载自唐康林NX二次开发论坛,原文出处: http://www.nxopen.cn/thread-126-1-1.html 刚才有同学问到这个问题,如果是用NXOpen来做,直接录制一下就可以了: ...

  2. NX二次开发-UFUN获取当前导出CGM选项设置UF_CGM_ask_session_export_options

    文章转载自唐康林NX二次开发论坛,原文出处: http://www.nxopen.cn/thread-126-1-1.html 刚才有同学问到这个问题,如果是用NXOpen来做,直接录制一下就可以了: ...

  3. NX二次开发-UFUN获取环境变量路径,将环境变量转换为字符串,字符串拼接UF_translate_variable

    NX9+VS2012 #include <uf.h> UF_initialize(); //UFUN获取环境变量路径 //将环境变量转换为字符串 char* GetName = NULL; ...

  4. NX二次开发-UFUN获取系统相关信息UF_ask_system_info

    NX9+VS2012 #include <uf.h> UF_initialize(); UF_system_info_t Info; UF_ask_system_info(&Inf ...

  5. NX二次开发-UFUN获取边的光顺性UF_MODL_ask_edge_smoothness(找相切面)

    #include <uf.h> #include <uf_modl.h> #include <uf_obj.h> UF_initialize(); //获取面的所有 ...

  6. NX二次开发-UFUN获取当前所在的模块UF_ask_application_module

    NX9+VS2012 #include <uf.h> #include <NXOpen/UI.hxx> #include <NXOpen/MenuBar_MenuBarM ...

  7. NX二次开发-UFUN获取显示在NX交互界面的对象UF_OBJ_is_displayable

    NX9+VS2012 #include <uf.h> #include <uf_disp.h> #include <uf_obj.h> #include <u ...

  8. NX二次开发-UFUN获取边的端点UF_MODL_ask_edge_verts

    NX9+VS2012 #include <uf.h> #include <uf_modl.h> #include <uf_ui.h> #include <uf ...

  9. NX二次开发-UFUN获取直线的两个端点UF_CURVE_ask_line_data

    NX9+VS2012 #include <uf.h> #include <uf_obj.h> #include <uf_ui.h> UF_initialize(); ...

随机推荐

  1. mybatis xml中大于号小于号的代替

    第一种写法(1): 原符号 < <= > >= & ' "替换符号 < <= > >= & &apos; " ...

  2. JDK1.8之后的新特性和新接口

    接口的旧特性: 就特性下接口中只有: 常量(必须赋值) 抽象方法abstract(和final static private三个关键字冲突) interface Inter { //int a ; / ...

  3. 调试Android有什么错误

    项目目录的cmd调试查看有什么错误 gradlew processDebugManifest --stacktrace

  4. 深入理解Magento - 第五章 Magento资源配置

    对于任何一个更新频繁的项目来说,保持开发环境和生产环境的数据库同步是件很头疼的事情.Magento提供了一套系统,用版本化的资源迁移脚本来解决这个问题. 上一章,我们为 Helloworld Blog ...

  5. 【多线程】volatile

    Java并发编程:volatile关键字解析 volatile这个关键字可能很多朋友都听说过,或许也都用过.在Java 5之前,它是一个备受争议的关键字,因为在程序中使用它往往会导致出人意料的结果.在 ...

  6. 【LeetCode 14】最长公共前缀

    题目链接 [题解] 二分最长前缀的长度. 然后暴力把第2..n个字符串和第1个字符串的前mid个字符匹配. 还有一种比较厉害的算法. 把这n个字符串加入到字典树当中去. 然后根节点到第一个有分支的节点 ...

  7. js设计模式——1.代理模式

    js设计模式——1.代理模式 以下是代码示例 /*js设计模式——代理模式*/ class ReadImg { constructor(fileName) { this.fileName = file ...

  8. Linux启动过程的C语言代码分析

    1. main函数 参见上方http://www.cnblogs.com/long123king/p/3543872.html,代码跳转到main函数. arch/x86/boot/main.c 1: ...

  9. SQL中Truncate语法

    转自:http://www.studyofnet.com/news/555.html 本文导读:删除表中的数据的方法有delete,truncate, 其中TRUNCATE TABLE用于删除表中的所 ...

  10. scala 实现算法

    快速排序 def sort(xs: Array[Int]): Array[Int] = if (xs.length <= 1) xs else { val pivot = xs(xs.lengt ...