-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathcimgui-knobs.h
More file actions
67 lines (58 loc) · 1.29 KB
/
cimgui-knobs.h
File metadata and controls
67 lines (58 loc) · 1.29 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
#pragma once
#if !defined(EXPORT)
# define EXPORT
#endif
#ifdef __cplusplus
extern "C" {
#endif
#include <stdbool.h>
typedef struct IgKnobColorSet {
unsigned int base;
unsigned int hovered;
unsigned int active;
} IgKnobColorSet;
typedef enum IgKnobFlags {
IgKnobFlags_NoTitle = 1 << 0,
IgKnobFlags_NoInput = 1 << 1,
IgKnobFlags_ValueTooltip = 1 << 2,
IgKnobFlags_DragHorizontal = 1 << 3,
IgKnobFlags_DragVertical = 1 << 4,
} IgKnobFlags;
typedef enum IgKnobVariant {
IgKnobVariant_Tick = 1 << 0,
IgKnobVariant_Dot = 1 << 1,
IgKnobVariant_Wiper = 1 << 2,
IgKnobVariant_WiperOnly = 1 << 3,
IgKnobVariant_WiperDot = 1 << 4,
IgKnobVariant_Stepped = 1 << 5,
IgKnobVariant_Space = 1 << 6,
} IgKnobVariant;
EXPORT bool IgKnobFloat(
const char *label,
float *p_value,
float v_min,
float v_max,
float speed,
const char *format,
IgKnobVariant variant,
float size,
IgKnobFlags flags,
int steps,
float angle_min,
float angle_max);
EXPORT bool IgKnobInt(
const char *label,
int *p_value,
int v_min,
int v_max,
float speed,
const char *format,
IgKnobVariant variant,
float size,
IgKnobFlags flags,
int steps,
float angle_min,
float angle_max);
#ifdef __cplusplus
}
#endif