|
| qreal | playmatVisibleWidth (const QSize &fullCardSize, const PlaymatParams ¶ms) |
| | Width of the outer viewing window: full card width trimmed by the horizontal margins. Guarded against margins summing to >= 1.
|
| qreal | playmatClampedZoom (const QSize &fullCardSize, const PlaymatParams ¶ms) |
| | Zoom clamped to the range where every step renders differently.
|
| qreal | playmatWindowSide (const QSize &fullCardSize, const PlaymatParams ¶ms) |
| | Side of the square sampling window actually rendered for these parameters. Never exceeds either card dimension, so the source rect always lies within the image (vertical travel remains for panning whenever the art is taller than it is wide).
|
| QRectF | computeArtSourceRect (const QSize &fullCardSize, const PlaymatParams ¶ms) |
| | Computes the source region of the full resolution card image to use as a playmat.
|
| QRectF | coverFitRect (const QRectF &dstArea, const QSizeF &srcSize) |
| | Returns the destination rectangle that fits a source of the given aspect ratio into dstArea using "cover" semantics (no distortion, overflows cropped).
|
| QRectF | aspectFitRect (const QRectF &dstArea, qreal aspect) |
| | Fits a rectangle of the given aspect ratio into dstArea, centered, touching the constraining dimension ("aspect fit" of the FRAME itself, not of a source image).
|
| qreal PlaymatUtils::playmatClampedZoom |
( |
const QSize & | fullCardSize, |
|
|
const PlaymatParams & | params ) |
|
inline |
Zoom clamped to the range where every step renders differently.
The square sampling window is visibleWidth / zoom, zooming out past visibleWidth / min(card width, height) would sample beyond the card itself, which both looks broken and makes whole ranges of the parameter dead. The floor is therefore derived from the actual image instead of a static value, and is shared verbatim by the render path and the editor's gesture math so the two can never disagree.