[mutter/gbsneto/kill-vblank: 60/62] clutter: Remove ability to externally set sync-to-vblank
- From: Georges Basile Stavracas Neto <gbsneto src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [mutter/gbsneto/kill-vblank: 60/62] clutter: Remove ability to externally set sync-to-vblank
- Date: Tue, 4 Sep 2018 17:24:59 +0000 (UTC)
commit 50905d417d2103deabc1781b467016c125c710c8
Author: Georges Basile Stavracas Neto <georges stavracas gmail com>
Date: Wed Aug 8 14:05:31 2018 -0300
clutter: Remove ability to externally set sync-to-vblank
Externally setting the sync-to-vblank setting was a feature
added as a workaround to old Intel and ATI graphic cards, and
is not needed anymore. Furthermore, it doesn't make sense to
change it on a compositor whatsoever.
This commit removes all the ways to externally change this
setting, as well as the now unused API.
https://gitlab.gnome.org/GNOME/mutter/merge_requests/191
clutter/clutter/clutter-main.c | 20 --------------------
clutter/clutter/clutter-mutter.h | 3 ---
clutter/clutter/x11/clutter-stage-x11.c | 3 +--
src/backends/native/meta-renderer-native.c | 3 +--
4 files changed, 2 insertions(+), 27 deletions(-)
---
diff --git a/clutter/clutter/clutter-main.c b/clutter/clutter/clutter-main.c
index 46537f322..61742aca2 100644
--- a/clutter/clutter/clutter-main.c
+++ b/clutter/clutter/clutter-main.c
@@ -261,16 +261,6 @@ clutter_config_read_from_key_file (GKeyFile *keyfile)
else
clutter_enable_accessibility = bool_value;
- bool_value =
- g_key_file_get_boolean (keyfile, ENVIRONMENT_GROUP,
- "SyncToVblank",
- &key_error);
-
- if (key_error != NULL)
- g_clear_error (&key_error);
- else
- clutter_sync_to_vblank = bool_value;
-
int_value =
g_key_file_get_integer (keyfile, ENVIRONMENT_GROUP,
"DefaultFps",
@@ -1494,10 +1484,6 @@ pre_parse_hook (GOptionContext *context,
if (env_string)
clutter_use_fuzzy_picking = TRUE;
- env_string = g_getenv ("CLUTTER_VBLANK");
- if (g_strcmp0 (env_string, "none") == 0)
- clutter_sync_to_vblank = FALSE;
-
return _clutter_backend_pre_parse (backend, error);
}
@@ -3666,12 +3652,6 @@ _clutter_set_sync_to_vblank (gboolean sync_to_vblank)
clutter_sync_to_vblank = !!sync_to_vblank;
}
-gboolean
-_clutter_get_sync_to_vblank (void)
-{
- return clutter_sync_to_vblank;
-}
-
void
_clutter_debug_messagev (const char *format,
va_list var_args)
diff --git a/clutter/clutter/clutter-mutter.h b/clutter/clutter/clutter-mutter.h
index 034e5d0f2..69282c638 100644
--- a/clutter/clutter/clutter-mutter.h
+++ b/clutter/clutter/clutter-mutter.h
@@ -34,9 +34,6 @@
CLUTTER_AVAILABLE_IN_MUTTER
void clutter_set_custom_backend_func (ClutterBackend *(* func) (void));
-CLUTTER_AVAILABLE_IN_MUTTER
-gboolean _clutter_get_sync_to_vblank (void);
-
CLUTTER_AVAILABLE_IN_MUTTER
int64_t clutter_stage_get_frame_counter (ClutterStage *stage);
diff --git a/clutter/clutter/x11/clutter-stage-x11.c b/clutter/clutter/x11/clutter-stage-x11.c
index 1ee2f40ab..ee7857cb6 100644
--- a/clutter/clutter/x11/clutter-stage-x11.c
+++ b/clutter/clutter/x11/clutter-stage-x11.c
@@ -631,8 +631,7 @@ clutter_stage_x11_realize (ClutterStageWindow *stage_window)
stage_x11->onscreen = cogl_onscreen_new (backend->cogl_context, width, height);
- cogl_onscreen_set_swap_throttled (stage_x11->onscreen,
- _clutter_get_sync_to_vblank ());
+ cogl_onscreen_set_swap_throttled (stage_x11->onscreen, TRUE);
stage_x11->frame_closure =
cogl_onscreen_add_frame_callback (stage_x11->onscreen,
frame_cb,
diff --git a/src/backends/native/meta-renderer-native.c b/src/backends/native/meta-renderer-native.c
index 08b9befbb..d90c419cb 100644
--- a/src/backends/native/meta-renderer-native.c
+++ b/src/backends/native/meta-renderer-native.c
@@ -2594,8 +2594,7 @@ meta_renderer_native_create_onscreen (MetaRendererNative *renderer_native,
}
onscreen = cogl_onscreen_new (context, width, height);
- cogl_onscreen_set_swap_throttled (onscreen,
- _clutter_get_sync_to_vblank ());
+ cogl_onscreen_set_swap_throttled (onscreen, TRUE);
if (!cogl_framebuffer_allocate (COGL_FRAMEBUFFER (onscreen), error))
{
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]