1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59
|
/*******************************************************************************
* Instrument: Demo_shape_primitives
*
* %I
* Written by: Erik B Knudsen <erkn@fysik.dtu.dk>
* Date: Feb 2018
* Origin: DTU Physics
* %INSTRUMENT_SITE: Templates
*
* Demonstration instrument of some shapes used for mcdisplay
*
* %D
* This instrument will display a cylinder, a sphere, and a box,
* when run with mcdisplay. Otherwise does nothing.
*
*
* %P
*
* %L
*
* %E
*******************************************************************************/
DEFINE INSTRUMENT Demo_shape_primitives_simple()
DECLARE
%{
%}
INITIALIZE
%{
%}
TRACE
COMPONENT origin = Progress_bar()
AT (0, 0, 0) RELATIVE ABSOLUTE
COMPONENT shape0 = Shape(radius=0.5)
AT(0,0,.5) RELATIVE PREVIOUS
COMPONENT shape1 = Shape(radius=0.5, yheight=0.5)
AT(0,0,1) RELATIVE PREVIOUS
COMPONENT shape2 = Shape(xwidth=0.25, yheight=0.8,zdepth=0.1234)
AT(0,0,1) RELATIVE PREVIOUS
COMPONENT shape5 = Shape(xwidth=0.25, yheight=0.8,zdepth=0.1234,thickness=0.06125)
AT(0,0,1) RELATIVE PREVIOUS
COMPONENT shape3 = Cone(radius=0.5, yheight=0.5)
AT(0,0,1) RELATIVE PREVIOUS
COMPONENT shape4 = Shape(radius=0.5, yheight=0.5, thickness=0.25)
AT(0,0,1) RELATIVE PREVIOUS
FINALLY
%{
%}
END
|