3
3
* @author Mindou (minsu5875@naver.com)
4
4
* @brief external & user define library & etc. function/variable package header
5
5
* @version 0.1
6
- * @date (first date: 2023-05-08)
6
+ * @date (first date: 2023-05-08, last date: 2023-05-23 )
7
7
*
8
8
* @copyright Copyright (c) 2023 Minsu Bak
9
9
*
17
17
18
18
// external library & user define library
19
19
#include "raylib.h"
20
+ #include "image.h"
20
21
21
22
/**
22
23
* @brief main.h variable info
27
28
* #define SCREEN_H n screen size for height
28
29
* #define BTN_W n button size for width
29
30
* #define BTN_H n button size for height
30
- * bool FILE_NOT_FOUND n file find flag (default: false)
31
31
* int btnClickFlag y define click flag for each buttons
32
32
*
33
33
*/
37
37
#define SCREEN_H 600 // screen size: height
38
38
#define BTN_W 100 // button size: width
39
39
#define BTN_H 62 // button size: height
40
+ #define QAUNTUM 2 // default time quantum
41
+ #define P_COUNT 5 // default process count
42
+ #define P_PARAM 4 // default process parameters count
40
43
41
- bool FILE_NOT_FOUND = false; // file find flag
42
- int btnClickFlag [7 ]; // define click flag for each buttons
44
+ int btnClickFlag [7 ]; // define click flag for each buttons
45
+
46
+ // process default data to be used by the simulator
47
+ int pInfo [P_COUNT ][P_PARAM ] = {
48
+ {0 , 0 , 10 , 3 }, // process 0, arrival 0, burst 10, priority 3
49
+ {1 , 1 , 28 , 2 }, // process 1, arrival 1, burst 28, priority 2
50
+ {2 , 2 , 6 , 4 }, // process 2, arrival 2, burst 6, priority 4
51
+ {3 , 3 , 4 , 1 }, // process 3, arrival 3, burst 4, priority 1
52
+ {4 , 4 , 14 , 2 } // process 4, arrival 4, burst 14, priority 2
53
+ };
43
54
44
55
// button color flag
45
56
const Color colorTag [] = {
@@ -55,8 +66,8 @@ const Color colorTag[] = {
55
66
56
67
// logo position
57
68
const Rectangle logo_position [] = {
58
- {.x = SCREEN_W * 0.7f , .y = SCREEN_H * 0.8f , .width = 128 , .height = 128 },
59
- {.x = SCREEN_W * 0.85f , .y = SCREEN_H * 0.8f , .width = 96 , .height = 96 }
69
+ {.x = SCREEN_W * 0.70f , .y = SCREEN_H * 0.8f , .width = 128 , .height = 128 },
70
+ {.x = SCREEN_W * 0.83f , .y = SCREEN_H * 0.8f , .width = 96 , .height = 96 }
60
71
};
61
72
62
73
// script array
0 commit comments