This commit is contained in:
音游玩的人 2023-07-30 14:45:21 +08:00 committed by GitHub
parent fe24b5a00f
commit 7f9223ecc6
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -1,6 +1,6 @@
/* /*
WouoUI - osu WouoUI 仿 osu! v1.1 WouoUI - osu WouoUI 仿 osu!
线 线
@ -11,10 +11,6 @@
* 128 * 32 128 * 64 * 128 * 32 128 * 64
* *
WouoUI - osu v1.3
*
WouoUI v2 WouoUI v2
* 使线 * 使线
@ -277,13 +273,13 @@ M_SELECT setting_menu[]
M_SELECT about_menu[] M_SELECT about_menu[]
{ {
{"[ WouoUI - osu ]"}, {"[ WouoUI - osu ]"},
{"- Version: v1.3"}, {"- Version: v1.4"},
{"- Board: STM32F103"}, {"- Board: STM32F103"},
{"- Ram: 20k"}, {"- Ram: 20k"},
{"- Flash: 64k"}, {"- Flash: 64k"},
{"- Freq: 72Mhz"}, {"- Freq: 72Mhz"},
{"- Creator: RQNG"}, {"- Creator: RQNG"},
{"- Billi UID: 9182439"}, {"- Bili UID: 9182439"},
}; };
/************************************* 页面变量 *************************************/ /************************************* 页面变量 *************************************/
@ -334,7 +330,7 @@ struct
#define LIST_LINE_H 16 //列表单行高度 #define LIST_LINE_H 16 //列表单行高度
#define LIST_TEXT_S 4 //列表每行文字的上边距,左边距和右边距,下边距由它和字体高度和行高度决定 #define LIST_TEXT_S 4 //列表每行文字的上边距,左边距和右边距,下边距由它和字体高度和行高度决定
#define LIST_BAR_W 5 //列表进度条宽度需要是奇数因为正中间有1像素宽度的线 #define LIST_BAR_W 5 //列表进度条宽度需要是奇数因为正中间有1像素宽度的线
#define LIST_BOX_R 0.5 //列表选择框圆角 #define LIST_BOX_R 0.5f //列表选择框圆角
*/ */
//超窄行高度测试 //超窄行高度测试
@ -343,7 +339,7 @@ struct
#define LIST_LINE_H 7 //列表单行高度 #define LIST_LINE_H 7 //列表单行高度
#define LIST_TEXT_S 1 //列表每行文字的上边距,左边距和右边距,下边距由它和字体高度和行高度决定 #define LIST_TEXT_S 1 //列表每行文字的上边距,左边距和右边距,下边距由它和字体高度和行高度决定
#define LIST_BAR_W 7 //列表进度条宽度需要是奇数因为正中间有1像素宽度的线 #define LIST_BAR_W 7 //列表进度条宽度需要是奇数因为正中间有1像素宽度的线
#define LIST_BOX_R 0.5 //列表选择框圆角 #define LIST_BOX_R 0.5f //列表选择框圆角
struct struct
{ {
@ -751,8 +747,8 @@ void animation(float *a, float *a_trg, uint8_t n)
{ {
if (*a != *a_trg) if (*a != *a_trg)
{ {
if (fabs(*a - *a_trg) < 0.15) *a = *a_trg; if (fabs(*a - *a_trg) < 0.15f) *a = *a_trg;
else *a += (*a_trg - *a) / (ui.param[n] / 10.0); else *a += (*a_trg - *a) / (ui.param[n] / 10.0f);
} }
} }
@ -858,7 +854,7 @@ void list_show(struct MENU arr[], uint8_t ui_index)
{ {
if (ui.param[LIST_UFD]) list.temp = i * list.y - LIST_LINE_H * ui.select[ui.layer]; if (ui.param[LIST_UFD]) list.temp = i * list.y - LIST_LINE_H * ui.select[ui.layer];
else list.temp = (i - ui.select[ui.layer]) * list.y; else list.temp = (i - ui.select[ui.layer]) * list.y;
list.curve = (ui.param[LIST_CUR] / 1000.0) * pow(list.temp, 2); list.curve = (ui.param[LIST_CUR] / 1000.0f) * pow(list.temp, 2);
list_draw_text_and_check_box(arr, i); list_draw_text_and_check_box(arr, i);
} }
if (list.y == list.y_trg) if (list.y == list.y_trg)
@ -870,7 +866,7 @@ void list_show(struct MENU arr[], uint8_t ui_index)
else for (int i = 0; i < ui.num[ui_index]; ++ i) else for (int i = 0; i < ui.num[ui_index]; ++ i)
{ {
list.temp = LIST_LINE_H * i + list.y; list.temp = LIST_LINE_H * i + list.y;
list.curve = (ui.param[LIST_CUR] / 1000.0) * pow(list.temp, 2); list.curve = (ui.param[LIST_CUR] / 1000.0f) * pow(list.temp, 2);
list_draw_text_and_check_box(arr, i); list_draw_text_and_check_box(arr, i);
} }