Don't call InvertPixelArray with negative width and/or height.
[tangerine.git] / workbench / libs / muimaster / zunemaster_68k.c
blob72b7e36683ad4bf1fb7154d347e826a8005fb82f
1 /*
2 ** This file was automatically generated by fdtrans 51.9.
3 ** Do not edit it by hand. Instead, edit the sfd file
4 ** that was used to generate this file
5 */
7 #ifdef __USE_INLINE__
8 #undef __USE_INLINE__
9 #endif
10 #ifndef __NOGLOBALIFACE__
11 #define __NOGLOBALIFACE__
12 #endif
14 #include <exec/interfaces.h>
15 #include <exec/libraries.h>
16 #include <exec/emulation.h>
17 #include <interfaces/exec.h>
18 #include <interfaces/zunemaster.h>
19 #include <proto/zunemaster.h>
22 static inline int8 convert_int8 (uint32 x) { return x; }
23 static inline int16 convert_int16(uint32 x) { return x; }
26 STATIC ULONG stub_OpenPPC(ULONG *regarray)
28 struct Library *Base = (struct Library *) regarray[REG68K_A6/4];
29 struct ExtendedLibrary *ExtLib = (struct ExtendedLibrary *) ((ULONG)Base + Base->lib_PosSize);
30 struct LibraryManagerInterface *Self = (struct LibraryManagerInterface *) ExtLib->ILibrary;
32 return (ULONG) Self->Open(0);
34 struct EmuTrap stub_Open = { TRAPINST, TRAPTYPE, stub_OpenPPC };
36 STATIC ULONG stub_ClosePPC(ULONG *regarray)
38 struct Library *Base = (struct Library *) regarray[REG68K_A6/4];
39 struct ExtendedLibrary *ExtLib = (struct ExtendedLibrary *) ((ULONG)Base + Base->lib_PosSize);
40 struct LibraryManagerInterface *Self = (struct LibraryManagerInterface *) ExtLib->ILibrary;
42 return (ULONG) Self->Close();
44 struct EmuTrap stub_Close = { TRAPINST, TRAPTYPE, stub_ClosePPC };
46 STATIC ULONG stub_ExpungePPC(ULONG *regarray)
48 return 0UL;
50 struct EmuTrap stub_Expunge = { TRAPINST, TRAPTYPE, stub_ExpungePPC };
52 STATIC ULONG stub_ReservedPPC(ULONG *regarray)
54 return 0UL;
56 struct EmuTrap stub_Reserved = { TRAPINST, TRAPTYPE, stub_ReservedPPC };
58 static Object * stub_MUI_NewObjectAPPC(ULONG *regarray)
60 struct Library *Base = (struct Library *) regarray[REG68K_A6/4];
61 struct ExtendedLibrary *ExtLib = (struct ExtendedLibrary *) ((ULONG)Base + Base->lib_PosSize);
62 struct ZuneMasterIFace *Self = (struct ZuneMasterIFace *) ExtLib->MainIFace;
64 return Self->MUI_NewObjectA(
65 (CONST_STRPTR)regarray[8],
66 (struct TagItem *)regarray[9]
69 struct EmuTrap stub_MUI_NewObjectA = { TRAPINST, TRAPTYPE, (ULONG (*)(ULONG *))stub_MUI_NewObjectAPPC };
71 static VOID stub_MUI_DisposeObjectPPC(ULONG *regarray)
73 struct Library *Base = (struct Library *) regarray[REG68K_A6/4];
74 struct ExtendedLibrary *ExtLib = (struct ExtendedLibrary *) ((ULONG)Base + Base->lib_PosSize);
75 struct ZuneMasterIFace *Self = (struct ZuneMasterIFace *) ExtLib->MainIFace;
77 Self->MUI_DisposeObject(
78 (Object *)regarray[8]
81 struct EmuTrap stub_MUI_DisposeObject = { TRAPINST, TRAPTYPE, (ULONG (*)(ULONG *))stub_MUI_DisposeObjectPPC };
83 static LONG stub_MUI_RequestAPPC(ULONG *regarray)
85 struct Library *Base = (struct Library *) regarray[REG68K_A6/4];
86 struct ExtendedLibrary *ExtLib = (struct ExtendedLibrary *) ((ULONG)Base + Base->lib_PosSize);
87 struct ZuneMasterIFace *Self = (struct ZuneMasterIFace *) ExtLib->MainIFace;
89 return Self->MUI_RequestA(
90 (APTR)regarray[0],
91 (APTR)regarray[1],
92 (ULONG)regarray[2],
93 (CONST_STRPTR)regarray[8],
94 (CONST_STRPTR)regarray[9],
95 (CONST_STRPTR)regarray[10],
96 (APTR)regarray[11]
99 struct EmuTrap stub_MUI_RequestA = { TRAPINST, TRAPTYPE, (ULONG (*)(ULONG *))stub_MUI_RequestAPPC };
101 static APTR stub_MUI_AllocAslRequestPPC(ULONG *regarray)
103 struct Library *Base = (struct Library *) regarray[REG68K_A6/4];
104 struct ExtendedLibrary *ExtLib = (struct ExtendedLibrary *) ((ULONG)Base + Base->lib_PosSize);
105 struct ZuneMasterIFace *Self = (struct ZuneMasterIFace *) ExtLib->MainIFace;
107 return Self->MUI_AllocAslRequest(
108 (ULONG)regarray[0],
109 (struct TagItem *)regarray[8]
112 struct EmuTrap stub_MUI_AllocAslRequest = { TRAPINST, TRAPTYPE, (ULONG (*)(ULONG *))stub_MUI_AllocAslRequestPPC };
114 static BOOL stub_MUI_AslRequestPPC(ULONG *regarray)
116 struct Library *Base = (struct Library *) regarray[REG68K_A6/4];
117 struct ExtendedLibrary *ExtLib = (struct ExtendedLibrary *) ((ULONG)Base + Base->lib_PosSize);
118 struct ZuneMasterIFace *Self = (struct ZuneMasterIFace *) ExtLib->MainIFace;
120 return Self->MUI_AslRequest(
121 (APTR)regarray[8],
122 (struct TagItem *)regarray[9]
125 struct EmuTrap stub_MUI_AslRequest = { TRAPINST, TRAPTYPE, (ULONG (*)(ULONG *))stub_MUI_AslRequestPPC };
127 static VOID stub_MUI_FreeAslRequestPPC(ULONG *regarray)
129 struct Library *Base = (struct Library *) regarray[REG68K_A6/4];
130 struct ExtendedLibrary *ExtLib = (struct ExtendedLibrary *) ((ULONG)Base + Base->lib_PosSize);
131 struct ZuneMasterIFace *Self = (struct ZuneMasterIFace *) ExtLib->MainIFace;
133 Self->MUI_FreeAslRequest(
134 (APTR)regarray[8]
137 struct EmuTrap stub_MUI_FreeAslRequest = { TRAPINST, TRAPTYPE, (ULONG (*)(ULONG *))stub_MUI_FreeAslRequestPPC };
139 static LONG stub_MUI_ErrorPPC(ULONG *regarray)
141 struct Library *Base = (struct Library *) regarray[REG68K_A6/4];
142 struct ExtendedLibrary *ExtLib = (struct ExtendedLibrary *) ((ULONG)Base + Base->lib_PosSize);
143 struct ZuneMasterIFace *Self = (struct ZuneMasterIFace *) ExtLib->MainIFace;
145 return Self->MUI_Error(
148 struct EmuTrap stub_MUI_Error = { TRAPINST, TRAPTYPE, (ULONG (*)(ULONG *))stub_MUI_ErrorPPC };
150 static LONG stub_MUI_SetErrorPPC(ULONG *regarray)
152 struct Library *Base = (struct Library *) regarray[REG68K_A6/4];
153 struct ExtendedLibrary *ExtLib = (struct ExtendedLibrary *) ((ULONG)Base + Base->lib_PosSize);
154 struct ZuneMasterIFace *Self = (struct ZuneMasterIFace *) ExtLib->MainIFace;
156 return Self->MUI_SetError(
157 (LONG)regarray[0]
160 struct EmuTrap stub_MUI_SetError = { TRAPINST, TRAPTYPE, (ULONG (*)(ULONG *))stub_MUI_SetErrorPPC };
162 static struct IClass * stub_MUI_GetClassPPC(ULONG *regarray)
164 struct Library *Base = (struct Library *) regarray[REG68K_A6/4];
165 struct ExtendedLibrary *ExtLib = (struct ExtendedLibrary *) ((ULONG)Base + Base->lib_PosSize);
166 struct ZuneMasterIFace *Self = (struct ZuneMasterIFace *) ExtLib->MainIFace;
168 return Self->MUI_GetClass(
169 (CONST_STRPTR)regarray[8]
172 struct EmuTrap stub_MUI_GetClass = { TRAPINST, TRAPTYPE, (ULONG (*)(ULONG *))stub_MUI_GetClassPPC };
174 static VOID stub_MUI_FreeClassPPC(ULONG *regarray)
176 struct Library *Base = (struct Library *) regarray[REG68K_A6/4];
177 struct ExtendedLibrary *ExtLib = (struct ExtendedLibrary *) ((ULONG)Base + Base->lib_PosSize);
178 struct ZuneMasterIFace *Self = (struct ZuneMasterIFace *) ExtLib->MainIFace;
180 Self->MUI_FreeClass(
181 (struct IClass *)regarray[8]
184 struct EmuTrap stub_MUI_FreeClass = { TRAPINST, TRAPTYPE, (ULONG (*)(ULONG *))stub_MUI_FreeClassPPC };
186 static VOID stub_MUI_RequestIDCMPPPC(ULONG *regarray)
188 struct Library *Base = (struct Library *) regarray[REG68K_A6/4];
189 struct ExtendedLibrary *ExtLib = (struct ExtendedLibrary *) ((ULONG)Base + Base->lib_PosSize);
190 struct ZuneMasterIFace *Self = (struct ZuneMasterIFace *) ExtLib->MainIFace;
192 Self->MUI_RequestIDCMP(
193 (Object *)regarray[8],
194 (ULONG)regarray[0]
197 struct EmuTrap stub_MUI_RequestIDCMP = { TRAPINST, TRAPTYPE, (ULONG (*)(ULONG *))stub_MUI_RequestIDCMPPPC };
199 static VOID stub_MUI_RejectIDCMPPPC(ULONG *regarray)
201 struct Library *Base = (struct Library *) regarray[REG68K_A6/4];
202 struct ExtendedLibrary *ExtLib = (struct ExtendedLibrary *) ((ULONG)Base + Base->lib_PosSize);
203 struct ZuneMasterIFace *Self = (struct ZuneMasterIFace *) ExtLib->MainIFace;
205 Self->MUI_RejectIDCMP(
206 (Object *)regarray[8],
207 (ULONG)regarray[0]
210 struct EmuTrap stub_MUI_RejectIDCMP = { TRAPINST, TRAPTYPE, (ULONG (*)(ULONG *))stub_MUI_RejectIDCMPPPC };
212 static VOID stub_MUI_RedrawPPC(ULONG *regarray)
214 struct Library *Base = (struct Library *) regarray[REG68K_A6/4];
215 struct ExtendedLibrary *ExtLib = (struct ExtendedLibrary *) ((ULONG)Base + Base->lib_PosSize);
216 struct ZuneMasterIFace *Self = (struct ZuneMasterIFace *) ExtLib->MainIFace;
218 Self->MUI_Redraw(
219 (Object *)regarray[8],
220 (ULONG)regarray[0]
223 struct EmuTrap stub_MUI_Redraw = { TRAPINST, TRAPTYPE, (ULONG (*)(ULONG *))stub_MUI_RedrawPPC };
225 static struct MUI_CustomClass * stub_MUI_CreateCustomClassPPC(ULONG *regarray)
227 struct Library *Base = (struct Library *) regarray[REG68K_A6/4];
228 struct ExtendedLibrary *ExtLib = (struct ExtendedLibrary *) ((ULONG)Base + Base->lib_PosSize);
229 struct ZuneMasterIFace *Self = (struct ZuneMasterIFace *) ExtLib->MainIFace;
231 return Self->MUI_CreateCustomClass(
232 (struct Library *)regarray[8],
233 (CONST_STRPTR)regarray[9],
234 (struct MUI_CustomClass *)regarray[10],
235 (LONG)regarray[0],
236 (APTR)regarray[11]
239 struct EmuTrap stub_MUI_CreateCustomClass = { TRAPINST, TRAPTYPE, (ULONG (*)(ULONG *))stub_MUI_CreateCustomClassPPC };
241 static BOOL stub_MUI_DeleteCustomClassPPC(ULONG *regarray)
243 struct Library *Base = (struct Library *) regarray[REG68K_A6/4];
244 struct ExtendedLibrary *ExtLib = (struct ExtendedLibrary *) ((ULONG)Base + Base->lib_PosSize);
245 struct ZuneMasterIFace *Self = (struct ZuneMasterIFace *) ExtLib->MainIFace;
247 return Self->MUI_DeleteCustomClass(
248 (struct MUI_CustomClass *)regarray[8]
251 struct EmuTrap stub_MUI_DeleteCustomClass = { TRAPINST, TRAPTYPE, (ULONG (*)(ULONG *))stub_MUI_DeleteCustomClassPPC };
253 static Object * stub_MUI_MakeObjectAPPC(ULONG *regarray)
255 struct Library *Base = (struct Library *) regarray[REG68K_A6/4];
256 struct ExtendedLibrary *ExtLib = (struct ExtendedLibrary *) ((ULONG)Base + Base->lib_PosSize);
257 struct ZuneMasterIFace *Self = (struct ZuneMasterIFace *) ExtLib->MainIFace;
259 return Self->MUI_MakeObjectA(
260 (LONG)regarray[0],
261 (ULONG *)regarray[8]
264 struct EmuTrap stub_MUI_MakeObjectA = { TRAPINST, TRAPTYPE, (ULONG (*)(ULONG *))stub_MUI_MakeObjectAPPC };
266 static BOOL stub_MUI_LayoutPPC(ULONG *regarray)
268 struct Library *Base = (struct Library *) regarray[REG68K_A6/4];
269 struct ExtendedLibrary *ExtLib = (struct ExtendedLibrary *) ((ULONG)Base + Base->lib_PosSize);
270 struct ZuneMasterIFace *Self = (struct ZuneMasterIFace *) ExtLib->MainIFace;
272 return Self->MUI_Layout(
273 (Object *)regarray[8],
274 (LONG)regarray[0],
275 (LONG)regarray[1],
276 (LONG)regarray[2],
277 (LONG)regarray[3],
278 (ULONG)regarray[4]
281 struct EmuTrap stub_MUI_Layout = { TRAPINST, TRAPTYPE, (ULONG (*)(ULONG *))stub_MUI_LayoutPPC };
283 static LONG stub_MUI_ObtainPenPPC(ULONG *regarray)
285 struct Library *Base = (struct Library *) regarray[REG68K_A6/4];
286 struct ExtendedLibrary *ExtLib = (struct ExtendedLibrary *) ((ULONG)Base + Base->lib_PosSize);
287 struct ZuneMasterIFace *Self = (struct ZuneMasterIFace *) ExtLib->MainIFace;
289 return Self->MUI_ObtainPen(
290 (struct MUI_RenderInfo *)regarray[8],
291 (struct MUI_PenSpec *)regarray[9],
292 (ULONG)regarray[0]
295 struct EmuTrap stub_MUI_ObtainPen = { TRAPINST, TRAPTYPE, (ULONG (*)(ULONG *))stub_MUI_ObtainPenPPC };
297 static VOID stub_MUI_ReleasePenPPC(ULONG *regarray)
299 struct Library *Base = (struct Library *) regarray[REG68K_A6/4];
300 struct ExtendedLibrary *ExtLib = (struct ExtendedLibrary *) ((ULONG)Base + Base->lib_PosSize);
301 struct ZuneMasterIFace *Self = (struct ZuneMasterIFace *) ExtLib->MainIFace;
303 Self->MUI_ReleasePen(
304 (struct MUI_RenderInfo *)regarray[8],
305 (LONG)regarray[0]
308 struct EmuTrap stub_MUI_ReleasePen = { TRAPINST, TRAPTYPE, (ULONG (*)(ULONG *))stub_MUI_ReleasePenPPC };
310 static APTR stub_MUI_AddClippingPPC(ULONG *regarray)
312 struct Library *Base = (struct Library *) regarray[REG68K_A6/4];
313 struct ExtendedLibrary *ExtLib = (struct ExtendedLibrary *) ((ULONG)Base + Base->lib_PosSize);
314 struct ZuneMasterIFace *Self = (struct ZuneMasterIFace *) ExtLib->MainIFace;
316 return Self->MUI_AddClipping(
317 (struct MUI_RenderInfo *)regarray[8],
318 (WORD)convert_int16(regarray[0]),
319 (WORD)convert_int16(regarray[1]),
320 (WORD)convert_int16(regarray[2]),
321 (WORD)convert_int16(regarray[3])
324 struct EmuTrap stub_MUI_AddClipping = { TRAPINST, TRAPTYPE, (ULONG (*)(ULONG *))stub_MUI_AddClippingPPC };
326 static VOID stub_MUI_RemoveClippingPPC(ULONG *regarray)
328 struct Library *Base = (struct Library *) regarray[REG68K_A6/4];
329 struct ExtendedLibrary *ExtLib = (struct ExtendedLibrary *) ((ULONG)Base + Base->lib_PosSize);
330 struct ZuneMasterIFace *Self = (struct ZuneMasterIFace *) ExtLib->MainIFace;
332 Self->MUI_RemoveClipping(
333 (struct MUI_RenderInfo *)regarray[8],
334 (APTR)regarray[9]
337 struct EmuTrap stub_MUI_RemoveClipping = { TRAPINST, TRAPTYPE, (ULONG (*)(ULONG *))stub_MUI_RemoveClippingPPC };
339 static APTR stub_MUI_AddClipRegionPPC(ULONG *regarray)
341 struct Library *Base = (struct Library *) regarray[REG68K_A6/4];
342 struct ExtendedLibrary *ExtLib = (struct ExtendedLibrary *) ((ULONG)Base + Base->lib_PosSize);
343 struct ZuneMasterIFace *Self = (struct ZuneMasterIFace *) ExtLib->MainIFace;
345 return Self->MUI_AddClipRegion(
346 (struct MUI_RenderInfo *)regarray[8],
347 (struct Region *)regarray[9]
350 struct EmuTrap stub_MUI_AddClipRegion = { TRAPINST, TRAPTYPE, (ULONG (*)(ULONG *))stub_MUI_AddClipRegionPPC };
352 static VOID stub_MUI_RemoveClipRegionPPC(ULONG *regarray)
354 struct Library *Base = (struct Library *) regarray[REG68K_A6/4];
355 struct ExtendedLibrary *ExtLib = (struct ExtendedLibrary *) ((ULONG)Base + Base->lib_PosSize);
356 struct ZuneMasterIFace *Self = (struct ZuneMasterIFace *) ExtLib->MainIFace;
358 Self->MUI_RemoveClipRegion(
359 (struct MUI_RenderInfo *)regarray[8],
360 (APTR)regarray[9]
363 struct EmuTrap stub_MUI_RemoveClipRegion = { TRAPINST, TRAPTYPE, (ULONG (*)(ULONG *))stub_MUI_RemoveClipRegionPPC };
365 static BOOL stub_MUI_BeginRefreshPPC(ULONG *regarray)
367 struct Library *Base = (struct Library *) regarray[REG68K_A6/4];
368 struct ExtendedLibrary *ExtLib = (struct ExtendedLibrary *) ((ULONG)Base + Base->lib_PosSize);
369 struct ZuneMasterIFace *Self = (struct ZuneMasterIFace *) ExtLib->MainIFace;
371 return Self->MUI_BeginRefresh(
372 (struct MUI_RenderInfo *)regarray[8],
373 (ULONG)regarray[0]
376 struct EmuTrap stub_MUI_BeginRefresh = { TRAPINST, TRAPTYPE, (ULONG (*)(ULONG *))stub_MUI_BeginRefreshPPC };
378 static VOID stub_MUI_EndRefreshPPC(ULONG *regarray)
380 struct Library *Base = (struct Library *) regarray[REG68K_A6/4];
381 struct ExtendedLibrary *ExtLib = (struct ExtendedLibrary *) ((ULONG)Base + Base->lib_PosSize);
382 struct ZuneMasterIFace *Self = (struct ZuneMasterIFace *) ExtLib->MainIFace;
384 Self->MUI_EndRefresh(
385 (struct MUI_RenderInfo *)regarray[8],
386 (ULONG)regarray[0]
389 struct EmuTrap stub_MUI_EndRefresh = { TRAPINST, TRAPTYPE, (ULONG (*)(ULONG *))stub_MUI_EndRefreshPPC };
391 ULONG VecTable68K[] = {
392 (ULONG)&stub_Open,
393 (ULONG)&stub_Close,
394 (ULONG)&stub_Expunge,
395 (ULONG)&stub_Reserved,
396 (ULONG)&stub_MUI_NewObjectA,
397 (ULONG)&stub_MUI_DisposeObject,
398 (ULONG)&stub_MUI_RequestA,
399 (ULONG)&stub_MUI_AllocAslRequest,
400 (ULONG)&stub_MUI_AslRequest,
401 (ULONG)&stub_MUI_FreeAslRequest,
402 (ULONG)&stub_MUI_Error,
403 (ULONG)&stub_MUI_SetError,
404 (ULONG)&stub_MUI_GetClass,
405 (ULONG)&stub_MUI_FreeClass,
406 (ULONG)&stub_MUI_RequestIDCMP,
407 (ULONG)&stub_MUI_RejectIDCMP,
408 (ULONG)&stub_MUI_Redraw,
409 (ULONG)&stub_MUI_CreateCustomClass,
410 (ULONG)&stub_MUI_DeleteCustomClass,
411 (ULONG)&stub_MUI_MakeObjectA,
412 (ULONG)&stub_MUI_Layout,
413 (ULONG)&stub_Reserved,
414 (ULONG)&stub_Reserved,
415 (ULONG)&stub_Reserved,
416 (ULONG)&stub_Reserved,
417 (ULONG)&stub_MUI_ObtainPen,
418 (ULONG)&stub_MUI_ReleasePen,
419 (ULONG)&stub_MUI_AddClipping,
420 (ULONG)&stub_MUI_RemoveClipping,
421 (ULONG)&stub_MUI_AddClipRegion,
422 (ULONG)&stub_MUI_RemoveClipRegion,
423 (ULONG)&stub_MUI_BeginRefresh,
424 (ULONG)&stub_MUI_EndRefresh,
425 (ULONG)-1