mirror of
https://github.com/yshui/picom.git
synced 2024-11-11 13:51:02 -05:00
Fix compile without opengl
Signed-off-by: Yuxuan Shui <yshuiv7@gmail.com>
This commit is contained in:
parent
7e9d1c6442
commit
4c99ecfde4
1 changed files with 2 additions and 0 deletions
|
@ -229,8 +229,10 @@ void (*const VSYNC_FUNCS_DEINIT[NUM_VSYNC])(session_t *ps) = {
|
||||||
*/
|
*/
|
||||||
bool vsync_init(session_t *ps) {
|
bool vsync_init(session_t *ps) {
|
||||||
// Mesa turns on swap control by default, undo that
|
// Mesa turns on swap control by default, undo that
|
||||||
|
#ifdef CONFIG_OPENGL
|
||||||
if (bkend_use_glx(ps))
|
if (bkend_use_glx(ps))
|
||||||
vsync_opengl_swc_swap_interval(ps, 0);
|
vsync_opengl_swc_swap_interval(ps, 0);
|
||||||
|
#endif
|
||||||
|
|
||||||
if (ps->o.vsync && VSYNC_FUNCS_INIT[ps->o.vsync]
|
if (ps->o.vsync && VSYNC_FUNCS_INIT[ps->o.vsync]
|
||||||
&& !VSYNC_FUNCS_INIT[ps->o.vsync](ps)) {
|
&& !VSYNC_FUNCS_INIT[ps->o.vsync](ps)) {
|
||||||
|
|
Loading…
Reference in a new issue