zoukankan      html  css  js  c++  java
  • NX二次开发-UFUN计时函数UF_begin_timer

     1 NX9+VS2012    
     2     
     3     #include <uf.h>
     4     #include <uf_modl.h>
     5 
     6 
     7     UF_initialize();
     8 
     9     //计时开始
    10     UF_timer_t  Timer;
    11     UF_begin_timer(&Timer);
    12 
    13 
    14     //创建块
    15     UF_FEATURE_SIGN sign = UF_NULLSIGN;
    16     double corner_pt[3] = { 0.0, 0.0, 0.0 };
    17     char * edge_len[3] = { "100", "100", "100" };
    18     tag_t blk_obj_id = NULL_TAG;
    19     UF_MODL_create_block1(sign, corner_pt, edge_len, &blk_obj_id);
    20 
    21     //结束计时
    22     UF_timer_values_t ValueTimer;
    23     UF_end_timer(Timer, &ValueTimer);
    24 
    25 
    26     //打印信息
    27     char msg[256];
    28     UF_UI_open_listing_window();
    29     sprintf(msg,"cpu_time:%f
    real_time:%f", ValueTimer.cpu_time, ValueTimer.real_time);
    30     UF_UI_write_listing_window(msg);
    31 
    32 
    33     UF_terminate();
    34     
    35     Caesar
    36     2018年10月21日

  • 相关阅读:
    ansible-乱
    linux-PXE-12
    linux-ntp-10
    linux-selinxu---性能 -8
    linux-系统启动流程-7
    linux-网络管理-6
    linux-文件系统-5
    linux-包管理器-4
    linux-shell脚本基础-2
    linux-history-ps1-1
  • 原文地址:https://www.cnblogs.com/nxopen2018/p/10957135.html
Copyright © 2011-2022 走看看