#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <math.h>
#include <GL/glut.h>
#include <AR/gsub.h>
#include <AR/param.h>
#include <AR/matrix.h>
#include <AR/ar.h>
#include <AR/video.h>
#include <AR/arMulti.h>
#include "paddle.h"
Go to the source code of this file.
Classes | |
struct | targetInfo |
Defines | |
#define | NOT_TOUCHED -1 |
#define | TARGET_NUM 5 |
#define | TOUCHED 1 |
Functions | |
static int | checkCollision (float Pos1[], float Pos2[], float range) |
static void | cleanup (void) |
static void | draw (targetInfo myTarget, double BaseTrans[3][4]) |
int | draw_paddle (ARPaddleInfo *paddleInfo) |
int | drawGroundGrid (double trans[3][4], int divisions, float x, float y, float height) |
static void | findPaddlePosition (float curPaddlePos[], double card_trans[3][4], double base_trans[3][4]) |
static void | init (void) |
static void | keyEvent (unsigned char key, int x, int y) |
int | main (int argc, char **argv) |
static void | mainLoop (void) |
Variables | |
GLfloat | ambi [] = {0.1, 0.1, 0.1, 0.1} |
ARMultiMarkerInfoT * | config |
char * | config_name = "Data/multi/marker.dat" |
int | count = 0 |
ARParam | cparam |
char * | cparam_name = "Data/camera_para.dat" |
GLfloat | light_position [] = {100.0,-200.0,200.0,0.0} |
GLfloat | lightZeroColor [] = {0.9, 0.9, 0.9, 0.1} |
int | marker_flag [AR_SQUARE_MAX] |
targetInfo | myTarget [TARGET_NUM] |
char * | paddle_name = "Data/paddle_data" |
ARPaddleInfo * | paddleInfo |
int | thresh = 100 |
char * | vconf = "" |
int | xsize |
int | ysize |
#define NOT_TOUCHED -1 |
Definition at line 22 of file backup/examples/paddleInteraction/paddleInteractionTest.c.
#define TARGET_NUM 5 |
Definition at line 23 of file backup/examples/paddleInteraction/paddleInteractionTest.c.
#define TOUCHED 1 |
Definition at line 21 of file backup/examples/paddleInteraction/paddleInteractionTest.c.
static int checkCollision | ( | float | Pos1[], |
float | Pos2[], | ||
float | range | ||
) | [static] |
Definition at line 320 of file backup/examples/paddleInteraction/paddleInteractionTest.c.
static void cleanup | ( | void | ) | [static] |
Definition at line 263 of file backup/examples/paddleInteraction/paddleInteractionTest.c.
static void draw | ( | targetInfo | myTarget, |
double | BaseTrans[3][4] | ||
) | [static] |
Definition at line 337 of file backup/examples/paddleInteraction/paddleInteractionTest.c.
int draw_paddle | ( | ARPaddleInfo * | paddleInfo | ) |
int drawGroundGrid | ( | double | trans[3][4], |
int | divisions, | ||
float | x, | ||
float | y, | ||
float | height | ||
) |
static void findPaddlePosition | ( | float | curPaddlePos[], |
double | card_trans[3][4], | ||
double | base_trans[3][4] | ||
) | [static] |
Definition at line 271 of file backup/examples/paddleInteraction/paddleInteractionTest.c.
static void init | ( | void | ) | [static] |
static void keyEvent | ( | unsigned char | key, |
int | x, | ||
int | y | ||
) | [static] |
Definition at line 89 of file backup/examples/paddleInteraction/paddleInteractionTest.c.
int main | ( | int | argc, |
char ** | argv | ||
) |
Definition at line 75 of file backup/examples/paddleInteraction/paddleInteractionTest.c.
static void mainLoop | ( | void | ) | [static] |
Definition at line 121 of file backup/examples/paddleInteraction/paddleInteractionTest.c.
GLfloat ambi[] = {0.1, 0.1, 0.1, 0.1} |
Definition at line 62 of file backup/examples/paddleInteraction/paddleInteractionTest.c.
Definition at line 54 of file backup/examples/paddleInteraction/paddleInteractionTest.c.
char* config_name = "Data/multi/marker.dat" |
Definition at line 53 of file backup/examples/paddleInteraction/paddleInteractionTest.c.
int count = 0 |
Definition at line 48 of file backup/examples/paddleInteraction/paddleInteractionTest.c.
Definition at line 51 of file backup/examples/paddleInteraction/paddleInteractionTest.c.
char* cparam_name = "Data/camera_para.dat" |
Definition at line 50 of file backup/examples/paddleInteraction/paddleInteractionTest.c.
GLfloat light_position[] = {100.0,-200.0,200.0,0.0} |
Definition at line 61 of file backup/examples/paddleInteraction/paddleInteractionTest.c.
GLfloat lightZeroColor[] = {0.9, 0.9, 0.9, 0.1} |
Definition at line 63 of file backup/examples/paddleInteraction/paddleInteractionTest.c.
int marker_flag[AR_SQUARE_MAX] |
Definition at line 57 of file backup/examples/paddleInteraction/paddleInteractionTest.c.
Definition at line 42 of file backup/examples/paddleInteraction/paddleInteractionTest.c.
char* paddle_name = "Data/paddle_data" |
Definition at line 59 of file backup/examples/paddleInteraction/paddleInteractionTest.c.
Definition at line 58 of file backup/examples/paddleInteraction/paddleInteractionTest.c.
int thresh = 100 |
Definition at line 47 of file backup/examples/paddleInteraction/paddleInteractionTest.c.
char* vconf = "" |
Definition at line 32 of file backup/examples/paddleInteraction/paddleInteractionTest.c.
int xsize |
Definition at line 46 of file backup/examples/paddleInteraction/paddleInteractionTest.c.
int ysize |
Definition at line 46 of file backup/examples/paddleInteraction/paddleInteractionTest.c.