ETH Zuerich - Startseite
Professur für CAAD

 


caad d-arch


Caad Teaching
 

 
Bachelor of Architecture: CAAD II ss07

 
Master of Advanced Studies
in Architecture, CAAD


 
DWF-Processing
Programmieren statt Zeichnen


 
Graustufen - Ein Atlas
Schweizer Wohngebäude als XML Daten


 
DWF- Denken in Systemen:
In Collaboration with the Technical University Vienna


 
Seminarwoche:
BlowUp


 
Archiv

 
Caad Projects
 

 
Theory
 
Design
 
Building
 
Practice

 
Related pages
 

 
Swiss Federal Institute of Technology Zurich
 
Institute of Building Technology
 
Faculty of Architecture

 
Other pages

 










hbt d-arch

MAS ETH ARCH/CAAD - 2005/06 - STUDENT PAGES
Master of Advanced Studies in Architecture, Specialization in Computer Aided Architectural Design | 065-0005/6
Supervision: Prof. Dr. Ludger Hovestadt, Philipp Schaerer
Chair of CAAD, ETH Zurich





Toni Kotnik Module 1: Scripting|Mini-Assignment 2
development of a plugin for Vectorworks to move selected objects


Startbild.jpg
Select plugin and define translation vector ...



Logo_Verschheben.jpg

Move: move selected objects

PROCEDURE script1;

(* move selected objects *) 

VAR
   x1,y1 : REAL; (* coordinates of first mouse click *)
   x2,y2 : REAL; (* coordinates of second mouse click *)
   dx,dy : REAL; (* distance to move *)
   
BEGIN
   GetLine(x1,y1,x2,y2);
   dx:=x2-x1; dy:=y2-y1; 
   MoveObjs(dx,dy,TRUE,FALSE);   
END;
RUN(script1);
Verschieben2.jpg



Logo_Kopieren.jpg

Copy: move a copy of selected objects

PROCEDURE script2;

(* copy selected objects *) 

VAR
   x1,y1 : REAL; (* coordinates of first mouse click *)
   x2,y2 : REAL; (* coordinates of second mouse click *)
   dx,dy : REAL; (* distance to move *)
   
BEGIN
   GetLine(x1,y1,x2,y2);
   dx:=x2-x1; dy:=y2-y1; 
   Duplicate(dx,dy);   
END;
RUN(script2);
Kopieren1.jpg



Logo_MultiKopieren.jpg

Repeated Copies: move a copy of selected objects several times

PROCEDURE script3;

(* repeated copy of selected objects *) 

VAR
   x1,y1 : REAL; (* coordinates of first mouse click *)
   x2,y2 : REAL; (* coordinates of second mouse click *)
   dx,dy : REAL; (* distance to move *)
   n : INTEGER;   (* number of copies *)
   i : INTEGER;    (* counter *)
   
BEGIN
   n:=IntDialog('number of copies','1');
   GetLine(x1,y1,x2,y2);
   dx:=x2-x1; dy:=y2-y1; 
   FOR i:=1 TO n DO
       Duplicate(dx,dy);   
END;
RUN(script3);
MultiKopieren.jpg






Revision r1.4 - 09 Dec 2005 - 08:55 - NDSToniKotnik
Parents: NDSToniKotnik
Copyright © 1999-2003 by the contributing authors. All material on this collaboration platform is the property of the contributing authors.

This website has been archived and is no longer maintained.