乐筑天下

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

[编程交流] Filter for small parts (ssget)

[复制链接]

37

主题

264

帖子

236

银币

初露锋芒

Rank: 3Rank: 3Rank: 3

铜币
185
发表于 2022-7-5 18:09:10 | 显示全部楼层 |阅读模式
Hi there,
 
 
I am looking for a way to get rid of small volume parts in a DWG file.
In some cases we recieve the most 'dumbest' export models you can think of in DWG. Bolts and rings make the model very big and hard to handle. I did a small excercise and a small workaround will save at least 50% of the filesize! ..and loading time
 
 
Does any one can know if it is possible to filter 3D solids WITH a volume criteria?  Can anybody help me a little to set this up in a decent matter? This would really be a big help for to get this working. Especially because we sometimes want 3D DWG to be used in Revit as well. Would be very handy to have a method to make the data more LEAN and reloadable. Clash detection on this level is totally irrelevant for us!
 
 
Thanks in advance
 
 
Hans
ISOLATE SOLID.LSP
回复

使用道具 举报

8

主题

1647

帖子

1647

银币

初来乍到

Rank: 1

铜币
36
发表于 2022-7-5 18:29:28 | 显示全部楼层
You posted this question in the 3D Studio Max section. I have moved it to the Autocad 3D section: http://www.cadtutor.net/forum/forumdisplay.php?20-AutoCAD-3D-Modelling-amp-Rendering
回复

使用道具 举报

37

主题

264

帖子

236

银币

初露锋芒

Rank: 3Rank: 3Rank: 3

铜币
185
发表于 2022-7-5 18:49:08 | 显示全部楼层
I wasn't aware of that. Sorry for the inconvinience
回复

使用道具 举报

37

主题

264

帖子

236

银币

初露锋芒

Rank: 3Rank: 3Rank: 3

铜币
185
发表于 2022-7-5 18:59:33 | 显示全部楼层
First step..  
Selection set not to be based on volume but on Bounding box.
I tried Lee Mac's routine and this can work on 3D objects as well.
However, i do not know how to set the criteria (area) yet, put this in a selection set and loop it.
 
 
Kind of beyond my programming skills.
Maybe a small commercial tool would fill my needs?
Anyone know about this?
 
http://www.lee-mac.com/ssboundingbox.html
 
 
quote
 
 
"I think bounding box would be easier to obtain than volume.
Perhaps something like this (thrown together and untested):
 
(setq ObjectBoundingBox (GetBoundingBox CurrentEntityName))
(setq CompareBoundX (- (car ur) (car ll)))
(setq CompareBoundY (- (cadr ur) (cadr ll)))
(setq CompareBoundZ (- (caddr ur) (caddr ll)))
(setq ObjectVolume (* CompareBoundX CompareBoundY CompareBoundZ))
 
(defun GetBoundingBox (ent / obj)
  (setq obj (vlax-ename->vla-object ent)
     (vla-getBoundingBox obj 'll 'ur)
     (setq ll (vlax-safearray->list ll)
             ur (vlax-safearray->list ur)
      );end setq
   );end setq
);end defun
回复

使用道具 举报

8

主题

1647

帖子

1647

银币

初来乍到

Rank: 1

铜币
36
发表于 2022-7-5 19:18:06 | 显示全部楼层
Ok, I originally moved this to the Autocad 3D section, but it appears you are actually looking for help with a lisp routine? I am moving your question, again. This time to the Autolisp section: http://www.cadtutor.net/forum/forumdisplay.php?21-AutoLISP-Visual-LISP-amp-DCL
回复

使用道具 举报

发表回复

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

本版积分规则

  • 微信公众平台

  • 扫描访问手机版

  • 点击图片下载手机App

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

GMT+8, 2025-3-12 19:48 , Processed in 0.608856 second(s), 62 queries .

© 2020-2025 乐筑天下

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