Ignore:
Timestamp:
Dec 1, 2009, 10:51:51 PM (15 years ago)
Author:
Rick van der Zwet
Message:

Bit hacky, but uinput did not do the trick. Using the X11Test does the trick

File:
1 edited

Legend:

Unmodified
Added
Removed
  • liacs/mss/project/colour-tracking.c

    r15 r17  
    99#include <highgui.h>
    1010#include <stdio.h>
     11#include "xdo.h"
    1112
    1213#define DEBUG 1
     
    1516#define GVALUE(x,y,step) (x*step+y*3+1)
    1617#define BVALUE(x,y,step) (x*step+y*3+0)
     18
     19/* XXX: Global variables */
     20xdo_t *xdo;
    1721
    1822/* Used for playing with bounderies, returned max value of the pair */
     
    6771    int r, g, b;
    6872    int q;
     73    int retval;
     74    char arg1[4], arg2[4];
    6975       
    7076   
     
    149155        cvCopy(output,filter, NULL);
    150156        cvCircle(target, cvPoint(xmax, ymax), 10, CV_RGB(255,0,0),4, 8, 0);
     157        xdo_mousemove(xdo,xmax,ymax);
    151158                       
    152159
     
    181188// Quick at 1.0.0, not needing in  2.0x anymore
    182189int main(int argc, char *argv[]) {
    183    return InitSystem(argc, argv);
     190   int retval;
     191   xdo = xdo_new(getenv("DISPLAY"));
     192   retval = InitSystem(argc, argv);
     193   xdo_free(xdo);
    184194}
Note: See TracChangeset for help on using the changeset viewer.