mirror of
https://github.com/libretro/RetroArch
synced 2025-03-23 19:21:03 +00:00
(PS3) Add some Griffin overrides
This commit is contained in:
parent
3902bc19b3
commit
3e6a10ffb6
@ -40,6 +40,9 @@
|
||||
#define video_set_rotation_func(rotation) gl_set_rotation(driver.video_data, rotation)
|
||||
#define video_set_aspect_ratio_func(aspectratio_idx) gfx_ctx_set_aspect_ratio(driver.video_data, aspectratio_idx)
|
||||
|
||||
#define gfx_ctx_window_has_focus() (true)
|
||||
#define gfx_ctx_swap_buffers() (psglSwap())
|
||||
|
||||
#define input_init_func() ps3_input_initialize()
|
||||
#define input_poll_func() ps3_input_poll(driver.input_data)
|
||||
#define input_input_state_func(snes_keybinds, port, device, index, id) \
|
||||
@ -65,6 +68,9 @@
|
||||
#define video_set_rotation_func(rotation) xdk360_set_rotation(driver.video_data, rotation)
|
||||
#define video_set_aspect_ratio_func(aspectratio_idx) gfx_ctx_set_aspect_ratio(driver.video_data, aspectratio_idx)
|
||||
|
||||
#define gfx_ctx_window_has_focus() (true)
|
||||
#define gfx_ctx_swap_buffers() (d3d9->d3d_render_device->Present(NULL, NULL, NULL, NULL))
|
||||
|
||||
#define input_init_func() xdk360_input_initialize()
|
||||
#define input_poll_func() xdk360_input_poll(driver.input_data)
|
||||
#define input_input_state_func(snes_keybinds, port, device, index, id) \
|
||||
@ -95,5 +101,6 @@
|
||||
wii_input_state(driver.input_data, snes_keybinds, port, device, index, id)
|
||||
#define input_key_pressed_func(key) wii_key_pressed(driver.input_data, key)
|
||||
#define input_free_func() wii_free_input(driver.input_data)
|
||||
#define gfx_ctx_window_has_focus() (true)
|
||||
|
||||
#endif
|
||||
|
@ -95,17 +95,20 @@ void gfx_ctx_check_window(bool *quit,
|
||||
*resize = true;
|
||||
}
|
||||
|
||||
#ifndef HAVE_GRIFFIN
|
||||
bool gfx_ctx_window_has_focus(void)
|
||||
{
|
||||
return true;
|
||||
}
|
||||
|
||||
void gfx_ctx_set_resize(unsigned width, unsigned height) { }
|
||||
|
||||
void gfx_ctx_swap_buffers(void)
|
||||
{
|
||||
psglSwap();
|
||||
}
|
||||
#endif
|
||||
|
||||
void gfx_ctx_set_resize(unsigned width, unsigned height) { }
|
||||
|
||||
|
||||
bool gfx_ctx_menu_init(void)
|
||||
{
|
||||
@ -408,4 +411,3 @@ void gfx_ctx_set_overscan(void)
|
||||
|
||||
gl->should_resize = true;
|
||||
}
|
||||
|
||||
|
@ -58,11 +58,13 @@ bool gfx_ctx_window_has_focus(void)
|
||||
|
||||
void gfx_ctx_set_resize(unsigned width, unsigned height) { }
|
||||
|
||||
#ifndef HAVE_GRIFFIN
|
||||
void gfx_ctx_swap_buffers(void)
|
||||
{
|
||||
xdk360_video_t *d3d9 = (xdk360_video_t*)driver.video_data;
|
||||
d3d9->d3d_render_device->Present(NULL, NULL, NULL, NULL);
|
||||
}
|
||||
#endif
|
||||
|
||||
bool gfx_ctx_menu_init(void)
|
||||
{
|
||||
|
@ -46,4 +46,3 @@ void gl_render_msg_post(gl_t *gl)
|
||||
{
|
||||
cellDbgFontDraw();
|
||||
}
|
||||
|
||||
|
@ -49,8 +49,6 @@ void gfx_ctx_destroy(void);
|
||||
void gfx_ctx_get_video_size(unsigned *width, unsigned *height);
|
||||
void gfx_ctx_update_window_title(bool reset);
|
||||
|
||||
void gfx_ctx_swap_buffers(void);
|
||||
|
||||
bool gfx_ctx_key_pressed(int key);
|
||||
|
||||
void gfx_ctx_check_window(bool *quit,
|
||||
@ -62,8 +60,12 @@ void gfx_ctx_set_resize(unsigned width, unsigned height);
|
||||
bool gfx_ctx_get_wm_info(SDL_SysWMinfo *info);
|
||||
#endif
|
||||
|
||||
#ifndef HAVE_GRIFFIN
|
||||
bool gfx_ctx_window_has_focus(void);
|
||||
|
||||
void gfx_ctx_swap_buffers(void);
|
||||
#endif
|
||||
|
||||
void gfx_ctx_input_driver(const input_driver_t **input, void **input_data);
|
||||
|
||||
#ifdef HAVE_CG_MENU
|
||||
|
28
gfx/gl.c
28
gfx/gl.c
@ -542,20 +542,6 @@ static inline void set_texture_coords(GLfloat *coords, GLfloat xamt, GLfloat yam
|
||||
coords[7] = yamt;
|
||||
}
|
||||
|
||||
static void check_window(gl_t *gl)
|
||||
{
|
||||
bool quit, resize;
|
||||
|
||||
gfx_ctx_check_window(&quit,
|
||||
&resize, &gl->win_width, &gl->win_height,
|
||||
gl->frame_count);
|
||||
|
||||
if (quit)
|
||||
gl->quitting = true;
|
||||
else if (resize)
|
||||
gl->should_resize = true;
|
||||
}
|
||||
|
||||
#ifdef HAVE_FBO
|
||||
static void gl_compute_fbo_geometry(gl_t *gl, unsigned width, unsigned height,
|
||||
unsigned vp_width, unsigned vp_height)
|
||||
@ -958,7 +944,9 @@ static bool gl_frame(void *data, const void *frame, unsigned width, unsigned hei
|
||||
gl_render_msg_post(gl);
|
||||
}
|
||||
|
||||
#ifndef RARCH_CONSOLE
|
||||
gfx_ctx_update_window_title(false);
|
||||
#endif
|
||||
|
||||
#ifdef RARCH_CONSOLE
|
||||
if (!gl->block_swap)
|
||||
@ -1189,7 +1177,17 @@ static void *gl_init(const video_info_t *video, const input_driver_t **input, vo
|
||||
static bool gl_alive(void *data)
|
||||
{
|
||||
gl_t *gl = (gl_t*)data;
|
||||
check_window(gl);
|
||||
bool quit, resize;
|
||||
|
||||
gfx_ctx_check_window(&quit,
|
||||
&resize, &gl->win_width, &gl->win_height,
|
||||
gl->frame_count);
|
||||
|
||||
if (quit)
|
||||
gl->quitting = true;
|
||||
else if (resize)
|
||||
gl->should_resize = true;
|
||||
|
||||
return !gl->quitting;
|
||||
}
|
||||
|
||||
|
@ -22,6 +22,7 @@ void gl_init_font(gl_t *gl, const char *font_path, unsigned font_size);
|
||||
void gl_deinit_font(gl_t *gl);
|
||||
|
||||
void gl_render_msg(gl_t *gl, const char *msg);
|
||||
|
||||
void gl_render_msg_post(gl_t *gl);
|
||||
|
||||
#endif
|
||||
|
Loading…
x
Reference in New Issue
Block a user