Cockatrice/cockatrice/src/game_graphics/player
BruebachL bb0a96984d
[Game] Derive playmat sampling window from shared clamped helpers (#7159)
* [Game] Derive playmat sampling window from shared clamped helpers

The crop formula computed the sampled window inline with an unclamped
zoom floor, so stored vertical offsets below half of travel were dead
and extreme zooms could sample outside the art

Remap verticalOffset to place the window top edge within its travel,
floor zoom at visible width over min card side with a 4.0 ceiling,
clamp pan along the margin sum constant segment, and expose
playmatClampedZoom, playmatWindowSide and aspectFitRect so the game
renderer and any editor share one geometry model

Zoom 1 rendering is bit identical to before

Took 7 seconds

* Comments.

Took 29 minutes

---------

Co-authored-by: Lukas Brübach <Bruebach.Lukas@bdosecurity.de>
2026-08-23 17:26:15 +02:00
..
menu [Settings] Shuffle some settings around (#7084) 2026-08-08 22:27:41 +02:00
card_menu_action_type.h [Game] Move graphics out of game and into game_graphics (#6928) 2026-06-09 09:51:13 +02:00
player_area.cpp [Game] Move graphics out of game and into game_graphics (#6928) 2026-06-09 09:51:13 +02:00
player_area.h [Game] Move graphics out of game and into game_graphics (#6928) 2026-06-09 09:51:13 +02:00
player_dialogs.cpp Split trice_limits.h into dedicated headers (#7025) 2026-06-29 14:37:52 -07:00
player_dialogs.h [Game] Move graphics out of game and into game_graphics (#6928) 2026-06-09 09:51:13 +02:00
player_graphics_item.cpp [Game] Derive playmat sampling window from shared clamped helpers (#7159) 2026-08-23 17:26:15 +02:00
player_graphics_item.h [Game] Playmats (#7101) 2026-08-21 10:40:49 +02:00
player_list_widget.cpp [CI] Remove Qt5 (#7071) 2026-08-08 22:04:50 +02:00
player_list_widget.h [Game] Move graphics out of game and into game_graphics (#6928) 2026-06-09 09:51:13 +02:00
player_target.cpp [CI] No need to capture a variable in a lambda. (#7109) 2026-08-13 20:51:23 +02:00
player_target.h [Game] Animate life counter manipulation (#7100) 2026-08-13 19:12:12 +02:00