找回密码
 立即注册

QQ登录

只需一步,快速开始

扫一扫,访问微社区

查看: 899|回复: 0

和VPORT相关的系统变量和ARX获取的方法...

[复制链接]

已领礼包: 145个

财富等级: 日进斗金

发表于 2002-1-22 12:25:21 | 显示全部楼层 |阅读模式

马上注册,结交更多好友,享用更多功能,让你轻松玩转社区。

您需要 登录 才可以下载或查看,没有账号?立即注册

×
GETTING VIEWPORT INFORMATION
Product AUTOCAD  Author ODIET,NATHALIE
Date 01-SEP-97  Document ID 1733
Expiration date    Attachments  
Keywords ACDBVIEWPORT, VIEWPORT, ACDBGETCURVIEWPORTOBJECTID,SYTEM = VARIA

Developer Consulting Group technical solution. Autodesk confidential, for ADN members only. Please read the disclaimer

Question


How can I obtain an acdbviewport associated with the current viewport ?


Answer


In Tilemode 0, you can use acdbGetCurViewportObjectId() to obtain the
objectId of the current viewport.
In Tilemode 1, you can only obtain information about the viewports from the
system variables or from within a custom object's viewportDraw() member. I
listed the system variables of interest here along with their meaning (for
more information see the AutoCAD Command Reference) and the corresponding
AcDbViewport member function that would be used if in Tilemode =0 to get the
same data. Note that some of these variables are read-only and can only be
set using ads_command with the proper AutoCAD command.

BACKZ - back clipping plane (backClipDistance)
FRONTZ - front clipping plane (frontClipDistance)
LENSLENGTH - lens length (for perspective) (lensLength)
TARGET - camera target point (viewTarget)
VIEWCTR - the view's center (viewCenter)
VIEWDIR - view direction as vector offset of target (viewDirection)
VIEWMODE - current mode, clip, perspective, follow (isPerspectiveOn,
isFrontClipOn, isBackClipOn, isFrontClipAtEyeOn, isUcsFollowModeOn)
VIEWSIZE - current viewport height (viewHeight)
VIEWTWIST - view twist angle (twistAngle)
VSMAX - upper right corner (centerPoint,height,widht)
VSMIN    - lower left corner (centerPoint,height,widht)
GRIDMODE - grid on/off (isGridOn)
GRIDUNIT - grid increments (gridIncrement)
SNAPUNIT - snap incrments (snapIncrement)
SNAPANG - snap and grid angle (snapAngle)
SNAPBASE - snap and grid origin (snapBasePoint)
SNAPISOPAIR - which isometric plane (snapIsoPair)
SNAPMODE - snap on/off (isSnapOn)
SNAPSTYL - snap style (isSnapIsometric
UCSICON - ucs visibility (isUcsIconVisible,isUcsIconAtOrigin)
UCSFOLLOW - view plan to ucs (isUcsFollowModeOn)



Disclaimer

This information is derived from a response to a specific question sent to the Developer Consulting Group at Autodesk, and thus given its nature, is subject to change without notice. The information is provided to you on an "as is" basis, and you may use it only at your own risk. Autodesk is not responsible for its quality, nor shall it be liable for any damage or loss caused by your use of this information.

Top
论坛插件加载方法
发帖求助前要善用【论坛搜索】功能,那里可能会有你要找的答案;
如果你在论坛求助问题,并且已经从坛友或者管理的回复中解决了问题,请把帖子标题加上【已解决】;
如何回报帮助你解决问题的坛友,一个好办法就是给对方加【D豆】,加分不会扣除自己的积分,做一个热心并受欢迎的人!
您需要登录后才可以回帖 登录 | 立即注册

本版积分规则

QQ|申请友链|Archiver|手机版|小黑屋|辽公网安备|晓东CAD家园 ( 辽ICP备15016793号 )

GMT+8, 2024-12-5 03:04 , Processed in 0.402475 second(s), 31 queries , Gzip On.

Powered by Discuz! X3.5

© 2001-2024 Discuz! Team.

快速回复 返回顶部 返回列表