Vla-get-isplanar
- 構文
- (vla-get-isplanar vla-object )
- 機能
- 指定されたスプラインが平面スプラインかどうかを決定する。
- 引数
-
- vla-object … Spline のVLAオブジェクト
- 戻り値
- ブール型
- :vlax-True: 平面スプライン。
- :vlax-False: 平面スプラインではない。
- サンプル
(vl-load-com)
(defun c:Example_IsPlanar()
;; Spline を作成して平面スプラインを取得する
(setq acadObj (vlax-get-acad-object))
(setq doc (vla-get-ActiveDocument acadObj))
;; スプラインの定義
(setq startTan (vlax-3d-point 0.5 0.5 0)
endTan (vlax-3d-point 0.5 0.5 0)
fitPoints (vlax-make-safearray vlax-vbDouble '(0 . 8)))
(vlax-safearray-fill fitPoints '(0 0 0
5 5 0
10 0 0))
;; スプラインを作成
(setq modelSpace (vla-get-ModelSpace doc))
(setq splineObj (vla-AddSpline modelSpace fitPoints startTan endTan))
(vla-ZoomAll acadObj)
;; スプラインが平面スプラインか
(setq UserMessage (if (= (vla-get-IsPlanar splineObj) :vlax-true) "is planar" "is not planar"))
(alert (strcat "The new Spline " UserMessage))
)
関連事項