乐筑天下

搜索
欢迎各位开发者和用户入驻本平台 尊重版权,从我做起,拒绝盗版,拒绝倒卖 签到、发布资源、邀请好友注册,可以获得银币 请注意保管好自己的密码,避免账户资金被盗
查看: 43|回复: 2

求助方法AddPolyfaceMesh得用法?

[复制链接]

2

主题

14

帖子

6

银币

初来乍到

Rank: 1

铜币
22
发表于 2006-2-13 22:06:00 | 显示全部楼层 |阅读模式
不明白后面点和面是怎么组合的?
回复

使用道具 举报

124

主题

837

帖子

9

银币

顶梁支柱

Rank: 50Rank: 50

铜币
1333
发表于 2006-2-13 22:52:00 | 显示全部楼层
&ltRE class=Code>这是AutoCAD帮助中的例子:&ltRE class=Code>
  1. Sub Example_AddPolyfaceMesh()
  2.    
  3.     Dim vertexList(0 To 17) As Double    'Data
  4.     vertexList(0) = 4: vertexList(1) = 7: vertexList(2) = 0
  5.     vertexList(3) = 5: vertexList(4) = 7: vertexList(5) = 0
  6.     vertexList(6) = 6: vertexList(7) = 7: vertexList(8) = 0
  7.     vertexList(9) = 4: vertexList(10) = 6: vertexList(11) = 0
  8.     vertexList(12) = 5: vertexList(13) = 6: vertexList(14) = 0
  9.     vertexList(15) = 6: vertexList(16) = 6: vertexList(17) = 1
  10.         Dim FaceList(0 To 7) As Integer    FaceList(0) = 1
  11.     FaceList(1) = 2
  12.     FaceList(2) = 5
  13.     FaceList(3) = 4
  14.     FaceList(4) = 2
  15.     FaceList(5) = 3
  16.     FaceList(6) = 6
  17.     FaceList(7) = 5    Dim obj As AcadPolyfaceMesh
  18.     Set obj = ModelSpace.AddPolyfaceMesh(vertexList, FaceList)
  19.     obj.Update    ' Change the viewing direction of the viewport to
  20.     ' better see the polyface mesh
  21.     Dim NewDirection(0 To 2) As Double
  22.     NewDirection(0) = -1: NewDirection(1) = -1: NewDirection(2) = 1
  23.     ThisDrawing.ActiveViewport.direction = NewDirection
  24.     ThisDrawing.ActiveViewport = ThisDrawing.ActiveViewport
  25.     ZoomAll
  26. End Sub
回复

使用道具 举报

2

主题

14

帖子

6

银币

初来乍到

Rank: 1

铜币
22
发表于 2006-2-14 08:27:00 | 显示全部楼层
谢谢帮忙,看懂了!
回复

使用道具 举报

发表回复

您需要登录后才可以回帖 登录 | 立即注册

本版积分规则

  • 微信公众平台

  • 扫描访问手机版

  • 点击图片下载手机App

QQ|关于我们|小黑屋|乐筑天下 繁体中文

GMT+8, 2025-7-5 00:50 , Processed in 0.404840 second(s), 58 queries .

© 2020-2025 乐筑天下

联系客服 关注微信 帮助中心 下载APP 返回顶部 返回列表