45 lines
1.0 KiB
C
45 lines
1.0 KiB
C
/*
|
|
* etcpmon_graph.h - ETCP Monitor Graph Definitions
|
|
*/
|
|
|
|
#ifndef ETCPMON_GRAPH_H
|
|
#define ETCPMON_GRAPH_H
|
|
|
|
#ifndef WIN32_LEAN_AND_MEAN
|
|
#define WIN32_LEAN_AND_MEAN
|
|
#endif
|
|
|
|
#include <windows.h>
|
|
#include <stdint.h>
|
|
|
|
#ifdef __cplusplus
|
|
extern "C" {
|
|
#endif
|
|
|
|
/* Graph constants */
|
|
#define GRAPH_WIDTH 860
|
|
#define GRAPH_HEIGHT 150
|
|
#define CHANNEL_LIST_HEIGHT 80
|
|
#define GRAPH_METRICS_COUNT 8
|
|
#define GRAPH_HISTORY_SIZE 860
|
|
|
|
/* Forward declarations */
|
|
struct etcpmon_app;
|
|
struct metrics_history;
|
|
|
|
/* Graph colors for each metric */
|
|
extern const COLORREF graph_colors[GRAPH_METRICS_COUNT];
|
|
extern const char* graph_metric_names[GRAPH_METRICS_COUNT];
|
|
|
|
/* Graph functions */
|
|
LRESULT CALLBACK GraphWndProc(HWND hWnd, UINT message, WPARAM wParam, LPARAM lParam);
|
|
void DrawGraph(HDC hdc, RECT* rc, struct etcpmon_app* app);
|
|
void GetSelectedChannels(struct etcpmon_app* app, int* selected, int* count);
|
|
void UpdateChannelValues(struct etcpmon_app* app, int cursor_sample);
|
|
|
|
#ifdef __cplusplus
|
|
}
|
|
#endif
|
|
|
|
#endif /* ETCPMON_GRAPH_H */
|