svcore
1.9
|
Display zoom level. More...
#include <ZoomLevel.h>
Public Types | |
enum | Zone { FramesPerPixel, PixelsPerFrame } |
Public Member Functions | |
ZoomLevel () | |
ZoomLevel (Zone z, int lev) | |
bool | operator< (const ZoomLevel &other) const |
bool | operator== (const ZoomLevel &other) const |
ZoomLevel | incremented () const |
ZoomLevel | decremented () const |
double | framesToPixels (double frames) const |
Inexact conversion. More... | |
double | pixelsToFrames (double pixels) const |
Inexact conversion. More... | |
Static Public Member Functions | |
static ZoomLevel | fromRatio (int pixels, sv_frame_t frames) |
Return a ZoomLevel that approximates the given ratio of pixels to frames. More... | |
Public Attributes | |
Zone | zone |
int | level |
Detailed Description
Display zoom level.
Can be an integer number of samples per pixel, or an integer number of pixels per sample.
Definition at line 26 of file ZoomLevel.h.
Member Enumeration Documentation
enum ZoomLevel::Zone |
Enumerator | |
---|---|
FramesPerPixel | |
PixelsPerFrame |
Definition at line 28 of file ZoomLevel.h.
Constructor & Destructor Documentation
|
inline |
Definition at line 36 of file ZoomLevel.h.
|
inline |
Definition at line 37 of file ZoomLevel.h.
Member Function Documentation
|
inline |
Definition at line 39 of file ZoomLevel.h.
References FramesPerPixel, level, and zone.
|
inline |
Definition at line 55 of file ZoomLevel.h.
|
inline |
Definition at line 59 of file ZoomLevel.h.
References FramesPerPixel, and zone.
|
inline |
Definition at line 71 of file ZoomLevel.h.
References PixelsPerFrame, and zone.
|
inline |
Inexact conversion.
The result is a whole number if we are zoomed in enough (in PixelsPerFrame zone), a fraction otherwise.
Definition at line 85 of file ZoomLevel.h.
References level, and PixelsPerFrame.
|
inline |
Inexact conversion.
The result is a whole number if we are zoomed out enough (in FramesPerPixel zone), a fraction otherwise.
Definition at line 97 of file ZoomLevel.h.
References level, and PixelsPerFrame.
|
inlinestatic |
Return a ZoomLevel that approximates the given ratio of pixels to frames.
Definition at line 108 of file ZoomLevel.h.
References FramesPerPixel, operator<<(), and PixelsPerFrame.
Member Data Documentation
Zone ZoomLevel::zone |
Definition at line 33 of file ZoomLevel.h.
Referenced by decremented(), RelativelyFineZoomConstraint::getNearestZoomLevel(), PowerOfTwoZoomConstraint::getNearestZoomLevel(), PowerOfSqrtTwoZoomConstraint::getNearestZoomLevel(), ZoomConstraint::getNearestZoomLevel(), incremented(), operator<(), operator<<(), and operator==().
int ZoomLevel::level |
Definition at line 34 of file ZoomLevel.h.
Referenced by framesToPixels(), PowerOfTwoZoomConstraint::getNearestBlockSize(), PowerOfSqrtTwoZoomConstraint::getNearestBlockSize(), RelativelyFineZoomConstraint::getNearestZoomLevel(), PowerOfSqrtTwoZoomConstraint::getNearestZoomLevel(), PowerOfTwoZoomConstraint::getNearestZoomLevel(), ZoomConstraint::getNearestZoomLevel(), operator<(), operator<<(), operator==(), and pixelsToFrames().
The documentation for this struct was generated from the following file:
Generated by 1.8.11