home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
AmigActive 6
/
AACD06.ISO
/
AACD
/
WebSites
/
Sites
/
Imagine
/
arexx
/
mpwe.lha
/
MakePathWithEdges.irx
Wrap
Text File
|
1997-04-12
|
3KB
|
111 lines
/*==============================================================================
$VER: MakePathWithEdges.irx 0.1 (20.01.97)
© : NasGûl
nasgul@faws.org
Auteur: André Capus
Usage : Interne Imagine
Commandes AmigaDos:
Libraries Arexx:
Commentaires:
©©©©©©©©©©©©©©©©©©©©©©©©©©©©©©©©©©
© ©© ©© ©©©© ©© ©©
© ©©©©©© ©©© © © © © ©©©©©©
© ©©© © © © ©© ©©
© ©©©©©© ©©© © ©©©©©© ©
© ©©©©©© ©©© ©© ©© ©©© ©©
©©©©©©©©©©©©©©©©©©©©©©©©©©©©©©©©©©
(French Amiga Web Server)
nasgul@faws.org
http://www.faws.org
==============================================================================*/
/*=== name of oublic screen of Imagine ===*/
psname=GetEnv(IMAGINE_PSNAME)
Address 'Imagine.1'
'DISPLAYREXXPTR ON'
'GETGEOMETRY'
if EDGE_NUM='EDGE_NUM' then
do
'NOTIFY You Must select an object !'
'DISPLAYREXXPTR OFF'
Call PostMsg()
'DISPLAYREDRAW'
Exit
end
'UNPICK'
'MULTIPICKOFF'
nbrsedg=Compress(EDGE_NUM,'0'x)
DO i=1 TO nbrsedg
num_fpts=compress(EDGE_1.i,'0'x)
fpts_x=Compress(PNT_X.num_fpts,'0'x)
fpts_y=Compress(PNT_Y.num_fpts,'0'x)
fpts_z=Compress(PNT_Z.num_fpts,'0'x)
num_spts=Compress(EDGE_2.i,'0'x)
spts_x=Compress(PNT_X.num_spts,'0'x)
spts_y=Compress(PNT_Y.num_spts,'0'x)
spts_z=Compress(PNT_Z.num_spts,'0'x)
vector_x.i=spts_x-fpts_x
vector_y.i=spts_y-fpts_y
vector_z.i=spts_z-fpts_z
distance=trunc(sqrt((spts_x-fpts_x)**2+(spts_y-fpts_y)**2+(spts_z-fpts_z)**2),4)
'CALC_VECTORALIGNMENT 'vector_x.i' ' vector_y.i' 'vector_z.i''
'ADDAXIS'
'PICK'
'SELECT'
'GETATTRIBUTES OBJECTNAME'
ATTRIB.OBJECTNAME='PATH_AXIS.'i
'SETATTRIBUTES OBJECTNAME'
'DISPLAYSTOPREDRAW'
'TRANSFORM_ALIGNMENT 'IMAGINEVEC.0' 'IMAGINEVEC.1' 'IMAGINEVEC.2
TRANSFORM_POSITION fpts_x fpts_y fpts_z
'UNPICK'
END
'SELECT HOME'
'PICK'
'GETATTRIBUTES OBJECTNAME'
ATTRIB.OBJECTNAME='PATH_AXIS_GABA'
'SETATTRIBUTES OBJECTNAME'
'SELECT NEXT'
'MULTIPICKON'
DO i=1 TO nbrsedg
'PICK'
'SELECT NEXT'
END
'UNPICK SELECT'
type=Request(100,100,'Quel type pour ce path',,'Ouvert','Fermer',psname)
if type='OKAY' then
'MAKEPATH'
else
'MAKECLOSEDPATH'
'GETATTRIBUTES OBJECTNAME'
newname=Request(100,100,'nom pour ce Path','',,,psname)
ATTRIB.OBJECTNAME=newname
'SETATTRIBUTES OBJECTNAME'd
'MULTIPICKOFF'
'DISPLAYREXXPTR OFF'
'KEY_SPACE'
exit