AiCPlayer
Interface of aic vm - for rendering aspect, sensors, video records
Macros | Functions | Variables
sdl_events.c File Reference

Produce virtual input events from SDL events. More...

#include <pthread.h>
#include <sys/time.h>
#include <time.h>
#include <linux/input.h>
#include "buffer_sizes.h"
#include "logger.h"
#include "grabber.h"
#include "sdl_events.h"
#include "sdl_translate.h"
Include dependency graph for sdl_events.c:

Go to the source code of this file.

Macros

#define LOG_TAG   "sdl_events"
 

Functions

int sdl_key (SDL_Event *event, socket_t input_socket)
 Produce a key press/release event to the virtual input. More...
 
int sdl_mouse_motion (SDL_Event *event, socket_t input_socket)
 Produce a mouse motion event to the virtual input. More...
 
int sdl_mouse_wheel (SDL_Event *event, socket_t input_socket)
 Produce a mouse wheel event to the virtual input. More...
 
int sdl_mouse_button (SDL_Event *event, socket_t input_socket)
 Produce a mouse click event to the virtual input. More...
 

Variables

int g_width
 Global variable for the window width. More...
 
int g_height
 Global variable for the window height. More...
 
float g_rotation
 

Detailed Description

Produce virtual input events from SDL events.

Definition in file sdl_events.c.

Macro Definition Documentation

#define LOG_TAG   "sdl_events"

Definition at line 15 of file sdl_events.c.

Function Documentation

int sdl_key ( SDL_Event *  event,
socket_t  input_socket 
)

Produce a key press/release event to the virtual input.

Definition at line 64 of file sdl_events.c.

Here is the call graph for this function:

int sdl_mouse_button ( SDL_Event *  event,
socket_t  input_socket 
)

Produce a mouse click event to the virtual input.

Definition at line 141 of file sdl_events.c.

int sdl_mouse_motion ( SDL_Event *  event,
socket_t  input_socket 
)

Produce a mouse motion event to the virtual input.

Definition at line 112 of file sdl_events.c.

int sdl_mouse_wheel ( SDL_Event *  event,
socket_t  input_socket 
)

Produce a mouse wheel event to the virtual input.

Definition at line 126 of file sdl_events.c.

Variable Documentation

int g_height

Global variable for the window height.

Height of the window (can be resized at runtime)

Shared with the grabber.

Definition at line 87 of file main.c.

float g_rotation

Rotation angle of the VM

Shared width sdl events

Definition at line 100 of file main.c.

int g_width

Global variable for the window width.

Width of the window (can be resized at runtime)

Shared with the grabber.

Definition at line 93 of file main.c.