xwayland: add force_zero_scaling
This commit is contained in:
parent
64ce06a353
commit
6beb79f27b
8 changed files with 28 additions and 9 deletions
|
|
@ -1355,7 +1355,7 @@ void CHyprRenderer::arrangeLayersForMonitor(const int& monitor) {
|
|||
PMONITOR->vecReservedBottomRight.x, PMONITOR->vecReservedBottomRight.y);
|
||||
}
|
||||
|
||||
void CHyprRenderer::damageSurface(wlr_surface* pSurface, double x, double y) {
|
||||
void CHyprRenderer::damageSurface(wlr_surface* pSurface, double x, double y, double scale) {
|
||||
if (!pSurface)
|
||||
return; // wut?
|
||||
|
||||
|
|
@ -1365,6 +1365,8 @@ void CHyprRenderer::damageSurface(wlr_surface* pSurface, double x, double y) {
|
|||
pixman_region32_t damageBox;
|
||||
pixman_region32_init(&damageBox);
|
||||
wlr_surface_get_effective_damage(pSurface, &damageBox);
|
||||
if (scale != 1.0)
|
||||
wlr_region_scale(&damageBox, &damageBox, scale);
|
||||
|
||||
// schedule frame events
|
||||
if (!wl_list_empty(&pSurface->current.frame_callback_list)) {
|
||||
|
|
|
|||
|
|
@ -11,16 +11,14 @@
|
|||
struct SMonitorRule;
|
||||
|
||||
// TODO: add fuller damage tracking for updating only parts of a window
|
||||
enum DAMAGETRACKINGMODES
|
||||
{
|
||||
enum DAMAGETRACKINGMODES {
|
||||
DAMAGE_TRACKING_INVALID = -1,
|
||||
DAMAGE_TRACKING_NONE = 0,
|
||||
DAMAGE_TRACKING_MONITOR,
|
||||
DAMAGE_TRACKING_FULL
|
||||
};
|
||||
|
||||
enum eRenderPassMode
|
||||
{
|
||||
enum eRenderPassMode {
|
||||
RENDER_PASS_ALL = 0,
|
||||
RENDER_PASS_MAIN,
|
||||
RENDER_PASS_POPUP
|
||||
|
|
@ -35,7 +33,7 @@ class CHyprRenderer {
|
|||
void renderMonitor(CMonitor* pMonitor);
|
||||
void outputMgrApplyTest(wlr_output_configuration_v1*, bool);
|
||||
void arrangeLayersForMonitor(const int&);
|
||||
void damageSurface(wlr_surface*, double, double);
|
||||
void damageSurface(wlr_surface*, double, double, double scale = 1.0);
|
||||
void damageWindow(CWindow*);
|
||||
void damageBox(wlr_box*);
|
||||
void damageBox(const int& x, const int& y, const int& w, const int& h);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue