-
Notifications
You must be signed in to change notification settings - Fork 3
/
amal_object_screen_display.cpp
92 lines (74 loc) · 1.69 KB
/
amal_object_screen_display.cpp
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
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
#include "stdafx.h"
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <vector>
#ifdef __amigaos4__
#include <proto/dos.h>
#include <libraries/retroMode.h>
#include <proto/retroMode.h>
#include <amoskittens.h>
#endif
#ifdef __linux__
#include <stdint.h>
#include "os/linux/stuff.h"
#include <retromode.h>
#include <retromode_lib.h>
#define Pritnf printf
#endif
#include "AmalCompiler.h"
#include "channel.h"
static int getMax ( void )
{
return 8;
}
static int getImage (unsigned int object)
{
return 0;
}
static int getX (unsigned int object)
{
return instance.screens[object]->scanline_x;
}
static int getY (unsigned int object)
{
return instance.screens[object]->scanline_y;
}
static void setImage (unsigned int object,int image)
{
}
static void setX (unsigned int object,int x)
{
instance.screens[object]->scanline_x = x;
retroApplyScreen( instance.screens[object], instance.video,
instance.screens[object] -> scanline_x,
instance.screens[object] -> scanline_y,
instance.screens[object] -> displayWidth,
instance.screens[object] -> displayHeight );
instance.video -> refreshAllScanlines = TRUE;
}
static void setY (unsigned int object,int y)
{
instance.screens[object]->scanline_y = y;
retroApplyScreen( instance.screens[object], instance.video,
instance.screens[object] -> scanline_x,
instance.screens[object] -> scanline_y,
instance.screens[object] -> displayWidth,
instance.screens[object] -> displayHeight );
instance.video -> refreshAllScanlines = TRUE;
}
static struct retroScreen *getScreen(unsigned int object)
{
return NULL;
}
struct channelAPI screen_display_api =
{
getMax,
getImage,
getX,
getY,
setImage,
setX,
setY,
getScreen
};