replace sparkle with glow in components/script (#33911)

* replace sparkle's GlType with canvas_traits's GlType

Signed-off-by: sagudev <16504129+sagudev@users.noreply.github.com>

* remove sparkle from components/servo

Signed-off-by: sagudev <16504129+sagudev@users.noreply.github.com>

* remove sparkle from script

Signed-off-by: sagudev <16504129+sagudev@users.noreply.github.com>

---------

Signed-off-by: sagudev <16504129+sagudev@users.noreply.github.com>
This commit is contained in:
Samson 2024-10-19 12:40:03 +02:00 committed by GitHub
parent a13900c4f8
commit 76bedf28e0
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
5 changed files with 7 additions and 7 deletions

2
Cargo.lock generated
View file

@ -6069,6 +6069,7 @@ dependencies = [
"fonts", "fonts",
"fonts_traits", "fonts_traits",
"fxhash", "fxhash",
"glow 0.15.0",
"headers", "headers",
"html5ever", "html5ever",
"http", "http",
@ -6116,7 +6117,6 @@ dependencies = [
"servo_rand", "servo_rand",
"servo_url", "servo_url",
"smallvec", "smallvec",
"sparkle",
"style", "style",
"style_traits", "style_traits",
"swapper", "swapper",

View file

@ -99,7 +99,7 @@ servo_geometry = { path = "../geometry" }
servo_rand = { path = "../rand" } servo_rand = { path = "../rand" }
servo_url = { path = "../url" } servo_url = { path = "../url" }
smallvec = { workspace = true, features = ["union"] } smallvec = { workspace = true, features = ["union"] }
sparkle = { workspace = true } glow = { workspace = true }
style = { workspace = true } style = { workspace = true }
style_dom = { workspace = true } style_dom = { workspace = true }
style_traits = { workspace = true } style_traits = { workspace = true }

View file

@ -124,7 +124,7 @@ impl VertexArrayObject {
constants::FLOAT => 4, constants::FLOAT => 4,
constants::INT | constants::UNSIGNED_INT if is_webgl2 => 4, constants::INT | constants::UNSIGNED_INT if is_webgl2 => 4,
constants2::HALF_FLOAT if is_webgl2 => 2, constants2::HALF_FLOAT if is_webgl2 => 2,
sparkle::gl::FIXED if is_webgl2 => 4, glow::FIXED if is_webgl2 => 4,
constants2::INT_2_10_10_10_REV | constants2::UNSIGNED_INT_2_10_10_10_REV constants2::INT_2_10_10_10_REV | constants2::UNSIGNED_INT_2_10_10_10_REV
if is_webgl2 && size == 4 => if is_webgl2 && size == 4 =>
{ {

View file

@ -10,7 +10,7 @@ use canvas_traits::webgl::{GlType, TexFormat, WebGLSLVersion, WebGLVersion};
use fnv::{FnvHashMap, FnvHashSet}; use fnv::{FnvHashMap, FnvHashSet};
use js::jsapi::JSObject; use js::jsapi::JSObject;
use malloc_size_of::MallocSizeOf; use malloc_size_of::MallocSizeOf;
use sparkle::gl::{self, GLenum}; type GLenum = u32;
use super::wrapper::{TypedWebGLExtensionWrapper, WebGLExtensionWrapper}; use super::wrapper::{TypedWebGLExtensionWrapper, WebGLExtensionWrapper};
use super::{ext, WebGLExtension, WebGLExtensionSpec}; use super::{ext, WebGLExtension, WebGLExtensionSpec};
@ -461,7 +461,7 @@ impl WebGLExtensions {
if type_ == OESTextureHalfFloatConstants::HALF_FLOAT_OES && if type_ == OESTextureHalfFloatConstants::HALF_FLOAT_OES &&
!self.supports_gl_extension("GL_OES_texture_half_float") !self.supports_gl_extension("GL_OES_texture_half_float")
{ {
return gl::HALF_FLOAT; return glow::HALF_FLOAT;
} }
type_ type_
} }

View file

@ -139,9 +139,9 @@ impl XRWebGLLayer {
fn texture_target(&self) -> u32 { fn texture_target(&self) -> u32 {
if cfg!(target_os = "macos") { if cfg!(target_os = "macos") {
sparkle::gl::TEXTURE_RECTANGLE glow::TEXTURE_RECTANGLE
} else { } else {
sparkle::gl::TEXTURE_2D glow::TEXTURE_2D
} }
} }