A bit more custom-client framework.

This commit is contained in:
Michael Jumper
2010-09-07 21:21:03 -07:00
parent 51f71d40ba
commit a70a5bad39
6 changed files with 360 additions and 228 deletions

View File

@@ -1,6 +1,26 @@
#ifndef _PROXY_H_
#define _PROXY_H
#ifndef _CLIENT_H
#define _CLIENT_H
void client(int client_fd);
#include <png.h>
#include "guacio.h"
typedef struct guac_client {
GUACIO* io;
void* data;
void (*handle_messages)(struct guac_client* client);
void (*mouse_handler)(struct guac_client* client, int x, int y, int button_mask);
void (*key_handler)(struct guac_client* client, int keysym, int pressed);
void (*free_handler)(void* client);
} guac_client;
guac_client* guac_get_client(int client_fd, void (*client_init)(guac_client* client));
void guac_start_client(guac_client* client);
void guac_free_client(guac_client* client);
png_byte** guac_alloc_png_buffer(int w, int h, int bpp);
void guac_free_png_buffer(png_byte** png_buffer, int h);
#endif