diff --git a/src/backend/graphics/glium.rs b/src/backend/graphics/glium.rs index a3629de..dacfb51 100644 --- a/src/backend/graphics/glium.rs +++ b/src/backend/graphics/glium.rs @@ -3,7 +3,7 @@ use backend::graphics::egl::{EGLGraphicsBackend, SwapBuffersError}; use glium::Frame; use glium::SwapBuffersError as GliumSwapBuffersError; -use glium::backend::{Backend, Context}; +use glium::backend::{Backend, Context, Facade}; use glium::debug::DebugCallbackBehavior; use std::ops::Deref; use std::os::raw::c_void; @@ -63,6 +63,12 @@ impl Deref for GliumGraphicsBackend { } } +impl Facade for GliumGraphicsBackend { + fn get_context(&self) -> &Rc { + &self.context + } +} + /// Converter trait to expose `glium` compatibility for all `EGLGraphicsBackend`s pub trait IntoGlium: EGLGraphicsBackend + Sized { /// Wrap the given `EGLGraphicsBackend` to a `GliumGraphicBackend`