mirror of
https://github.com/brl/mutter.git
synced 2024-11-23 00:20:42 -05:00
kms/connector: Track underscan in KmsConnectorState
Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/3552>
This commit is contained in:
parent
0dc43c04ee
commit
e9e613a6c3
@ -181,18 +181,6 @@ meta_kms_connector_get_current_state (MetaKmsConnector *connector)
|
||||
return connector->current_state;
|
||||
}
|
||||
|
||||
gboolean
|
||||
meta_kms_connector_is_underscanning_supported (MetaKmsConnector *connector)
|
||||
{
|
||||
uint32_t underscan_prop_id;
|
||||
|
||||
underscan_prop_id =
|
||||
meta_kms_connector_get_prop_id (connector,
|
||||
META_KMS_CONNECTOR_PROP_UNDERSCAN);
|
||||
|
||||
return underscan_prop_id != 0;
|
||||
}
|
||||
|
||||
gboolean
|
||||
meta_kms_connector_is_privacy_screen_supported (MetaKmsConnector *connector)
|
||||
{
|
||||
@ -480,6 +468,10 @@ state_set_properties (MetaKmsConnectorState *state,
|
||||
state->broadcast_rgb.supported =
|
||||
supported_drm_broadcast_rgb_to_output_rgb_range (prop->supported_variants);
|
||||
}
|
||||
|
||||
prop = &props[META_KMS_CONNECTOR_PROP_UNDERSCAN];
|
||||
if (prop->prop_id)
|
||||
state->underscan.supported = TRUE;
|
||||
}
|
||||
|
||||
static CoglSubpixelOrder
|
||||
|
@ -74,6 +74,10 @@ typedef struct _MetaKmsConnectorState
|
||||
MetaOutputRGBRange value;
|
||||
uint64_t supported;
|
||||
} broadcast_rgb;
|
||||
|
||||
struct {
|
||||
gboolean supported;
|
||||
} underscan;
|
||||
} MetaKmsConnectorState;
|
||||
|
||||
META_EXPORT_TEST
|
||||
@ -94,8 +98,6 @@ MetaKmsMode * meta_kms_connector_get_preferred_mode (MetaKmsConnector *connector
|
||||
META_EXPORT_TEST
|
||||
const MetaKmsConnectorState * meta_kms_connector_get_current_state (MetaKmsConnector *connector);
|
||||
|
||||
gboolean meta_kms_connector_is_underscanning_supported (MetaKmsConnector *connector);
|
||||
|
||||
gboolean meta_kms_connector_is_privacy_screen_supported (MetaKmsConnector *connector);
|
||||
|
||||
const MetaKmsRange * meta_kms_connector_get_max_bpc (MetaKmsConnector *connector);
|
||||
|
@ -365,8 +365,7 @@ meta_output_kms_new (MetaGpuKms *gpu_kms,
|
||||
output_info->suggested_x = connector_state->suggested_x;
|
||||
output_info->suggested_y = connector_state->suggested_y;
|
||||
output_info->hotplug_mode_update = connector_state->hotplug_mode_update;
|
||||
output_info->supports_underscanning =
|
||||
meta_kms_connector_is_underscanning_supported (kms_connector);
|
||||
output_info->supports_underscanning = connector_state->underscan.supported;
|
||||
|
||||
max_bpc_range = meta_kms_connector_get_max_bpc (kms_connector);
|
||||
if (max_bpc_range)
|
||||
|
Loading…
Reference in New Issue
Block a user