Silence some warnings
This commit is contained in:
parent
019f256b17
commit
e543aa25ae
|
@ -283,8 +283,8 @@ void fill_pathname_application_special(char *s,
|
||||||
case APPLICATION_SPECIAL_DIRECTORY_ASSETS_SYSICONS:
|
case APPLICATION_SPECIAL_DIRECTORY_ASSETS_SYSICONS:
|
||||||
{
|
{
|
||||||
#ifdef HAVE_MENU
|
#ifdef HAVE_MENU
|
||||||
settings_t *settings = config_get_ptr();
|
|
||||||
#if defined(HAVE_XMB) || defined(HAVE_MATERIALUI) || defined(HAVE_OZONE)
|
#if defined(HAVE_XMB) || defined(HAVE_MATERIALUI) || defined(HAVE_OZONE)
|
||||||
|
settings_t *settings = config_get_ptr();
|
||||||
const char *menu_ident = settings->arrays.menu_driver;
|
const char *menu_ident = settings->arrays.menu_driver;
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
@ -321,8 +321,7 @@ void fill_pathname_application_special(char *s,
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
#endif
|
#endif
|
||||||
if (len)
|
if (len) s[0] = '\0';
|
||||||
s[0] = '\0';
|
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -3380,8 +3380,6 @@ static bool gl2_frame(void *data, const void *frame,
|
||||||
bool use_rgba = (video_info->video_st_flags & VIDEO_FLAG_USE_RGBA) ? true : false;
|
bool use_rgba = (video_info->video_st_flags & VIDEO_FLAG_USE_RGBA) ? true : false;
|
||||||
bool statistics_show = video_info->statistics_show;
|
bool statistics_show = video_info->statistics_show;
|
||||||
bool msg_bgcolor_enable = video_info->msg_bgcolor_enable;
|
bool msg_bgcolor_enable = video_info->msg_bgcolor_enable;
|
||||||
int bfi_light_frames;
|
|
||||||
unsigned n;
|
|
||||||
bool input_driver_nonblock_state = video_info->input_driver_nonblock_state;
|
bool input_driver_nonblock_state = video_info->input_driver_nonblock_state;
|
||||||
bool hard_sync = video_info->hard_sync;
|
bool hard_sync = video_info->hard_sync;
|
||||||
unsigned hard_sync_frames = video_info->hard_sync_frames;
|
unsigned hard_sync_frames = video_info->hard_sync_frames;
|
||||||
|
@ -3667,6 +3665,8 @@ static bool gl2_frame(void *data, const void *frame,
|
||||||
&& !video_info->runloop_is_paused
|
&& !video_info->runloop_is_paused
|
||||||
&& !(gl->flags & GL2_FLAG_MENU_TEXTURE_ENABLE))
|
&& !(gl->flags & GL2_FLAG_MENU_TEXTURE_ENABLE))
|
||||||
{
|
{
|
||||||
|
unsigned n;
|
||||||
|
int bfi_light_frames;
|
||||||
|
|
||||||
if (video_info->bfi_dark_frames > video_info->black_frame_insertion)
|
if (video_info->bfi_dark_frames > video_info->black_frame_insertion)
|
||||||
video_info->bfi_dark_frames = video_info->black_frame_insertion;
|
video_info->bfi_dark_frames = video_info->black_frame_insertion;
|
||||||
|
|
|
@ -990,7 +990,6 @@ static void gx_resize(gx_video_t *gx,
|
||||||
float top = 1, bottom = -1, left = -1, right = 1;
|
float top = 1, bottom = -1, left = -1, right = 1;
|
||||||
int x = 0, y = 0;
|
int x = 0, y = 0;
|
||||||
const global_t *global = global_get_ptr();
|
const global_t *global = global_get_ptr();
|
||||||
settings_t *settings = config_get_ptr();
|
|
||||||
unsigned width = gx->vp.full_width;
|
unsigned width = gx->vp.full_width;
|
||||||
unsigned height = gx->vp.full_height;
|
unsigned height = gx->vp.full_height;
|
||||||
|
|
||||||
|
|
|
@ -983,14 +983,10 @@ static void rsx_set_viewport(void *data, unsigned viewport_width,
|
||||||
{
|
{
|
||||||
int i;
|
int i;
|
||||||
rsx_viewport_t vp;
|
rsx_viewport_t vp;
|
||||||
int x = 0;
|
|
||||||
int y = 0;
|
|
||||||
float device_aspect = (float)viewport_width / viewport_height;
|
|
||||||
struct video_ortho ortho = {0, 1, 0, 1, -1, 1};
|
struct video_ortho ortho = {0, 1, 0, 1, -1, 1};
|
||||||
settings_t *settings = config_get_ptr();
|
settings_t *settings = config_get_ptr();
|
||||||
rsx_t *rsx = (rsx_t*)data;
|
rsx_t *rsx = (rsx_t*)data;
|
||||||
bool video_scale_integer = settings->bools.video_scale_integer;
|
bool video_scale_integer = settings->bools.video_scale_integer;
|
||||||
unsigned aspect_ratio_idx = settings->uints.video_aspect_ratio_idx;
|
|
||||||
|
|
||||||
if (video_scale_integer && !force_full)
|
if (video_scale_integer && !force_full)
|
||||||
{
|
{
|
||||||
|
|
|
@ -549,8 +549,6 @@ static void switch_update_viewport(switch_video_t *sw,
|
||||||
video_frame_info_t *video_info)
|
video_frame_info_t *video_info)
|
||||||
{
|
{
|
||||||
settings_t *settings = config_get_ptr();
|
settings_t *settings = config_get_ptr();
|
||||||
int x = 0;
|
|
||||||
int y = 0;
|
|
||||||
float desired_aspect = 0.0f;
|
float desired_aspect = 0.0f;
|
||||||
float width = sw->vp.full_width;
|
float width = sw->vp.full_width;
|
||||||
float height = sw->vp.full_height;
|
float height = sw->vp.full_height;
|
||||||
|
@ -570,15 +568,12 @@ static void switch_update_viewport(switch_video_t *sw,
|
||||||
|
|
||||||
desired_aspect = video_driver_get_aspect_ratio();
|
desired_aspect = video_driver_get_aspect_ratio();
|
||||||
|
|
||||||
|
/* TODO/FIXME: Does nx use top-left or bottom-left origin? I'm assuming top left. */
|
||||||
if (settings->bools.video_scale_integer)
|
if (settings->bools.video_scale_integer)
|
||||||
{
|
video_viewport_get_scaled_integer(&sw->vp, sw->vp.full_width, sw->vp.full_height,
|
||||||
/* TODO: Does nx use top-left or bottom-left origin? I'm assuming top left. */
|
desired_aspect, sw->keep_aspect, true);
|
||||||
video_viewport_get_scaled_integer(&sw->vp, sw->vp.full_width, sw->vp.full_height, desired_aspect, sw->keep_aspect, true);
|
|
||||||
}
|
|
||||||
else if (sw->keep_aspect)
|
else if (sw->keep_aspect)
|
||||||
{
|
|
||||||
video_viewport_get_scaled_aspect(&sw->vp, width, height, true);
|
video_viewport_get_scaled_aspect(&sw->vp, width, height, true);
|
||||||
}
|
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
sw->vp.x = sw->vp.y = 0;
|
sw->vp.x = sw->vp.y = 0;
|
||||||
|
@ -648,9 +643,9 @@ static bool switch_frame(void *data, const void *frame,
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
if ( sw->should_resize ||
|
if ( sw->should_resize
|
||||||
width != sw->last_width ||
|
|| (width != sw->last_width)
|
||||||
height != sw->last_height)
|
|| (height != sw->last_height))
|
||||||
{
|
{
|
||||||
switch_update_viewport(sw, video_info);
|
switch_update_viewport(sw, video_info);
|
||||||
|
|
||||||
|
@ -693,8 +688,8 @@ static bool switch_frame(void *data, const void *frame,
|
||||||
nwindowSetDimensions(sw->win, sw->hw_scale.width, sw->hw_scale.height);
|
nwindowSetDimensions(sw->win, sw->hw_scale.width, sw->hw_scale.height);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
sw->scaler.out_fmt = SCALER_FMT_ABGR8888;
|
|
||||||
|
|
||||||
|
sw->scaler.out_fmt = SCALER_FMT_ABGR8888;
|
||||||
sw->scaler.scaler_type = SCALER_TYPE_POINT;
|
sw->scaler.scaler_type = SCALER_TYPE_POINT;
|
||||||
|
|
||||||
if (!scaler_ctx_gen_filter(&sw->scaler))
|
if (!scaler_ctx_gen_filter(&sw->scaler))
|
||||||
|
@ -706,7 +701,7 @@ static bool switch_frame(void *data, const void *frame,
|
||||||
sw->should_resize = false;
|
sw->should_resize = false;
|
||||||
}
|
}
|
||||||
|
|
||||||
out_buffer = (uint32_t *)framebufferBegin(&sw->fb, &stride);
|
out_buffer = (uint32_t*)framebufferBegin(&sw->fb, &stride);
|
||||||
sw->out_buffer = out_buffer;
|
sw->out_buffer = out_buffer;
|
||||||
sw->stride = stride;
|
sw->stride = stride;
|
||||||
|
|
||||||
|
@ -726,7 +721,10 @@ static bool switch_frame(void *data, const void *frame,
|
||||||
if (sw->menu_texture.pixels)
|
if (sw->menu_texture.pixels)
|
||||||
{
|
{
|
||||||
memset(out_buffer, 0, stride * sw->vp.full_height);
|
memset(out_buffer, 0, stride * sw->vp.full_height);
|
||||||
scaler_ctx_scale(&sw->menu_texture.scaler, sw->tmp_image + ((sw->vp.full_height - sw->menu_texture.tgth) / 2) * sw->vp.full_width + ((sw->vp.full_width - sw->menu_texture.tgtw) / 2), sw->menu_texture.pixels);
|
scaler_ctx_scale(&sw->menu_texture.scaler,
|
||||||
|
sw->tmp_image + ((sw->vp.full_height - sw->menu_texture.tgth) / 2)
|
||||||
|
* sw->vp.full_width + ((sw->vp.full_width - sw->menu_texture.tgtw) / 2),
|
||||||
|
sw->menu_texture.pixels);
|
||||||
gfx_cpy_dsp_buf(out_buffer, sw->tmp_image, sw->vp.full_width, sw->vp.full_height, stride, true);
|
gfx_cpy_dsp_buf(out_buffer, sw->tmp_image, sw->vp.full_width, sw->vp.full_height, stride, true);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -821,9 +819,9 @@ static void switch_set_texture_frame(
|
||||||
switch_video_t *sw = data;
|
switch_video_t *sw = data;
|
||||||
size_t sz = width * height * (rgb32 ? 4 : 2);
|
size_t sz = width * height * (rgb32 ? 4 : 2);
|
||||||
|
|
||||||
if (!sw->menu_texture.pixels ||
|
if ( !sw->menu_texture.pixels
|
||||||
sw->menu_texture.width != width ||
|
|| (sw->menu_texture.width != width)
|
||||||
sw->menu_texture.height != height)
|
|| (sw->menu_texture.height != height))
|
||||||
{
|
{
|
||||||
int xsf, ysf, sf;
|
int xsf, ysf, sf;
|
||||||
struct scaler_ctx *sctx = NULL;
|
struct scaler_ctx *sctx = NULL;
|
||||||
|
@ -869,10 +867,7 @@ static void switch_set_texture_frame(
|
||||||
memcpy(sw->menu_texture.pixels, frame, sz);
|
memcpy(sw->menu_texture.pixels, frame, sz);
|
||||||
}
|
}
|
||||||
|
|
||||||
static void switch_apply_state_changes(void *data)
|
static void switch_apply_state_changes(void *data) { }
|
||||||
{
|
|
||||||
(void)data;
|
|
||||||
}
|
|
||||||
|
|
||||||
static void switch_set_texture_enable(void *data, bool enable, bool full_screen)
|
static void switch_set_texture_enable(void *data, bool enable, bool full_screen)
|
||||||
{
|
{
|
||||||
|
|
|
@ -310,7 +310,7 @@ static int wiiusb_hid_add_adapter(void *data, usb_device_entry *dev)
|
||||||
|
|
||||||
/* Allocate mem for the send control buffer, 32bit aligned */
|
/* Allocate mem for the send control buffer, 32bit aligned */
|
||||||
adapter->send_control_type = WIIUSB_SC_NONE;
|
adapter->send_control_type = WIIUSB_SC_NONE;
|
||||||
adapter->send_control_buffer = memalign(32, 128);
|
adapter->send_control_buffer = (uint8_t*)memalign(32, 128);
|
||||||
|
|
||||||
if (!adapter->send_control_buffer)
|
if (!adapter->send_control_buffer)
|
||||||
{
|
{
|
||||||
|
@ -333,7 +333,7 @@ static int wiiusb_hid_add_adapter(void *data, usb_device_entry *dev)
|
||||||
goto error;
|
goto error;
|
||||||
}
|
}
|
||||||
|
|
||||||
adapter->data = memalign(32, 128);
|
adapter->data = (uint8_t*)memalign(32, 128);
|
||||||
adapter->hid = hid;
|
adapter->hid = hid;
|
||||||
adapter->next = hid->adapters_head;
|
adapter->next = hid->adapters_head;
|
||||||
hid->adapters_head = adapter;
|
hid->adapters_head = adapter;
|
||||||
|
|
|
@ -47,16 +47,17 @@
|
||||||
#include "../accessibility.h"
|
#include "../accessibility.h"
|
||||||
#include "../command.h"
|
#include "../command.h"
|
||||||
#include "../config.def.keybinds.h"
|
#include "../config.def.keybinds.h"
|
||||||
#include "../driver.h"
|
|
||||||
#include "../retroarch.h"
|
|
||||||
#include "../verbosity.h"
|
|
||||||
#include "../configuration.h"
|
#include "../configuration.h"
|
||||||
|
#include "../driver.h"
|
||||||
|
#include "../frontend/frontend_driver.h"
|
||||||
#include "../list_special.h"
|
#include "../list_special.h"
|
||||||
#include "../performance_counters.h"
|
#include "../performance_counters.h"
|
||||||
|
#include "../retroarch.h"
|
||||||
#ifdef HAVE_BSV_MOVIE
|
#ifdef HAVE_BSV_MOVIE
|
||||||
#include "../tasks/task_content.h"
|
#include "../tasks/task_content.h"
|
||||||
#endif
|
#endif
|
||||||
#include "../tasks/tasks_internal.h"
|
#include "../tasks/tasks_internal.h"
|
||||||
|
#include "../verbosity.h"
|
||||||
|
|
||||||
#define HOLD_BTN_DELAY_SEC 2
|
#define HOLD_BTN_DELAY_SEC 2
|
||||||
|
|
||||||
|
|
|
@ -104,7 +104,6 @@ static int menu_action_sublabel_contentless_core(file_list_t *list,
|
||||||
const char *core_path = path;
|
const char *core_path = path;
|
||||||
core_info_t *core_info = NULL;
|
core_info_t *core_info = NULL;
|
||||||
const contentless_core_info_entry_t *entry = NULL;
|
const contentless_core_info_entry_t *entry = NULL;
|
||||||
const char *menu_ident = menu_driver_ident();
|
|
||||||
bool display_runtime = true;
|
bool display_runtime = true;
|
||||||
settings_t *settings = config_get_ptr();
|
settings_t *settings = config_get_ptr();
|
||||||
bool playlist_show_sublabels = settings->bools.playlist_show_sublabels;
|
bool playlist_show_sublabels = settings->bools.playlist_show_sublabels;
|
||||||
|
@ -121,6 +120,9 @@ static int menu_action_sublabel_contentless_core(file_list_t *list,
|
||||||
menu_timedate_date_separator =
|
menu_timedate_date_separator =
|
||||||
(enum playlist_sublabel_last_played_date_separator_type)
|
(enum playlist_sublabel_last_played_date_separator_type)
|
||||||
settings->uints.menu_timedate_date_separator;
|
settings->uints.menu_timedate_date_separator;
|
||||||
|
#if defined(HAVE_OZONE) || defined(HAVE_MATERIALUI)
|
||||||
|
const char *menu_ident = menu_driver_ident();
|
||||||
|
#endif
|
||||||
|
|
||||||
if (playlist_show_sublabels)
|
if (playlist_show_sublabels)
|
||||||
{
|
{
|
||||||
|
|
|
@ -15095,20 +15095,20 @@ bool menu_displaylist_ctl(enum menu_displaylist_ctl_state type,
|
||||||
_len += strlcpy(new_exts + _len, "bmp", sizeof(new_exts) - _len);
|
_len += strlcpy(new_exts + _len, "bmp", sizeof(new_exts) - _len);
|
||||||
#endif
|
#endif
|
||||||
#ifdef HAVE_RPNG
|
#ifdef HAVE_RPNG
|
||||||
if (new_exts[_len-1] != '\0')
|
if (_len > 0 && (new_exts[_len-1] != '\0'))
|
||||||
_len += strlcpy(new_exts + _len, "|", sizeof(new_exts) - _len);
|
_len += strlcpy(new_exts + _len, "|", sizeof(new_exts) - _len);
|
||||||
_len += strlcpy(new_exts + _len, "png", sizeof(new_exts) - _len);
|
_len += strlcpy(new_exts + _len, "png", sizeof(new_exts) - _len);
|
||||||
#endif
|
#endif
|
||||||
#ifdef HAVE_RJPEG
|
#ifdef HAVE_RJPEG
|
||||||
if (new_exts[_len-1] != '\0')
|
if (_len > 0 && (new_exts[_len-1] != '\0'))
|
||||||
_len += strlcpy(new_exts + _len, "|", sizeof(new_exts) - _len);
|
_len += strlcpy(new_exts + _len, "|", sizeof(new_exts) - _len);
|
||||||
_len += strlcpy(new_exts + _len, "jpeg", sizeof(new_exts) - _len);
|
_len += strlcpy(new_exts + _len, "jpeg", sizeof(new_exts) - _len);
|
||||||
if (new_exts[_len-1] != '\0')
|
if (_len > 0 && (new_exts[_len-1] != '\0'))
|
||||||
_len += strlcpy(new_exts + _len, "|", sizeof(new_exts) - _len);
|
_len += strlcpy(new_exts + _len, "|", sizeof(new_exts) - _len);
|
||||||
_len += strlcpy(new_exts + _len, "jpg", sizeof(new_exts) - _len);
|
_len += strlcpy(new_exts + _len, "jpg", sizeof(new_exts) - _len);
|
||||||
#endif
|
#endif
|
||||||
#ifdef HAVE_RTGA
|
#ifdef HAVE_RTGA
|
||||||
if (new_exts[_len-1] != '\0')
|
if (_len > 0 && (new_exts[_len-1] != '\0'))
|
||||||
_len += strlcpy(new_exts + _len, "|", sizeof(new_exts) - _len);
|
_len += strlcpy(new_exts + _len, "|", sizeof(new_exts) - _len);
|
||||||
_len += strlcpy(new_exts + _len, "tga", sizeof(new_exts) - _len);
|
_len += strlcpy(new_exts + _len, "tga", sizeof(new_exts) - _len);
|
||||||
#endif
|
#endif
|
||||||
|
|
|
@ -2168,7 +2168,6 @@ struct string_list *dir_list_new_special(const char *input_dir,
|
||||||
char ext_shaders[255];
|
char ext_shaders[255];
|
||||||
#endif
|
#endif
|
||||||
char ext_name[16];
|
char ext_name[16];
|
||||||
size_t _len = 0;
|
|
||||||
const char *exts = NULL;
|
const char *exts = NULL;
|
||||||
bool recursive = false;
|
bool recursive = false;
|
||||||
|
|
||||||
|
@ -2197,6 +2196,7 @@ struct string_list *dir_list_new_special(const char *input_dir,
|
||||||
case DIR_LIST_SHADERS:
|
case DIR_LIST_SHADERS:
|
||||||
#if defined(HAVE_CG) || defined(HAVE_GLSL) || defined(HAVE_SLANG) || defined(HAVE_HLSL)
|
#if defined(HAVE_CG) || defined(HAVE_GLSL) || defined(HAVE_SLANG) || defined(HAVE_HLSL)
|
||||||
{
|
{
|
||||||
|
size_t _len = 0;
|
||||||
ext_shaders[0] = '\0';
|
ext_shaders[0] = '\0';
|
||||||
|
|
||||||
if (video_shader_is_supported(RARCH_SHADER_CG))
|
if (video_shader_is_supported(RARCH_SHADER_CG))
|
||||||
|
|
Loading…
Reference in New Issue