The MouseSubregion object scales the mouse inputs from within a rectangular region of the screen, as if they were the full-screen inputs.
More...
#include "mouseSubregion.h"
List of all members.
Public Member Functions |
|
| MouseSubregion (const string &name) |
|
virtual TypeHandle | force_init_type () |
| PN_stdfloat | get_bottom () const |
| | Retrieves the y coordinate of the bottom edge of the rectangle within the window.
|
| PN_stdfloat | get_left () const |
| | Retrieves the x coordinate of the left edge of the rectangle within the window.
|
| PN_stdfloat | get_right () const |
| | Retrieves the x coordinate of the right edge of the rectangle within the window.
|
| PN_stdfloat | get_top () const |
| | Retrieves the y coordinate of the top edge of the rectangle within the window.
|
|
virtual TypeHandle | get_type () const |
| void | set_dimensions (PN_stdfloat l, PN_stdfloat r, PN_stdfloat b, PN_stdfloat t) |
| | Changes the region of the window in which the mouse is considered to be active.
|
Static Public Member Functions |
|
static TypeHandle | get_class_type () |
|
static void | init_type () |
Protected Member Functions |
| virtual void | do_transmit_data (DataGraphTraverser *trav, const DataNodeTransmit &input, DataNodeTransmit &output) |
| | The virtual implementation of transmit_data().
|
Detailed Description
The MouseSubregion object scales the mouse inputs from within a rectangular region of the screen, as if they were the full-screen inputs.
If you choose your MouseSubregion coordinates to exactly match a DisplayRegion within your window, you end up with a virtual mouse within your DisplayRegion.
Definition at line 37 of file mouseSubregion.h.
Member Function Documentation
| PN_stdfloat MouseSubregion::get_bottom |
( |
| ) |
const [inline] |
Retrieves the y coordinate of the bottom edge of the rectangle within the window.
This number will be in the range [0..1].
Definition at line 48 of file mouseSubregion.I.
| PN_stdfloat MouseSubregion::get_left |
( |
| ) |
const [inline] |
Retrieves the x coordinate of the left edge of the rectangle within the window.
This number will be in the range [0..1].
Definition at line 24 of file mouseSubregion.I.
| PN_stdfloat MouseSubregion::get_right |
( |
| ) |
const [inline] |
Retrieves the x coordinate of the right edge of the rectangle within the window.
This number will be in the range [0..1].
Definition at line 36 of file mouseSubregion.I.
| PN_stdfloat MouseSubregion::get_top |
( |
| ) |
const [inline] |
Retrieves the y coordinate of the top edge of the rectangle within the window.
This number will be in the range [0..1].
Definition at line 60 of file mouseSubregion.I.
| void MouseSubregion::set_dimensions |
( |
PN_stdfloat |
l, |
|
|
PN_stdfloat |
r, |
|
|
PN_stdfloat |
b, |
|
|
PN_stdfloat |
t |
|
) |
| [inline] |
Changes the region of the window in which the mouse is considered to be active.
The parameters are identical to those for a DisplayRegion: they range from 0 to 1, where 0,0 is the lower left corner and 1,1 is the upper right; (0, 1, 0, 1) represents the whole window.
Definition at line 75 of file mouseSubregion.I.
The documentation for this class was generated from the following files: