libservo: Handle GL video decoding setup internally (#31209)

Instead of making the client set up GL video decoding, have this done
inside libservo. The details necessary for decoding are fetched via
Surfman now. This also removes the setup for the context on Android --
which has no GStreamer support now anyway. In the future, this could be
enabled, but should likely be done using Surfman, instead of passing on
all these details manually.
This commit is contained in:
Martin Robinson 2024-02-03 15:38:48 +01:00 committed by GitHub
parent b2fe66f7e4
commit d7d0451424
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
7 changed files with 125 additions and 156 deletions

View file

@ -15,7 +15,6 @@ use libc::c_void;
use msg::constellation_msg::{PipelineId, TopLevelBrowsingContextId, TraversalDirection};
use script_traits::{MediaSessionActionType, MouseButton, TouchEventType, TouchId, WheelDelta};
use servo_geometry::DeviceIndependentPixel;
use servo_media::player::context::{GlApi, GlContext, NativeDisplay};
use servo_url::ServoUrl;
use style_traits::DevicePixel;
use webrender_api::units::{DeviceIntPoint, DeviceIntRect, DeviceIntSize, DevicePoint};
@ -171,13 +170,7 @@ pub trait WindowMethods {
/// will want to avoid blocking on UI events, and just
/// run the event loop at the vsync interval.
fn set_animation_state(&self, _state: AnimationState);
/// Get the media GL context
fn get_gl_context(&self) -> GlContext;
/// Get the media native display
fn get_native_display(&self) -> NativeDisplay;
/// Get the GL api
fn get_gl_api(&self) -> GlApi;
/// Get the RenderingContext instance.
/// Get the [`RenderingContext`] of this Window.
fn rendering_context(&self) -> RenderingContext;
}