![]() |
OpendTect
6.3
|
Auxiliary class to control dragger speed. The idea is that slowly moving the mouse forces the dragger to move only one inl/crl/z per (few) pixel(s), while moving it fast can have it cover many lines per pixel. More...
Public Member Functions | |
| DragController () | |
| ~DragController () | |
| void | init (const Coord &mousepos, double scalefactor=1.0, const Coord3 &dragdir=Coord3(0.0, 0.0, 0.0)) |
| void | setFastMaxDragToMouseRatio (float distanceperpixel) |
| float | getFastMaxDragToMouseRatio () const |
| void | setSlowMaxDragToMouseRatio (float distanceperpixel) |
| float | getSlowMaxDragToMouseRatio () const |
| void | setFastMinDragToMouseRatio (float distanceperpixel) |
| float | getFastMinDragToMouseRatio () const |
| void | setSlowMinDragToMouseRatio (float distanceperpixel) |
| float | getSlowMinDragToMouseRatio () const |
| void | setFastMouseSpeed (float pixelspersecond) |
| float | getFastMouseSpeed () const |
| void | setSlowMouseSpeed (float pixelspersecond) |
| float | getSlowMouseSpeed () const |
| void | setLinearBackDragFrac (float fraction) |
| float | getLinearBackDragFrac () const |
| void | transform (double &dragval, const Coord &mousepos, double maxdragdist=mUdf(double)) |
| void | transform (Coord3 &dragvec, const Coord &mousepos, double maxdragdist=mUdf(double)) |
| void | dragInScreenSpace (bool fromstart, const Coord &projvec) |
Protected Member Functions | |
| void | reInit (const Coord &mousepos) |
| void | manageScreenDragging (double &dragval, const Coord &mousepos) |
| double | absTransform (double dragval, const Coord &mousepos, double maxdragdist=mUdf(double)) |
Protected Attributes | |
| float | fastmaxdragtomouseratio_ |
| float | slowmaxdragtomouseratio_ |
| float | fastmindragtomouseratio_ |
| float | slowmindragtomouseratio_ |
| float | fastmousespeed_ |
| float | slowmousespeed_ |
| float | linearbackdragfrac_ |
| Coord | initmousepos_ |
| Coord3 | dragdir_ |
| int | prevdragtime_ |
| bool | screendragmode_ |
| float | screendragfactor_ |
| Coord | screendragprojvec_ |
| Coord | prevmousepos_ |
| double | prevdragval_ |
| double | prevtransval_ |
| double | maxdragval_ |
| int | dragsign_ |
| double | scalefactor_ |
Auxiliary class to control dragger speed. The idea is that slowly moving the mouse forces the dragger to move only one inl/crl/z per (few) pixel(s), while moving it fast can have it cover many lines per pixel.
| DragController::DragController | ( | ) |
| DragController::~DragController | ( | ) |
|
protected |
| void DragController::dragInScreenSpace | ( | bool | fromstart, |
| const Coord & | projvec | ||
| ) |
| float DragController::getFastMaxDragToMouseRatio | ( | ) | const |
| float DragController::getFastMinDragToMouseRatio | ( | ) | const |
| float DragController::getFastMouseSpeed | ( | ) | const |
| float DragController::getLinearBackDragFrac | ( | ) | const |
If moving back towards initial position, 'fraction' defines where the dragger starts acting linear to reach its origin at the same time as the mouse pointer.
| float DragController::getSlowMaxDragToMouseRatio | ( | ) | const |
| float DragController::getSlowMinDragToMouseRatio | ( | ) | const |
| float DragController::getSlowMouseSpeed | ( | ) | const |
| void DragController::init | ( | const Coord & | mousepos, |
| double | scalefactor = 1.0, |
||
| const Coord3 & | dragdir = Coord3(0.0, 0.0, 0.0) |
||
| ) |
|
protected |
|
protected |
| void DragController::setFastMaxDragToMouseRatio | ( | float | distanceperpixel | ) |
| void DragController::setFastMinDragToMouseRatio | ( | float | distanceperpixel | ) |
| void DragController::setFastMouseSpeed | ( | float | pixelspersecond | ) |
| void DragController::setLinearBackDragFrac | ( | float | fraction | ) |
| void DragController::setSlowMaxDragToMouseRatio | ( | float | distanceperpixel | ) |
| void DragController::setSlowMinDragToMouseRatio | ( | float | distanceperpixel | ) |
| void DragController::setSlowMouseSpeed | ( | float | pixelspersecond | ) |
| void DragController::transform | ( | double & | dragval, |
| const Coord & | mousepos, | ||
| double | maxdragdist = mUdf(double) |
||
| ) |
| void DragController::transform | ( | Coord3 & | dragvec, |
| const Coord & | mousepos, | ||
| double | maxdragdist = mUdf(double) |
||
| ) |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
Generated at for the OpendTect seismic interpretation project. Copyright (C): dGB Beheer B. V. 2017