diff --git a/src/main/iidxhook-util/config-gfx.c b/src/main/iidxhook-util/config-gfx.c index 0f90cfe..02fbd6d 100644 --- a/src/main/iidxhook-util/config-gfx.c +++ b/src/main/iidxhook-util/config-gfx.c @@ -220,13 +220,13 @@ void iidxhook_config_gfx_get(struct iidxhook_config_gfx* config_gfx, } if (!strcmp(tmp, "none")) { - config_gfx->scale_back_buffer_filter = D3D9_BACK_BUFFER_SCALE_FILTER_NONE; + config_gfx->scale_back_buffer_filter = IIDXHOOK_UTIL_D3D9_BACK_BUFFER_SCALE_FILTER_NONE; } else if (!strcmp(tmp, "linear")) { - config_gfx->scale_back_buffer_filter = D3D9_BACK_BUFFER_SCALE_FILTER_LINEAR; + config_gfx->scale_back_buffer_filter = IIDXHOOK_UTIL_D3D9_BACK_BUFFER_SCALE_FILTER_LINEAR; } else if (!strcmp(tmp, "point")) { - config_gfx->scale_back_buffer_filter = D3D9_BACK_BUFFER_SCALE_FILTER_POINT; + config_gfx->scale_back_buffer_filter = IIDXHOOK_UTIL_D3D9_BACK_BUFFER_SCALE_FILTER_POINT; } else { - config_gfx->scale_back_buffer_filter = D3D9_BACK_BUFFER_SCALE_FILTER_NONE; + config_gfx->scale_back_buffer_filter = IIDXHOOK_UTIL_D3D9_BACK_BUFFER_SCALE_FILTER_NONE; log_warning("Invalid value for key '%s' specified, fallback " "to default '%s'", IIDXHOOK_CONFIG_GFX_SCALE_BACK_BUFFER_FILTER_KEY, diff --git a/src/main/iidxhook-util/config-gfx.h b/src/main/iidxhook-util/config-gfx.h index 370bb3e..c71895f 100644 --- a/src/main/iidxhook-util/config-gfx.h +++ b/src/main/iidxhook-util/config-gfx.h @@ -17,7 +17,7 @@ struct iidxhook_config_gfx { int32_t window_height; uint16_t scale_back_buffer_width; uint16_t scale_back_buffer_height; - enum d3d9_back_buffer_scale_filter scale_back_buffer_filter; + enum iidxhook_util_d3d9_back_buffer_scale_filter scale_back_buffer_filter; }; void iidxhook_config_gfx_init(struct cconfig* config); diff --git a/src/test/iidxhook-util/iidxhook-util-config-gfx-test.c b/src/test/iidxhook-util/iidxhook-util-config-gfx-test.c index b2a5fb6..d107e92 100644 --- a/src/test/iidxhook-util/iidxhook-util-config-gfx-test.c +++ b/src/test/iidxhook-util/iidxhook-util-config-gfx-test.c @@ -27,7 +27,7 @@ static void test_config_gfx_defaults() check_bool_false(config_gfx.windowed); check_int_eq(config_gfx.scale_back_buffer_width, 0); check_int_eq(config_gfx.scale_back_buffer_height, 0); - check_int_eq(config_gfx.scale_back_buffer_width, D3D9_BACK_BUFFER_SCALE_FILTER_NONE); + check_int_eq(config_gfx.scale_back_buffer_width, IIDXHOOK_UTIL_D3D9_BACK_BUFFER_SCALE_FILTER_NONE); } static void test_config_gfx() @@ -62,7 +62,7 @@ static void test_config_gfx() check_bool_true(config_gfx.windowed); check_int_eq(config_gfx.scale_back_buffer_width, 1920); check_int_eq(config_gfx.scale_back_buffer_height, 1080); - check_int_eq(config_gfx.scale_back_buffer_filter, D3D9_BACK_BUFFER_SCALE_FILTER_LINEAR); + check_int_eq(config_gfx.scale_back_buffer_filter, IIDXHOOK_UTIL_D3D9_BACK_BUFFER_SCALE_FILTER_LINEAR); } static void test_config_gfx_invalid_values() @@ -97,7 +97,7 @@ static void test_config_gfx_invalid_values() check_bool_false(config_gfx.windowed); check_int_eq(config_gfx.scale_back_buffer_width, 0); check_int_eq(config_gfx.scale_back_buffer_height, 0); - check_int_eq(config_gfx.scale_back_buffer_width, D3D9_BACK_BUFFER_SCALE_FILTER_NONE); + check_int_eq(config_gfx.scale_back_buffer_width, IIDXHOOK_UTIL_D3D9_BACK_BUFFER_SCALE_FILTER_NONE); } TEST_MODULE_BEGIN("iidxhook-config-gfx")