mirror of
https://github.com/jamessanford/kegs.git
synced 2024-06-07 16:03:45 +00:00
Add OG initializations from kegs_3_1_453
This fixes the bug where, for example, the mouse cursor wouldn't display after reboting from another disk.
This commit is contained in:
parent
66ea28c3c6
commit
973d9c1422
|
@ -191,6 +191,24 @@ Data_log *g_log_data_ptr = &(g_data_log_array[0]);
|
|||
Data_log *g_log_data_start_ptr = &(g_data_log_array[0]);
|
||||
Data_log *g_log_data_end_ptr = &(g_data_log_array[PC_LOG_LEN]);
|
||||
|
||||
// OG Missing defined below
|
||||
extern word32 g_vbl_count;
|
||||
extern int g_vbl_index_count;
|
||||
extern int g_limit_speed;
|
||||
extern double g_sim_sum;
|
||||
|
||||
extern double g_cur_sim_dtime;
|
||||
extern double g_projected_pmhz;
|
||||
extern double g_zip_pmhz;
|
||||
extern double g_sim_mhz;
|
||||
extern int g_line_ref_amt;
|
||||
extern int g_video_line_update_interval;
|
||||
|
||||
extern double g_dtime_last_vbl;
|
||||
extern double g_dtime_expected;
|
||||
|
||||
extern int g_scan_int_events;
|
||||
|
||||
// OG Added sim65816_initglobals()
|
||||
void sim65816_initglobals()
|
||||
{
|
||||
|
@ -253,6 +271,31 @@ void sim65816_initglobals()
|
|||
g_mem_size_base = 256*1024; /* size of motherboard memory */
|
||||
g_mem_size_exp = 8*1024*1024; /* size of expansion RAM card */
|
||||
g_mem_size_total = 256*1024; /* Total contiguous RAM from 0 */
|
||||
|
||||
// OG Added missing initializers 120710
|
||||
// g_force_depth = -1; // OG Should be no reseted
|
||||
// g_screen_depth = 8; // OG Should be no reseted
|
||||
|
||||
g_vbl_count = 0;
|
||||
g_vbl_index_count = 0;
|
||||
// g_limit_speed = 0; // OG Should be no reseted
|
||||
g_sim_sum = 0.0;
|
||||
|
||||
g_cur_sim_dtime = 0.0;
|
||||
g_projected_pmhz = 1.0;
|
||||
g_zip_pmhz = 8.0;
|
||||
g_sim_mhz = 100.0;
|
||||
g_line_ref_amt = 1;
|
||||
g_video_line_update_interval = 0;
|
||||
|
||||
g_dtime_last_vbl = 0.0;
|
||||
#ifdef __ANDROID__
|
||||
g_dtime_expected = (1.0/59.8);
|
||||
#else
|
||||
g_dtime_expected = (1.0/60.0);
|
||||
#endif
|
||||
|
||||
g_scan_int_events = 0;
|
||||
}
|
||||
|
||||
void
|
||||
|
@ -741,10 +784,10 @@ do_reset()
|
|||
{
|
||||
|
||||
extern int g_irq_pending;
|
||||
/*
|
||||
extern int g_scan_int_events ;
|
||||
extern int g_c023_val;
|
||||
|
||||
/*
|
||||
#define REMOVEIRQ(ADR) { extern int ADR; if (ADR) { remove_irq(); ADR=0; } }
|
||||
#define CLEARIRQ(ADR) { extern int ADR; ADR=0; }
|
||||
|
||||
|
|
34
jni/video.c
34
jni/video.c
|
@ -308,6 +308,15 @@ const word32 g_hires_convert[64] = {
|
|||
0x050, 0x0d0, 0x150, 0x1d0, 0x250, 0x2d0, 0x350, 0x3d0
|
||||
};
|
||||
|
||||
// OG Defined below
|
||||
extern int g_flash_count;
|
||||
extern int g_screen_redraw_skip_count;
|
||||
extern int g_screen_redraw_skip_amt;
|
||||
extern word32 g_cycs_in_check_input;
|
||||
extern int g_needfullrefreshfornextframe;
|
||||
extern int g_num_a2vid_palette_checks;
|
||||
extern int g_border_color; // OG Expose border color
|
||||
extern int g_num_border_changes;
|
||||
|
||||
void
|
||||
video_init()
|
||||
|
@ -375,17 +384,20 @@ video_init()
|
|||
g_num_lines_prev_superhires = 0;
|
||||
g_num_lines_prev_superhires640 = 0;
|
||||
|
||||
/*
|
||||
g_red_mask = 0xff;
|
||||
g_green_mask = 0xff;
|
||||
g_blue_mask = 0xff;
|
||||
g_red_left_shift = 16;
|
||||
g_green_left_shift = 8;
|
||||
g_blue_left_shift = 0;
|
||||
g_red_right_shift = 0;
|
||||
g_green_right_shift = 0;
|
||||
g_blue_right_shift = 0;
|
||||
*/
|
||||
g_flash_count = 0;
|
||||
|
||||
g_screen_redraw_skip_count = 0;
|
||||
g_screen_redraw_skip_amt = -1;
|
||||
|
||||
g_cycs_in_check_input = 0;
|
||||
|
||||
g_needfullrefreshfornextframe = 1 ;
|
||||
|
||||
g_num_a2vid_palette_checks = 1;
|
||||
|
||||
g_border_color = 0; // OG Expose border color
|
||||
|
||||
g_num_border_changes = 0;
|
||||
|
||||
/* Initialize video system */
|
||||
|
||||
|
|
Loading…
Reference in New Issue
Block a user