Category : Printer + Display Graphics
Archive   : SPIN.ZIP
Filename : BEDROOM.PAS

 
Output of file : BEDROOM.PAS contained in archive : SPIN.ZIP
Program Bedroom;

(* This program generates an AcroSpin file called BEDROOM.FIL that displays *)
(* a bedroom and closet. You can change the colors by changing the following *)
(* constants. *)
(* David B. Parker *)

(* Constants. *)

Const BedroomColor = 12; (* Color of the bedroom. *)
ClosetColor = 14; (* Color of the closet. *)
EndPoints = 36; (* Total number of endpoints. *)
Lines = 48; (* Total number of lines. *)

(* Types. *)

Type PointArrayType = Array[1..EndPoints,1..3] Of Integer;
LineArrayType = Array[1..Lines,1..3] Of Integer;

(* Coordinates of endpoints. *)

Const PointArray: PointArrayType = (
(*1*) (3960,7872,0),
(*2*) (3960,12032,0),
(*3*) (-768,12032,0),
(*4*) (-768,6760,0),
(*5*) (24,6760,0),
(*6*) (2008,6760,0),
(*7*) (3960,6760,0),
(*8*) (3960,6912,0),
(*9*) (24,6592,0),
(*10*) (-768,6592,0),
(*11*) (-768,5416,0),
(*12*) (2976,5416,0),
(*13*) (2976,6592,0),
(*14*) (2008,6592,0),
(*15*) (3960,7872,3072),
(*16*) (3960,12032,3072),
(*17*) (-768,12032,3072),
(*18*) (-768,6760,3072),
(*19*) (24,6760,3072),
(*20*) (2008,6760,3072),
(*21*) (3960,6760,3072),
(*22*) (3960,6912,3072),
(*23*) (24,6592,3072),
(*24*) (-768,6592,3072),
(*25*) (-768,5416,3072),
(*26*) (2976,5416,3072),
(*27*) (2976,6592,3072),
(*28*) (2008,6592,3072),
(*29*) (2176,12032,864), (* Rear bedroom window. *)
(*30*) (1056,12032,864),
(*31*) (1056,12032,2544),
(*32*) (2176,12032,2544),
(*33*) (-768,10112,864), (* Side bedroom window. *)
(*34*) (-768,8608,864),
(*35*) (-768,8608,2544),
(*36*) (-768,10112,2544) );

(* List of lines. *)

LineArray: LineArrayType = (
(*1*) (1,2,BedroomColor),
(*2*) (2,3,BedroomColor),
(*3*) (3,4,BedroomColor),
(*4*) (4,5,BedroomColor),
(*5*) (6,7,BedroomColor),
(*6*) (7,8,BedroomColor),
(*7*) (5,9,ClosetColor),
(*8*) (9,10,ClosetColor),
(*9*) (10,11,ClosetColor),
(*10*) (11,12,ClosetColor),
(*11*) (12,13,ClosetColor),
(*12*) (13,14,ClosetColor),
(*13*) (14,6,ClosetColor),
(*14*) (15,16,BedroomColor),
(*15*) (16,17,BedroomColor),
(*16*) (17,18,BedroomColor),
(*17*) (18,19,BedroomColor),
(*18*) (20,21,BedroomColor),
(*19*) (21,22,BedroomColor),
(*20*) (19,23,ClosetColor),
(*21*) (23,24,ClosetColor),
(*22*) (24,25,ClosetColor),
(*23*) (25,26,ClosetColor),
(*24*) (26,27,ClosetColor),
(*25*) (27,28,ClosetColor),
(*26*) (28,20,ClosetColor),
(*27*) (1,15,BedroomColor),
(*28*) (2,16,BedroomColor),
(*29*) (3,17,BedroomColor),
(*30*) (4,18,BedroomColor),
(*31*) (5,19,BedroomColor),
(*32*) (6,20,BedroomColor),
(*33*) (7,21,BedroomColor),
(*34*) (8,22,BedroomColor),
(*35*) (9,23,ClosetColor),
(*36*) (10,24,ClosetColor),
(*37*) (11,25,ClosetColor),
(*38*) (12,26,ClosetColor),
(*39*) (13,27,ClosetColor),
(*40*) (14,28,ClosetColor),
(*41*) (29,30,BedroomColor), (* Rear bedroom window. *)
(*42*) (30,31,BedroomColor),
(*43*) (31,32,BedroomColor),
(*44*) (32,29,BedroomColor),
(*45*) (33,34,BedroomColor), (* Side bedroom window. *)
(*46*) (34,35,BedroomColor),
(*47*) (35,36,BedroomColor),
(*48*) (36,33,BedroomColor) );

(* Variables. *)

Var I : Integer; (* Looping variable. *)
Output: Text; (* Output file. *)

(* Include the subroutine that writes out text. *)

{$I WRITETEX.PAS}

(* Open the output file for writing. *)

Begin
Assign(Output,'BEDROOM.FIL');
Rewrite(Output);

(* Write out the endpoints for the bedroom and closet. *)

For I := 1 To EndPoints Do
Writeln(Output,'EndPoint X ',PointArray[I,1],
' Y ',PointArray[I,2],
' Z ',PointArray[I,3],
' Name P',I);

(* Write out the lines for the bedroom and closet. *)

For I := 1 To Lines Do
Writeln(Output,'Line From P',LineArray[I,1],
' To P',LineArray[I,2],' Color ',LineArray[I,3]);

(* Write out the words bedroom and closet. *)

WriteText( BedRoomColor,
200.0,200.0,
0.0,0.0,0.0,
700.0,9000.0,0.0,
'Bedroom');
WriteText( ClosetColor,
200.0,200.0,
0.0,0.0,0.0,
400.0,5900.0,0.0,
'Closet');

(* Close the output file. *)

Close(Output);
End.


  3 Responses to “Category : Printer + Display Graphics
Archive   : SPIN.ZIP
Filename : BEDROOM.PAS

  1. Very nice! Thank you for this wonderful archive. I wonder why I found it only now. Long live the BBS file archives!

  2. This is so awesome! 😀 I’d be cool if you could download an entire archive of this at once, though.

  3. But one thing that puzzles me is the “mtswslnkmcjklsdlsbdmMICROSOFT” string. There is an article about it here. It is definitely worth a read: http://www.os2museum.com/wp/mtswslnk/