Initial revision
[ssr] / StraySrc / Sculptrix / apcs / s / scp_apcs
1 ;
2 ; sculptrix.s
3 ;
4 ; Sculptrix SWI interface
5 ;
6 ; © 1997-1998 Straylight
7 ;
8
9 ;----- Licensing note -------------------------------------------------------
10 ;
11 ; This file is part of Straylight's Sculptrix.
12 ;
13 ; Sculptrix is free software; you can redistribute it and/or modify
14 ; it under the terms of the GNU General Public License as published by
15 ; the Free Software Foundation; either version 2, or (at your option)
16 ; any later version.
17 ;
18 ; Sculptrix is distributed in the hope that it will be useful,
19 ; but WITHOUT ANY WARRANTY; without even the implied warranty of
20 ; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
21 ; GNU General Public License for more details.
22 ;
23 ; You should have received a copy of the GNU General Public License
24 ; along with Sculptrix. If not, write to the Free Software Foundation,
25 ; 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
26
27 ;----- Standard header ------------------------------------------------------
28
29 GET libs:header
30 GET libs:swis
31
32 GET libs:stream
33
34 ;----- Main code ------------------------------------------------------------
35
36 AREA |C$$code|,CODE,READONLY
37
38 ; --- sculptrix_redrawWindow ---
39
40 EXPORT sculptrix_redrawWindow
41 sculptrix_redrawWindow
42 MOV R12,R14
43 MOV R1,R0
44 SWI XSculptrix_RedrawWindow
45 MOVVC R0,#0
46 MOVS PC,R12
47
48 ; --- sculptrix_doSlab ---
49
50 EXPORT sculptrix_doSlab
51 sculptrix_doSlab
52 MOV R12,R14
53 SWI XSculptrix_DoSlab
54 MOVVSS PC,R12
55 CMP R3,#0
56 STRNE R2,[R3]
57 MOV R0,#0
58 MOVS PC,R12
59
60 ; --- sculptrix_slabIcon ---
61
62 EXPORT sculptrix_slabIcon
63 sculptrix_slabIcon
64 MOV R12,R14
65 SWI XSculptrix_SlabIcon
66 MOVVC R0,#0
67 MOVS PC,R12
68
69 ; --- sculptrix_unslabIcon ---
70
71 EXPORT sculptrix_unslabIcon
72 sculptrix_unslabIcon
73 MOV R12,R14
74 MOV R2,R0
75 SWI XSculptrix_UnslabIcon
76 MOVVC R0,#0
77 MOVS PC,R12
78
79 ; --- sculptrix_boundingBox ---
80
81 EXPORT sculptrix_boundingBox
82 sculptrix_boundingBox
83 MOV R12,R14
84 MOV R1,R0
85 SWI XSculptrix_BoundingBox
86 MOVVS R0,#0
87 MOVS PC,R12
88
89 ; --- sculptrix_plotIcon ---
90
91 EXPORT sculptrix_plotIcon
92 sculptrix_plotIcon
93 MOV R12,R14
94 SWI XSculptrix_PlotIcon
95 MOVVC R0,#0
96 MOVS PC,R12
97
98 ; --- sculptrix_plotGroupBox ---
99
100 EXPORT sculptrix_plotGroupBox
101 sculptrix_plotGroupBox
102 MOV R12,R14
103 MOV R3,R2
104 MOV R2,#0
105 SWI XSculptrix_PlotGroupBox
106 MOVVC R0,#0
107 MOVS PC,R12
108
109 ; --- sculptrix_setSpriteArea ---
110
111 EXPORT sculptrix_setSpriteArea
112 sculptrix_setSpriteArea
113 MOV R12,R14
114 CMP R0,#0
115 MOVEQ R0,#1
116 SWI XSculptrix_SetSpriteArea
117 MOVVC R0,#0
118 MOVS PC,R12
119
120 ; --- sculptrix_updateIcon ---
121
122 EXPORT sculptrix_updateIcon
123 sculptrix_updateIcon
124 MOV R12,R14
125 SWI XSculptrix_UpdateIcon
126 MOVVC R0,#0
127 MOVS PC,R12
128
129 ; --- sculptrix_slabColour ---
130
131 EXPORT sculptrix_slabColour
132 sculptrix_slabColour
133 MOV R12,R14
134 SWI XSculptrix_SlabColour
135 MOVVS R0,#14
136 MOVVC R0,R2
137 MOVS PC,R12
138
139 ; --- sculptrix_setConfig ---
140
141 EXPORT sculptrix_setConfig
142 sculptrix_setConfig
143 MOV R12,R14
144 SWI XSculptrix_SetConfig
145 MOVCS R0,#1
146 MOVCC R0,#0
147 MOVVS R0,#0
148 MOVS PC,R12
149
150 ; --- sculptrix_readConfig ---
151
152 EXPORT sculptrix_readConfig
153 sculptrix_readConfig
154 MOV R12,R14
155 SWI XSculptrix_ReadConfig
156 MOVVC R0,#0
157 MOVS PC,R12
158
159 ;----- That's all, folks ----------------------------------------------------
160
161 END