14 #ifndef POINTEREVENTLIST_H 15 #define POINTEREVENTLIST_H 24 class ModifierPointers;
37 INLINE
size_t get_num_events()
const;
38 INLINE
bool get_in_window(
size_t n)
const;
39 INLINE
int get_xpos(
size_t n)
const;
40 INLINE
int get_ypos(
size_t n)
const;
41 INLINE
double get_dx(
size_t n)
const;
42 INLINE
double get_dy(
size_t n)
const;
43 INLINE
int get_sequence(
size_t n)
const;
44 INLINE
double get_length(
size_t n)
const;
45 INLINE
double get_direction(
size_t n)
const;
46 INLINE
double get_rotation(
size_t n)
const;
47 INLINE
double get_time(
size_t n)
const;
50 INLINE
void pop_front();
51 void add_event(
const PointerData &data,
int seq,
double time);
52 void add_event(
bool in_win,
int xpos,
int ypos,
int seq,
double time);
53 void add_event(
bool in_win,
int xpos,
int ypos,
double xdelta,
double ydelta,
54 int seq,
double time);
56 bool encircles(
int x,
int y)
const;
57 double total_turns(
double sec)
const;
58 double match_pattern(
const std::string &pattern,
double rot,
double seglen);
64 INLINE
bool empty()
const;
67 virtual void output(std::ostream &out)
const;
68 void write(std::ostream &out,
int indent_level = 0)
const;
71 void parse_pattern(
const std::string &ascpat, vector_double &pattern);
79 static void init_type() {
80 ParamValueBase::init_type();
82 ParamValueBase::get_class_type());
85 return get_class_type();
87 virtual TypeHandle force_init_type() {init_type();
return get_class_type();}
93 INLINE std::ostream &operator << (std::ostream &out,
const PointerEventList &pointerlist) {
94 pointerlist.output(out);
void register_type(TypeHandle &type_handle, const std::string &name)
This inline function is just a convenient way to call TypeRegistry::register_type(),...
PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University.
Records a set of pointer events that happened recently.
PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University.
A non-template base class of ParamValue (below), which serves mainly to define the placeholder for th...
PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University.
Holds the data that might be generated by a 2-d pointer input device, such as the mouse in the Graphi...
PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University.
PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University.
A class to retrieve the individual data elements previously stored in a Datagram.
TypeHandle is the identifier used to differentiate C++ class types.
An ordered list of data elements, formatted in memory for transmission over a socket or writing to a ...
PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University.
Records a pointer movement event.