Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
P
PUAE
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
PocketInsanity
PUAE
Commits
add1223e
Commit
add1223e
authored
Dec 20, 2010
by
GnoStiC
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
puae 2.3.1
parent
a2e4c835
Changes
16
Hide whitespace changes
Inline
Side-by-side
Showing
16 changed files
with
249 additions
and
162 deletions
+249
-162
bronx_.sh
bronx_.sh
+1
-0
a2091.c
src/a2091.c
+1
-1
akiko.c
src/akiko.c
+1
-1
audio.c
src/audio.c
+5
-3
bsdsocket.c
src/bsdsocket.c
+5
-3
catweasel.c
src/catweasel.c
+3
-5
cd32_fmv.c
src/cd32_fmv.c
+2
-2
cdrom.c
src/cdrom.c
+82
-82
cdtv.c
src/cdtv.c
+1
-3
custom.c
src/custom.c
+10
-28
Makefile.am
src/gui-qt/Makefile.am
+19
-5
puae_mainwindow.cpp
src/gui-qt/puae_mainwindow.cpp
+113
-16
puae_mainwindow.h
src/gui-qt/puae_mainwindow.h
+4
-0
custom.h
src/include/custom.h
+0
-1
drawing.h
src/include/drawing.h
+1
-11
events_jit.h
src/include/events_jit.h
+1
-1
No files found.
bronx_.sh
View file @
add1223e
...
@@ -5,6 +5,7 @@
...
@@ -5,6 +5,7 @@
# this is the main script to build (and test) PUAE
# this is the main script to build (and test) PUAE
#
#
base
=
" --with-sdl --with-sdl-gl --with-sdl-gfx --with-sdl-sound --enable-drvsnd "
base
=
" --with-sdl --with-sdl-gl --with-sdl-gfx --with-sdl-sound --enable-drvsnd "
wiqt
=
" "
cd32
=
" --enable-cd32 "
cd32
=
" --enable-cd32 "
a600
=
" --enable-gayle "
a600
=
" --enable-gayle "
scsi
=
" --enable-scsi-device --enable-ncr --enable-a2091 "
scsi
=
" --enable-scsi-device --enable-ncr --enable-a2091 "
...
...
src/a2091.c
View file @
add1223e
...
@@ -1363,4 +1363,4 @@ void a2091_init (void)
...
@@ -1363,4 +1363,4 @@ void a2091_init (void)
}
}
map_banks
(
&
dmaca2091_bank
,
0xe80000
>>
16
,
0x10000
>>
16
,
0x10000
);
map_banks
(
&
dmaca2091_bank
,
0xe80000
>>
16
,
0x10000
>>
16
,
0x10000
);
}
}
#endif //a2091
#endif //a2091
\ No newline at end of file
src/akiko.c
View file @
add1223e
...
@@ -1163,10 +1163,10 @@ static void akiko_internal (void)
...
@@ -1163,10 +1163,10 @@ static void akiko_internal (void)
void
AKIKO_hsync_handler
(
void
)
void
AKIKO_hsync_handler
(
void
)
{
{
unsigned
int
i
;
if
(
!
currprefs
.
cs_cd32cd
||
!
akiko_inited
)
if
(
!
currprefs
.
cs_cd32cd
||
!
akiko_inited
)
return
;
return
;
unsigned
int
i
;
static
float
framecounter
;
static
float
framecounter
;
framecounter
--
;
framecounter
--
;
if
(
framecounter
<=
0
)
{
if
(
framecounter
<=
0
)
{
...
...
src/audio.c
View file @
add1223e
...
@@ -109,7 +109,8 @@ struct audio_channel_data {
...
@@ -109,7 +109,8 @@ struct audio_channel_data {
static
int
samplecnt
;
static
int
samplecnt
;
#if SOUNDSTUFF > 0
#if SOUNDSTUFF > 0
int
extrasamples
,
outputsample
,
doublesample
;
static
int
extrasamples
;
int
outputsample
,
doublesample
;
#endif
#endif
int
sampleripper_enabled
;
int
sampleripper_enabled
;
...
@@ -292,7 +293,8 @@ int sound_available = 0;
...
@@ -292,7 +293,8 @@ int sound_available = 0;
void
(
*
sample_handler
)
(
void
);
void
(
*
sample_handler
)
(
void
);
static
void
(
*
sample_prehandler
)
(
unsigned
long
best_evtime
);
static
void
(
*
sample_prehandler
)
(
unsigned
long
best_evtime
);
float
sample_evtime
,
scaled_sample_evtime
;
static
float
sample_evtime
;
float
scaled_sample_evtime
;
static
unsigned
long
last_cycles
;
static
unsigned
long
last_cycles
;
static
float
next_sample_evtime
;
static
float
next_sample_evtime
;
...
@@ -1840,7 +1842,7 @@ void AUDxDAT (int nr, uae_u16 v, uaecptr addr)
...
@@ -1840,7 +1842,7 @@ void AUDxDAT (int nr, uae_u16 v, uaecptr addr)
do_samplerip
(
cdp
);
do_samplerip
(
cdp
);
#ifdef DEBUG_AUDIO
#ifdef DEBUG_AUDIO
if
(
debugchannel
(
nr
))
if
(
debugchannel
(
nr
))
write_log
(
"AUD%d looped, IRQ=%d, LC=%08X LEN=%d
\n
"
,
nr
,
isirq
(
nr
),
cdp
->
pt
,
cdp
->
wlen
);
write_log
(
"AUD%d looped, IRQ=%d, LC=%08X LEN=%d
\n
"
,
nr
,
isirq
(
nr
)
?
1
:
0
,
cdp
->
pt
,
cdp
->
wlen
);
#endif
#endif
}
else
{
}
else
{
cdp
->
wlen
=
(
cdp
->
wlen
-
1
)
&
0xffff
;
cdp
->
wlen
=
(
cdp
->
wlen
-
1
)
&
0xffff
;
...
...
src/bsdsocket.c
View file @
add1223e
...
@@ -24,6 +24,8 @@
...
@@ -24,6 +24,8 @@
#include "bsdsocket.h"
#include "bsdsocket.h"
#include "native2amiga.h"
#include "native2amiga.h"
#define TRUE 1
#define FALSE 0
#ifdef BSDSOCKET
#ifdef BSDSOCKET
#ifdef WIN32
#ifdef WIN32
...
@@ -154,17 +156,17 @@ BOOL checksd(SB, int sd)
...
@@ -154,17 +156,17 @@ BOOL checksd(SB, int sd)
if
(
iCounter
!=
sd
)
{
if
(
iCounter
!=
sd
)
{
if
(
getsock
(
sb
,
iCounter
)
==
s
)
{
if
(
getsock
(
sb
,
iCounter
)
==
s
)
{
releasesock
(
sb
,
sd
);
releasesock
(
sb
,
sd
);
return
1
;
return
TRUE
;
}
}
}
}
}
}
for
(
iCounter
=
0
;
iCounter
<
SOCKPOOLSIZE
;
iCounter
++
)
{
for
(
iCounter
=
0
;
iCounter
<
SOCKPOOLSIZE
;
iCounter
++
)
{
if
(
s
==
sockdata
->
sockpoolsocks
[
iCounter
])
if
(
s
==
sockdata
->
sockpoolsocks
[
iCounter
])
return
1
;
return
TRUE
;
}
}
}
}
BSDTRACE
((
"checksd FALSE s 0x%x sd %d
\n
"
,
s
,
sd
));
BSDTRACE
((
"checksd FALSE s 0x%x sd %d
\n
"
,
s
,
sd
));
return
0
;
return
FALSE
;
}
}
void
setsd
(
SB
,
int
sd
,
SOCKET_TYPE
s
)
void
setsd
(
SB
,
int
sd
,
SOCKET_TYPE
s
)
...
...
src/catweasel.c
View file @
add1223e
...
@@ -315,10 +315,8 @@ void catweasel_do_bput (uaecptr addr, uae_u32 b)
...
@@ -315,10 +315,8 @@ void catweasel_do_bput (uaecptr addr, uae_u32 b)
} else {
} else {
#endif
#endif
ioport_write
(
cwc
.
iobase
+
addr
,
b
);
ioport_write
(
cwc
.
iobase
+
addr
,
b
);
#if 0
}
}
//write_log ("P %02X %02X %d\n", (uae_u8)addr, (uae_u8)b, did_read);
//write_log ("P %02X %02X %d\n", (uae_u8)addr, (uae_u8)b, did_read);
#endif
}
}
#include "core.cw4.cpp"
#include "core.cw4.cpp"
...
@@ -422,8 +420,8 @@ fail:
...
@@ -422,8 +420,8 @@ fail:
int
catweasel_detect
(
void
)
int
catweasel_detect
(
void
)
{
{
if
(
detected
)
if
(
detected
)
return
detected
<
0
?
0
:
1
;
return
detected
<
0
?
0
:
1
;
}
}
#endif
#endif
src/cd32_fmv.c
View file @
add1223e
...
@@ -303,7 +303,7 @@ static void REGPARAM2 fmv_lput (uaecptr addr, uae_u32 w)
...
@@ -303,7 +303,7 @@ static void REGPARAM2 fmv_lput (uaecptr addr, uae_u32 w)
fmv_wput
(
addr
+
2
,
w
>>
0
);
fmv_wput
(
addr
+
2
,
w
>>
0
);
}
}
extern
addrbank
fmv_bank
;
//
extern addrbank fmv_bank;
static
void
REGPARAM2
fmv_bput
(
uaecptr
addr
,
uae_u32
w
)
static
void
REGPARAM2
fmv_bput
(
uaecptr
addr
,
uae_u32
w
)
{
{
...
@@ -370,7 +370,7 @@ static uae_u8 *REGPARAM2 fmv_xlate (uaecptr addr)
...
@@ -370,7 +370,7 @@ static uae_u8 *REGPARAM2 fmv_xlate (uaecptr addr)
return
rom
+
addr
;
return
rom
+
addr
;
}
}
addrbank
fmv_bank
=
{
static
addrbank
fmv_bank
=
{
fmv_lget
,
fmv_wget
,
fmv_bget
,
fmv_lget
,
fmv_wget
,
fmv_bget
,
fmv_lput
,
fmv_wput
,
fmv_bput
,
fmv_lput
,
fmv_wput
,
fmv_bput
,
fmv_xlate
,
fmv_check
,
NULL
,
"CD32 FMV module"
,
fmv_xlate
,
fmv_check
,
NULL
,
"CD32 FMV module"
,
...
...
src/cdrom.c
View file @
add1223e
...
@@ -119,49 +119,49 @@ static uae_u8 rs_l12_alog[255] = {
...
@@ -119,49 +119,49 @@ static uae_u8 rs_l12_alog[255] = {
static
uae_u32
build_edc
(
const
uae_u8
*
inout
,
int
from
,
int
upto
)
static
uae_u32
build_edc
(
const
uae_u8
*
inout
,
int
from
,
int
upto
)
{
{
const
uae_u8
*
p
=
inout
+
from
;
const
uae_u8
*
p
=
inout
+
from
;
uae_u32
result
=
0
;
uae_u32
result
=
0
;
for
(;
from
<=
upto
;
from
++
)
for
(;
from
<=
upto
;
from
++
)
result
=
EDC_crctable
[(
result
^
*
p
++
)
&
0xff
]
^
(
result
>>
8
);
result
=
EDC_crctable
[(
result
^
*
p
++
)
&
0xff
]
^
(
result
>>
8
);
return
result
;
return
result
;
}
}
static
void
encode_L2_Q
(
uae_u8
*
inout
)
static
void
encode_L2_Q
(
uae_u8
*
inout
)
{
{
uae_u8
*
Q
;
uae_u8
*
Q
;
int
i
,
j
;
int
i
,
j
;
Q
=
inout
+
4
+
L2_RAW
+
4
+
8
+
L2_P
;
Q
=
inout
+
4
+
L2_RAW
+
4
+
8
+
L2_P
;
memset
(
Q
,
0
,
L2_Q
);
memset
(
Q
,
0
,
L2_Q
);
for
(
j
=
0
;
j
<
26
;
j
++
)
{
for
(
j
=
0
;
j
<
26
;
j
++
)
{
for
(
i
=
0
;
i
<
43
;
i
++
)
{
for
(
i
=
0
;
i
<
43
;
i
++
)
{
uae_u8
data
;
uae_u8
data
;
/* LSB */
/* LSB */
data
=
inout
[(
j
*
43
*
2
+
i
*
2
*
44
)
%
(
4
+
L2_RAW
+
4
+
8
+
L2_P
)];
data
=
inout
[(
j
*
43
*
2
+
i
*
2
*
44
)
%
(
4
+
L2_RAW
+
4
+
8
+
L2_P
)];
if
(
data
!=
0
)
{
if
(
data
!=
0
)
{
uae_u32
base
=
rs_l12_log
[
data
];
uae_u32
base
=
rs_l12_log
[
data
];
uae_u32
sum
=
base
+
DQ
[
0
][
i
];
uae_u32
sum
=
base
+
DQ
[
0
][
i
];
if
(
sum
>=
((
1
<<
RS_L12_BITS
)
-
1
))
if
(
sum
>=
((
1
<<
RS_L12_BITS
)
-
1
))
sum
-=
(
1
<<
RS_L12_BITS
)
-
1
;
sum
-=
(
1
<<
RS_L12_BITS
)
-
1
;
Q
[
0
]
^=
rs_l12_alog
[
sum
];
Q
[
0
]
^=
rs_l12_alog
[
sum
];
sum
=
base
+
DQ
[
1
][
i
];
sum
=
base
+
DQ
[
1
][
i
];
if
(
sum
>=
((
1
<<
RS_L12_BITS
)
-
1
))
if
(
sum
>=
((
1
<<
RS_L12_BITS
)
-
1
))
sum
-=
(
1
<<
RS_L12_BITS
)
-
1
;
sum
-=
(
1
<<
RS_L12_BITS
)
-
1
;
Q
[
26
*
2
]
^=
rs_l12_alog
[
sum
];
Q
[
26
*
2
]
^=
rs_l12_alog
[
sum
];
}
}
/* MSB */
/* MSB */
data
=
inout
[(
j
*
43
*
2
+
i
*
2
*
44
+
1
)
%
(
4
+
L2_RAW
+
4
+
8
+
L2_P
)];
data
=
inout
[(
j
*
43
*
2
+
i
*
2
*
44
+
1
)
%
(
4
+
L2_RAW
+
4
+
8
+
L2_P
)];
if
(
data
!=
0
)
{
if
(
data
!=
0
)
{
uae_u32
base
=
rs_l12_log
[
data
];
uae_u32
base
=
rs_l12_log
[
data
];
uae_u32
sum
=
base
+
DQ
[
0
][
i
];
uae_u32
sum
=
base
+
DQ
[
0
][
i
];
if
(
sum
>=
((
1
<<
RS_L12_BITS
)
-
1
))
if
(
sum
>=
((
1
<<
RS_L12_BITS
)
-
1
))
sum
-=
(
1
<<
RS_L12_BITS
)
-
1
;
sum
-=
(
1
<<
RS_L12_BITS
)
-
1
;
Q
[
1
]
^=
rs_l12_alog
[
sum
];
Q
[
1
]
^=
rs_l12_alog
[
sum
];
sum
=
base
+
DQ
[
1
][
i
];
sum
=
base
+
DQ
[
1
][
i
];
if
(
sum
>=
((
1
<<
RS_L12_BITS
)
-
1
))
if
(
sum
>=
((
1
<<
RS_L12_BITS
)
-
1
))
sum
-=
(
1
<<
RS_L12_BITS
)
-
1
;
sum
-=
(
1
<<
RS_L12_BITS
)
-
1
;
Q
[
26
*
2
+
1
]
^=
rs_l12_alog
[
sum
];
Q
[
26
*
2
+
1
]
^=
rs_l12_alog
[
sum
];
}
}
}
}
Q
+=
2
;
Q
+=
2
;
}
}
...
@@ -169,44 +169,44 @@ static void encode_L2_Q(uae_u8 *inout)
...
@@ -169,44 +169,44 @@ static void encode_L2_Q(uae_u8 *inout)
static
void
encode_L2_P
(
uae_u8
inout
[
4
+
L2_RAW
+
4
+
8
+
L2_P
])
static
void
encode_L2_P
(
uae_u8
inout
[
4
+
L2_RAW
+
4
+
8
+
L2_P
])
{
{
uae_u8
*
P
;
uae_u8
*
P
;
int
i
,
j
;
int
i
,
j
;
P
=
inout
+
4
+
L2_RAW
+
4
+
8
;
P
=
inout
+
4
+
L2_RAW
+
4
+
8
;
memset
(
P
,
0
,
L2_P
);
memset
(
P
,
0
,
L2_P
);
for
(
j
=
0
;
j
<
43
;
j
++
)
{
for
(
j
=
0
;
j
<
43
;
j
++
)
{
for
(
i
=
0
;
i
<
24
;
i
++
)
{
for
(
i
=
0
;
i
<
24
;
i
++
)
{
uae_u8
data
;
uae_u8
data
;
/* LSB */
/* LSB */
data
=
inout
[
i
*
2
*
43
];
data
=
inout
[
i
*
2
*
43
];
if
(
data
!=
0
)
{
if
(
data
!=
0
)
{
uae_u32
base
=
rs_l12_log
[
data
];
uae_u32
base
=
rs_l12_log
[
data
];
uae_u32
sum
=
base
+
DP
[
0
][
i
];
uae_u32
sum
=
base
+
DP
[
0
][
i
];
if
(
sum
>=
((
1
<<
RS_L12_BITS
)
-
1
))
if
(
sum
>=
((
1
<<
RS_L12_BITS
)
-
1
))
sum
-=
(
1
<<
RS_L12_BITS
)
-
1
;
sum
-=
(
1
<<
RS_L12_BITS
)
-
1
;
P
[
0
]
^=
rs_l12_alog
[
sum
];
P
[
0
]
^=
rs_l12_alog
[
sum
];
sum
=
base
+
DP
[
1
][
i
];
sum
=
base
+
DP
[
1
][
i
];
if
(
sum
>=
((
1
<<
RS_L12_BITS
)
-
1
))
if
(
sum
>=
((
1
<<
RS_L12_BITS
)
-
1
))
sum
-=
(
1
<<
RS_L12_BITS
)
-
1
;
sum
-=
(
1
<<
RS_L12_BITS
)
-
1
;
P
[
43
*
2
]
^=
rs_l12_alog
[
sum
];
P
[
43
*
2
]
^=
rs_l12_alog
[
sum
];
}
}
/* MSB */
/* MSB */
data
=
inout
[
i
*
2
*
43
+
1
];
data
=
inout
[
i
*
2
*
43
+
1
];
if
(
data
!=
0
)
{
if
(
data
!=
0
)
{
uae_u32
base
=
rs_l12_log
[
data
];
uae_u32
base
=
rs_l12_log
[
data
];
uae_u32
sum
=
base
+
DP
[
0
][
i
];
uae_u32
sum
=
base
+
DP
[
0
][
i
];
if
(
sum
>=
((
1
<<
RS_L12_BITS
)
-
1
))
if
(
sum
>=
((
1
<<
RS_L12_BITS
)
-
1
))
sum
-=
(
1
<<
RS_L12_BITS
)
-
1
;
sum
-=
(
1
<<
RS_L12_BITS
)
-
1
;
P
[
1
]
^=
rs_l12_alog
[
sum
];
P
[
1
]
^=
rs_l12_alog
[
sum
];
sum
=
base
+
DP
[
1
][
i
];
sum
=
base
+
DP
[
1
][
i
];
if
(
sum
>=
((
1
<<
RS_L12_BITS
)
-
1
))
if
(
sum
>=
((
1
<<
RS_L12_BITS
)
-
1
))
sum
-=
(
1
<<
RS_L12_BITS
)
-
1
;
sum
-=
(
1
<<
RS_L12_BITS
)
-
1
;
P
[
43
*
2
+
1
]
^=
rs_l12_alog
[
sum
];
P
[
43
*
2
+
1
]
^=
rs_l12_alog
[
sum
];
}
}
}
}
P
+=
2
;
P
+=
2
;
inout
+=
2
;
inout
+=
2
;
}
}
}
}
static
uae_u8
tobcd
(
uae_u8
v
)
static
uae_u8
tobcd
(
uae_u8
v
)
...
@@ -220,16 +220,16 @@ void encode_l2 (uae_u8 *p, int address)
...
@@ -220,16 +220,16 @@ void encode_l2 (uae_u8 *p, int address)
p
[
0
]
=
0x00
;
p
[
0
]
=
0x00
;
memset
(
p
+
1
,
0xff
,
11
);
memset
(
p
+
1
,
0xff
,
11
);
p
[
12
]
=
tobcd
((
uae_u8
)(
address
/
(
60
*
75
)));
p
[
12
]
=
tobcd
((
uae_u8
)(
address
/
(
60
*
75
)));
p
[
13
]
=
tobcd
((
uae_u8
)((
address
/
75
)
%
60
));
p
[
13
]
=
tobcd
((
uae_u8
)((
address
/
75
)
%
60
));
p
[
14
]
=
tobcd
((
uae_u8
)(
address
%
75
));
p
[
14
]
=
tobcd
((
uae_u8
)(
address
%
75
));
p
[
15
]
=
1
;
/* MODE1 */
p
[
15
]
=
1
;
/* MODE1 */
v
=
build_edc
(
p
,
0
,
16
+
2048
-
1
);
v
=
build_edc
(
p
,
0
,
16
+
2048
-
1
);
p
[
2064
+
0
]
=
(
uae_u8
)
(
v
>>
0
);
p
[
2064
+
0
]
=
(
uae_u8
)
(
v
>>
0
);
p
[
2064
+
1
]
=
(
uae_u8
)
(
v
>>
8
);
p
[
2064
+
1
]
=
(
uae_u8
)
(
v
>>
8
);
p
[
2064
+
2
]
=
(
uae_u8
)
(
v
>>
16
);
p
[
2064
+
2
]
=
(
uae_u8
)
(
v
>>
16
);
p
[
2064
+
3
]
=
(
uae_u8
)
(
v
>>
24
);
p
[
2064
+
3
]
=
(
uae_u8
)
(
v
>>
24
);
memset
(
p
+
2064
+
4
,
0
,
8
);
memset
(
p
+
2064
+
4
,
0
,
8
);
encode_L2_P
(
p
+
12
);
encode_L2_P
(
p
+
12
);
encode_L2_Q
(
p
+
12
);
encode_L2_Q
(
p
+
12
);
}
}
src/cdtv.c
View file @
add1223e
...
@@ -765,8 +765,6 @@ static void init_play (int start, int end)
...
@@ -765,8 +765,6 @@ static void init_play (int start, int end)
bool
cdtv_front_panel
(
int
button
)
bool
cdtv_front_panel
(
int
button
)
{
{
unsigned
int
j
;
if
(
!
frontpanel
||
configured
<=
0
)
if
(
!
frontpanel
||
configured
<=
0
)
return
false
;
return
false
;
if
(
button
<
0
)
if
(
button
<
0
)
...
@@ -792,6 +790,7 @@ bool cdtv_front_panel (int button)
...
@@ -792,6 +790,7 @@ bool cdtv_front_panel (int button)
uae_u8
*
sq
=
cdrom_qcode
+
4
;
uae_u8
*
sq
=
cdrom_qcode
+
4
;
int
track
=
frombcd
(
sq
[
1
]);
int
track
=
frombcd
(
sq
[
1
]);
int
pos
=
0
;
int
pos
=
0
;
unsigned
int
j
;
for
(
j
=
0
;
j
<
toc
.
points
;
j
++
)
{
for
(
j
=
0
;
j
<
toc
.
points
;
j
++
)
{
int
t
=
toc
.
toc
[
j
].
track
;
int
t
=
toc
.
toc
[
j
].
track
;
pos
=
toc
.
toc
[
j
].
paddress
;
pos
=
toc
.
toc
[
j
].
paddress
;
...
@@ -1861,7 +1860,6 @@ uae_u8 *save_cdtv (int *len, uae_u8 *dstptr)
...
@@ -1861,7 +1860,6 @@ uae_u8 *save_cdtv (int *len, uae_u8 *dstptr)
uae_u8
*
restore_cdtv
(
uae_u8
*
src
)
uae_u8
*
restore_cdtv
(
uae_u8
*
src
)
{
{
unsigned
int
i
;
unsigned
int
i
;
cdtv_free
();
cdtv_free
();
if
(
!
currprefs
.
cs_cdtvcd
)
{
if
(
!
currprefs
.
cs_cdtvcd
)
{
changed_prefs
.
cs_cdtvcd
=
changed_prefs
.
cs_cdtvram
=
true
;
changed_prefs
.
cs_cdtvcd
=
changed_prefs
.
cs_cdtvram
=
true
;
...
...
src/custom.c
View file @
add1223e
...
@@ -97,24 +97,6 @@ static void uae_abort (const TCHAR *format,...)
...
@@ -97,24 +97,6 @@ static void uae_abort (const TCHAR *format,...)
nomore
=
1
;
nomore
=
1
;
}
}
#if 0
void customhack_put (struct customhack *ch, uae_u16 v, int hpos)
{
ch->v = v;
ch->vpos = vpos;
ch->hpos = hpos;
}
uae_u16 customhack_get (struct customhack *ch, int hpos)
{
if (ch->vpos == vpos && ch->hpos == hpos) {
ch->vpos = -1;
return 0xffff;
}
return ch->v;
}
#endif
uae_u16
last_custom_value1
;
uae_u16
last_custom_value1
;
static
unsigned
int
n_consecutive_skipped
=
0
;
static
unsigned
int
n_consecutive_skipped
=
0
;
...
@@ -233,7 +215,7 @@ static uae_u16 sprdata[MAX_SPRITES][1], sprdatb[MAX_SPRITES][1];
...
@@ -233,7 +215,7 @@ static uae_u16 sprdata[MAX_SPRITES][1], sprdatb[MAX_SPRITES][1];
#endif
#endif
static
int
sprite_last_drawn_at
[
MAX_SPRITES
];
static
int
sprite_last_drawn_at
[
MAX_SPRITES
];
static
int
last_sprite_point
,
nr_armed
;
static
int
last_sprite_point
,
nr_armed
;
int
sprite_width
,
sprres
;
static
int
sprite_width
,
sprres
;
int
sprite_buffer_res
;
int
sprite_buffer_res
;
#ifdef CPUEMU_12
#ifdef CPUEMU_12
...
@@ -264,16 +246,16 @@ enum diw_states
...
@@ -264,16 +246,16 @@ enum diw_states
DIW_waiting_start
,
DIW_waiting_stop
DIW_waiting_start
,
DIW_waiting_stop
};
};
int
plffirstline
,
plflastline
;
static
int
plffirstline
,
plflastline
;
int
plffirstline_total
,
plflastline_total
;
int
plffirstline_total
,
plflastline_total
;
static
int
autoscale_bordercolors
;
static
int
autoscale_bordercolors
;
int
plfstrt_start
,
plfstrt
,
plfstop
;
static
int
plfstrt_start
,
plfstrt
,
plfstop
;
static
int
sprite_minx
,
sprite_maxx
;
static
int
sprite_minx
,
sprite_maxx
;
static
int
first_bpl_vpos
;
static
int
first_bpl_vpos
;
static
int
last_ddf_pix_hpos
;
static
int
last_ddf_pix_hpos
;
static
int
last_decide_line_hpos
;
static
int
last_decide_line_hpos
;
static
int
last_fetch_hpos
,
last_sprite_hpos
;
static
int
last_fetch_hpos
,
last_sprite_hpos
;
int
diwfirstword
,
diwlastword
;
static
int
diwfirstword
,
diwlastword
;
static
int
plfleft_real
;
static
int
plfleft_real
;
static
int
last_hdiw
;
static
int
last_hdiw
;
static
enum
diw_states
diwstate
,
hdiwstate
,
ddfstate
;
static
enum
diw_states
diwstate
,
hdiwstate
,
ddfstate
;
...
@@ -334,15 +316,15 @@ int bogusframe;
...
@@ -334,15 +316,15 @@ int bogusframe;
/* Recording of custom chip register changes. */
/* Recording of custom chip register changes. */
static
int
current_change_set
;
static
int
current_change_set
;
struct
sprite_entry
sprite_entries
[
2
][
MAX_SPR_PIXELS
/
16
];
st
atic
st
ruct
sprite_entry
sprite_entries
[
2
][
MAX_SPR_PIXELS
/
16
];
struct
color_change
color_changes
[
2
][
MAX_REG_CHANGE
];
st
atic
st
ruct
color_change
color_changes
[
2
][
MAX_REG_CHANGE
];
struct
decision
line_decisions
[
2
*
(
MAXVPOS
+
2
)
+
1
];
struct
decision
line_decisions
[
2
*
(
MAXVPOS
+
2
)
+
1
];
struct
draw_info
line_drawinfo
[
2
][
2
*
(
MAXVPOS
+
2
)
+
1
];
st
atic
st
ruct
draw_info
line_drawinfo
[
2
][
2
*
(
MAXVPOS
+
2
)
+
1
];
#define COLOR_TABLE_SIZE (MAXVPOS + 2) * 2
#define COLOR_TABLE_SIZE (MAXVPOS + 2) * 2
struct
color_entry
color_tables
[
2
][
COLOR_TABLE_SIZE
];
st
atic
st
ruct
color_entry
color_tables
[
2
][
COLOR_TABLE_SIZE
];
int
next_sprite_entry
=
0
;
static
int
next_sprite_entry
=
0
;
static
int
prev_next_sprite_entry
;
static
int
prev_next_sprite_entry
;
static
int
next_sprite_forced
=
1
;
static
int
next_sprite_forced
=
1
;
...
@@ -5221,7 +5203,7 @@ STATIC_INLINE int trigger_frh (int v)
...
@@ -5221,7 +5203,7 @@ STATIC_INLINE int trigger_frh (int v)
return
(
v
&
(
N_LINES
-
1
))
==
0
;
return
(
v
&
(
N_LINES
-
1
))
==
0
;
}
}
long
int
diff32
(
frame_time_t
x
,
frame_time_t
y
)
static
long
int
diff32
(
frame_time_t
x
,
frame_time_t
y
)
{
{
return
(
long
int
)(
x
-
y
);
return
(
long
int
)(
x
-
y
);
}
}
...
...
src/gui-qt/Makefile.am
View file @
add1223e
...
@@ -25,11 +25,25 @@ AR_FLAGS = $(LIBS)
...
@@ -25,11 +25,25 @@ AR_FLAGS = $(LIBS)
noinst_LIBRARIES
=
libguidep.a
noinst_LIBRARIES
=
libguidep.a
libguidep_a_SOURCES
=
puae_mainwindow.cpp moc_puae_mainwindow.cpp puae_bridge.cpp moc_puae_bridge.cpp puae_misc.cpp moc_puae_misc.cpp
libguidep_a_SOURCES
=
\
puae_mainwindow.cpp moc_puae_mainwindow.cpp
\
noinst_HEADERS
=
puae_mainwindow.h ui_puae_mainwindow.h puae_bridge.h puae_misc.h
puae_bridge.cpp moc_puae_bridge.cpp
\
puae_misc.cpp moc_puae_misc.cpp
\
BUILT_SOURCES
=
moc_puae_mainwindow.cpp moc_puae_bridge.cpp moc_puae_misc.cpp ui_puae_mainwindow.h
puae_registry.cpp moc_puae_registry.cpp
noinst_HEADERS
=
\
ui_puae_mainwindow.h
\
puae_mainwindow.h
\
puae_bridge.h
\
puae_misc.h
\
puae_registry.h
BUILT_SOURCES
=
\
moc_puae_mainwindow.cpp
\
moc_puae_bridge.cpp
\
moc_puae_misc.cpp
\
moc_puae_registry.cpp
\
ui_puae_mainwindow.h
CLEANFILES
=
*
.o qrc
*
.
*
ui
*
.
*
moc
*
.
*
CLEANFILES
=
*
.o qrc
*
.
*
ui
*
.
*
moc
*
.
*
...
...
src/gui-qt/puae_mainwindow.cpp
View file @
add1223e
...
@@ -8,6 +8,20 @@
...
@@ -8,6 +8,20 @@
*
*
*/
*/
// REMOVEME>tmp stuff from *.h
#define CSMASK_ECS_AGNUS 1
#define CSMASK_ECS_DENISE 2
#define CSMASK_AGA 4
#define CSMASK_MASK (CSMASK_ECS_AGNUS | CSMASK_ECS_DENISE | CSMASK_AGA)
#define VRES_NONDOUBLE 0
#define VRES_DOUBLE 1
#define VRES_MAX 1
#define DEFAULT_SOUND_MAXB 16384
// REMOVEME>tmp stuff from *.h
#include "puae_registry.h"
#include "puae_mainwindow.h"
#include "puae_mainwindow.h"
#include "ui_puae_mainwindow.h"
#include "ui_puae_mainwindow.h"
...
@@ -20,24 +34,21 @@
...
@@ -20,24 +34,21 @@
#define hDlg 0
#define hDlg 0
extern
"C"
{
extern
"C"
{
#include "include/rommgr.h"
#include "include/options.h"
#include "include/options.h"
extern
int
candirect
;
extern
int
candirect
;
extern
bool
canbang
;
extern
bool
canbang
;
struct
uae_prefs
workprefs
;
struct
uae_prefs
workprefs
;
}
// defs from *.h
// REMOVEME>tmp
#define CSMASK_ECS_AGNUS 1
extern
const
char
*
uae_archive_extensions
[];
#define CSMASK_ECS_DENISE 2
#ifdef ARCADIA
#define CSMASK_AGA 4
extern
struct
romdata
*
scan_arcadia_rom
(
char
*
,
int
);
#define CSMASK_MASK (CSMASK_ECS_AGNUS | CSMASK_ECS_DENISE | CSMASK_AGA)
#endif
// REMOVEME>tmp
#define VRES_NONDOUBLE 0
}
#define VRES_DOUBLE 1
#define VRES_MAX 1
#define DEFAULT_SOUND_MAXB 16384
//
int
full_property_sheet
=
1
;
int
full_property_sheet
=
1
;
// Paths Tab
// Paths Tab
...
@@ -745,6 +756,95 @@ void puae_MainWindow::on_IDC_FLOPPYSPD_valueChanged(int value)
...
@@ -745,6 +756,95 @@ void puae_MainWindow::on_IDC_FLOPPYSPD_valueChanged(int value)
out_floppyspeed
();
out_floppyspeed
();
}
}
//
// Santa's Little Helpers
//
int
puae_MainWindow
::
isromext
(
const
char
*
path
,
bool
deepscan
)
{
const
TCHAR
*
ext
;
int
i
;
if
(
!
path
)
return
0
;
ext
=
strrchr
(
path
,
'.'
);
if
(
!
ext
)
return
0
;
ext
++
;
if
(
!
strcasecmp
(
ext
,
"rom"
)
||
!
strcasecmp
(
ext
,
"adf"
)
||
!
strcasecmp
(
ext
,
"key"
)
||
!
strcasecmp
(
ext
,
"a500"
)
||
!
strcasecmp
(
ext
,
"a1200"
)
||
!
strcasecmp
(
ext
,
"a4000"
)
||
!
strcasecmp
(
ext
,
"cd32"
))
return
1
;
if
(
strlen
(
ext
)
>=
2
&&
toupper
(
ext
[
0
])
==
'U'
&&
isdigit
(
ext
[
1
]))
return
1
;
if
(
!
deepscan
)
return
0
;
for
(
i
=
0
;
uae_archive_extensions
[
i
];
i
++
)
{
if
(
!
strcasecmp
(
ext
,
uae_archive_extensions
[
i
]))
return
1
;
}
return
0
;
}
bool
puae_MainWindow
::
scan_rom_hook
(
const
char
*
name
,
int
line
)
{
/* MSG msg;
if (!infoboxhwnd)
return true;
if (name != NULL) {
const char *s = NULL;
if (line == 2) {
s = strrchr (name, '/');
if (!s)
s = strrchr (name, '\\');
if (s)
s++;
}
SetWindowText (GetDlgItem (infoboxhwnd, line == 1 ? IDC_INFOBOX_TEXT1 : (line == 2 ? IDC_INFOBOX_TEXT2 : IDC_INFOBOX_TEXT3)), s ? s : name);
}
while (PeekMessage (&msg, infoboxhwnd, 0, 0, PM_REMOVE)) {
if (!IsDialogMessage (infoboxhwnd, &msg)) {
TranslateMessage (&msg);
DispatchMessage (&msg);
}
}
return infoboxdialogstate;*/
return
false
;
}
int
puae_MainWindow
::
addrom
(
struct
romdata
*
rd
,
const
char
*
name
)
{
char
tmp1
[
MAX_DPATH
],
tmp2
[
MAX_DPATH
];
printf
(
tmp1
,
"ROM_%03d"
,
rd
->
id
);
}
int
puae_MainWindow
::
scan_rom
(
const
char
*
path
,
bool
deepscan
)
{
struct
romdata
*
rd
;
int
cnt
=
0
;
if
(
!
isromext
(
path
,
deepscan
))
{
return
0
;
}
scan_rom_hook
(
path
,
2
);
#ifdef ARCADIA
for
(;;)
{
char
tmp
[
MAX_DPATH
];
strcpy
(
tmp
,
path
);
rd
=
scan_arcadia_rom
(
tmp
,
cnt
++
);
if
(
rd
)
{
if
(
!
addrom
(
rd
,
tmp
))
return
1
;
continue
;
}
break
;
}
#endif
return
0
;
}
void
puae_MainWindow
::
display_fromselect
(
int
val
,
int
*
fs
,
int
*
vsync
,
int
p96
)
void
puae_MainWindow
::
display_fromselect
(
int
val
,
int
*
fs
,
int
*
vsync
,
int
p96
)
{
{
int
ofs
=
*
fs
;
int
ofs
=
*
fs
;
...
@@ -794,9 +894,6 @@ void puae_MainWindow::display_fromselect (int val, int *fs, int *vsync, int p96)
...
@@ -794,9 +894,6 @@ void puae_MainWindow::display_fromselect (int val, int *fs, int *vsync, int p96)
}
}
}
}
//
// Santa's Little Helpers
//
int
puae_MainWindow
::
getcpufreq
(
int
m
)
int
puae_MainWindow
::
getcpufreq
(
int
m
)
{
{
int
f
;
int
f
;
...
@@ -1621,7 +1718,7 @@ void puae_MainWindow::values_from_displaydlg () {
...
@@ -1621,7 +1718,7 @@ void puae_MainWindow::values_from_displaydlg () {
workprefs
.
gfx_scandoubler
=
ui
->
IDC_FLICKERFIXER
->
isChecked
();
workprefs
.
gfx_scandoubler
=
ui
->
IDC_FLICKERFIXER
->
isChecked
();
workprefs
.
gfx_blackerthanblack
=
ui
->
IDC_BLACKER_THAN_BLACK
->
isChecked
();
workprefs
.
gfx_blackerthanblack
=
ui
->
IDC_BLACKER_THAN_BLACK
->
isChecked
();
workprefs
.
gfx_vresolution
=
ui
->
IDC_LM_DOUBLED
->
isChecked
()
||
ui
->
IDC_LM_SCANLINES
->
isChecked
()
?
VRES_DOUBLE
:
VRES_NONDOUBLE
;
workprefs
.
gfx_vresolution
=
ui
->
IDC_LM_DOUBLED
->
isChecked
()
||
ui
->
IDC_LM_SCANLINES
->
isChecked
()
?
VRES_DOUBLE
:
VRES_NONDOUBLE
;
workprefs
.
gfx_scanlines
=
ui
->
IDC_LM_SCANLINES
->
isChecked
();
workprefs
.
gfx_scanlines
=
ui
->
IDC_LM_SCANLINES
->
isChecked
();
// workprefs.gfx_backbuffers = SendDlgItemMessage (hDlg, IDC_DISPLAY_BUFFERCNT, CB_GETCURSEL, 0, 0);
// workprefs.gfx_backbuffers = SendDlgItemMessage (hDlg, IDC_DISPLAY_BUFFERCNT, CB_GETCURSEL, 0, 0);
// workprefs.gfx_framerate = SendDlgItemMessage (hDlg, IDC_FRAMERATE, TBM_GETPOS, 0, 0);
// workprefs.gfx_framerate = SendDlgItemMessage (hDlg, IDC_FRAMERATE, TBM_GETPOS, 0, 0);
// workprefs.chipset_refreshrate = SendDlgItemMessage (hDlg, IDC_FRAMERATE2, TBM_GETPOS, 0, 0);
// workprefs.chipset_refreshrate = SendDlgItemMessage (hDlg, IDC_FRAMERATE2, TBM_GETPOS, 0, 0);
...
...
src/gui-qt/puae_mainwindow.h
View file @
add1223e
...
@@ -119,6 +119,10 @@ private slots:
...
@@ -119,6 +119,10 @@ private slots:
void
updatez3
(
unsigned
int
*
size1p
,
unsigned
int
*
size2p
);
void
updatez3
(
unsigned
int
*
size1p
,
unsigned
int
*
size2p
);
int
getcpufreq
(
int
);
int
getcpufreq
(
int
);
void
display_fromselect
(
int
val
,
int
*
fs
,
int
*
vsync
,
int
p96
);
void
display_fromselect
(
int
val
,
int
*
fs
,
int
*
vsync
,
int
p96
);
int
isromext
(
const
char
*
path
,
bool
deepscan
);
int
scan_rom
(
const
char
*
path
,
bool
deepscan
);
bool
scan_rom_hook
(
const
char
*
name
,
int
line
);
int
addrom
(
struct
romdata
*
rd
,
const
char
*
name
);
//
//
void
enable_for_memorydlg
();
void
enable_for_memorydlg
();
void
values_to_memorydlg
();
void
values_to_memorydlg
();
...
...
src/include/custom.h
View file @
add1223e
...
@@ -139,7 +139,6 @@ extern frame_time_t syncbase;
...
@@ -139,7 +139,6 @@ extern frame_time_t syncbase;
#define CYCLE_CPUNASTY 0x80
#define CYCLE_CPUNASTY 0x80
extern
unsigned
long
frametime
,
timeframes
;
extern
unsigned
long
frametime
,
timeframes
;
extern
int
plfstrt
,
plfstop
,
plffirstline
,
plflastline
;
extern
uae_u16
htotal
,
vtotal
,
beamcon0
;
extern
uae_u16
htotal
,
vtotal
,
beamcon0
;
/* 100 words give you 1600 horizontal pixels. Should be more than enough for
/* 100 words give you 1600 horizontal pixels. Should be more than enough for
...
...
src/include/drawing.h
View file @
add1223e
...
@@ -39,7 +39,7 @@
...
@@ -39,7 +39,7 @@
#define max_diwlastword (PIXEL_XPOS(0x1d4 >> 1))
#define max_diwlastword (PIXEL_XPOS(0x1d4 >> 1))
extern
int
lores_factor
,
lores_shift
,
sprite_width
,
interlace_seen
;
extern
int
lores_factor
,
lores_shift
,
interlace_seen
;
extern
bool
aga_mode
,
direct_rgb
;
extern
bool
aga_mode
,
direct_rgb
;
STATIC_INLINE
int
coord_hw_to_window_x
(
int
x
)
STATIC_INLINE
int
coord_hw_to_window_x
(
int
x
)
...
@@ -200,13 +200,6 @@ extern uae_u16 spixels[MAX_SPR_PIXELS * 2];
...
@@ -200,13 +200,6 @@ extern uae_u16 spixels[MAX_SPR_PIXELS * 2];
/* Way too much... */
/* Way too much... */
#define MAX_REG_CHANGE ((MAXVPOS + 1) * 2 * MAXHPOS)
#define MAX_REG_CHANGE ((MAXVPOS + 1) * 2 * MAXHPOS)
#ifdef OS_WITHOUT_MEMORY_MANAGEMENT
extern
struct
color_change
*
color_changes
[
2
];
#else
extern
struct
color_change
color_changes
[
2
][
MAX_REG_CHANGE
];
#endif
extern
struct
color_entry
color_tables
[
2
][(
MAXVPOS
+
2
)
*
2
];
extern
struct
color_entry
*
curr_color_tables
,
*
prev_color_tables
;
extern
struct
color_entry
*
curr_color_tables
,
*
prev_color_tables
;
extern
struct
sprite_entry
*
curr_sprite_entries
,
*
prev_sprite_entries
;
extern
struct
sprite_entry
*
curr_sprite_entries
,
*
prev_sprite_entries
;
...
@@ -241,8 +234,6 @@ struct draw_info {
...
@@ -241,8 +234,6 @@ struct draw_info {
int
nr_color_changes
,
nr_sprites
;
int
nr_color_changes
,
nr_sprites
;
};
};
extern
int
next_sprite_entry
;
extern
struct
decision
line_decisions
[
2
*
(
MAXVPOS
+
2
)
+
1
];
extern
struct
decision
line_decisions
[
2
*
(
MAXVPOS
+
2
)
+
1
];
extern
uae_u8
line_data
[(
MAXVPOS
+
2
)
*
2
][
MAX_PLANES
*
MAX_WORDS_PER_LINE
*
2
];
extern
uae_u8
line_data
[(
MAXVPOS
+
2
)
*
2
][
MAX_PLANES
*
MAX_WORDS_PER_LINE
*
2
];
...
@@ -283,7 +274,6 @@ extern void putpixel (uae_u8 *buf, int bpp, int x, xcolnr c8, int opaq);
...
@@ -283,7 +274,6 @@ extern void putpixel (uae_u8 *buf, int bpp, int x, xcolnr c8, int opaq);
/* Finally, stuff that shouldn't really be shared. */
/* Finally, stuff that shouldn't really be shared. */
extern
int
thisframe_first_drawn_line
,
thisframe_last_drawn_line
;
extern
int
thisframe_first_drawn_line
,
thisframe_last_drawn_line
;
extern
int
diwfirstword
,
diwlastword
;
#define IHF_SCROLLLOCK 0
#define IHF_SCROLLLOCK 0
#define IHF_QUIT_PROGRAM 1
#define IHF_QUIT_PROGRAM 1
...
...
src/include/events_jit.h
View file @
add1223e
/* Let's see whether hiding this away somewhere where the compiler can't
/* Let's see whether hiding this away somewhere where the compiler can't
see it will cure it of its silly urge to mis-optimize the comparison */
see it will cure it of its silly urge to mis-optimize the comparison */
extern
long
int
diff32
(
frame_time_t
x
,
frame_time_t
y
);
//
extern long int diff32(frame_time_t x, frame_time_t y);
extern
int
pissoff_value
;
extern
int
pissoff_value
;
STATIC_INLINE
void
events_schedule
(
void
)
STATIC_INLINE
void
events_schedule
(
void
)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment