mirror of
https://github.com/servo/servo.git
synced 2025-07-24 15:50:21 +01:00
Properly support gl_PointSize and gl_PointCoord
Fixes #21719. Fixes #20993. Fixes #20992. Fixes #21007. Fixes #20979.
This commit is contained in:
parent
aa9591137a
commit
8828925f4f
16 changed files with 44 additions and 243 deletions
26
Cargo.lock
generated
26
Cargo.lock
generated
|
@ -318,7 +318,7 @@ dependencies = [
|
||||||
"cssparser 0.24.0 (registry+https://github.com/rust-lang/crates.io-index)",
|
"cssparser 0.24.0 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||||
"euclid 0.19.0 (registry+https://github.com/rust-lang/crates.io-index)",
|
"euclid 0.19.0 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||||
"fnv 1.0.5 (registry+https://github.com/rust-lang/crates.io-index)",
|
"fnv 1.0.5 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||||
"gleam 0.6.2 (registry+https://github.com/rust-lang/crates.io-index)",
|
"gleam 0.6.4 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||||
"ipc-channel 0.11.0 (registry+https://github.com/rust-lang/crates.io-index)",
|
"ipc-channel 0.11.0 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||||
"log 0.4.5 (registry+https://github.com/rust-lang/crates.io-index)",
|
"log 0.4.5 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||||
"num-traits 0.2.4 (registry+https://github.com/rust-lang/crates.io-index)",
|
"num-traits 0.2.4 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||||
|
@ -336,7 +336,7 @@ version = "0.0.1"
|
||||||
dependencies = [
|
dependencies = [
|
||||||
"cssparser 0.24.0 (registry+https://github.com/rust-lang/crates.io-index)",
|
"cssparser 0.24.0 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||||
"euclid 0.19.0 (registry+https://github.com/rust-lang/crates.io-index)",
|
"euclid 0.19.0 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||||
"gleam 0.6.2 (registry+https://github.com/rust-lang/crates.io-index)",
|
"gleam 0.6.4 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||||
"ipc-channel 0.11.0 (registry+https://github.com/rust-lang/crates.io-index)",
|
"ipc-channel 0.11.0 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||||
"lazy_static 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
|
"lazy_static 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||||
"malloc_size_of 0.0.1",
|
"malloc_size_of 0.0.1",
|
||||||
|
@ -385,7 +385,7 @@ name = "cgl"
|
||||||
version = "0.2.3"
|
version = "0.2.3"
|
||||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||||
dependencies = [
|
dependencies = [
|
||||||
"gleam 0.6.2 (registry+https://github.com/rust-lang/crates.io-index)",
|
"gleam 0.6.4 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||||
"libc 0.2.42 (registry+https://github.com/rust-lang/crates.io-index)",
|
"libc 0.2.42 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||||
]
|
]
|
||||||
|
|
||||||
|
@ -495,7 +495,7 @@ dependencies = [
|
||||||
"embedder_traits 0.0.1",
|
"embedder_traits 0.0.1",
|
||||||
"euclid 0.19.0 (registry+https://github.com/rust-lang/crates.io-index)",
|
"euclid 0.19.0 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||||
"gfx_traits 0.0.1",
|
"gfx_traits 0.0.1",
|
||||||
"gleam 0.6.2 (registry+https://github.com/rust-lang/crates.io-index)",
|
"gleam 0.6.4 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||||
"image 0.19.0 (registry+https://github.com/rust-lang/crates.io-index)",
|
"image 0.19.0 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||||
"ipc-channel 0.11.0 (registry+https://github.com/rust-lang/crates.io-index)",
|
"ipc-channel 0.11.0 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||||
"libc 0.2.42 (registry+https://github.com/rust-lang/crates.io-index)",
|
"libc 0.2.42 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||||
|
@ -1201,7 +1201,7 @@ dependencies = [
|
||||||
|
|
||||||
[[package]]
|
[[package]]
|
||||||
name = "gleam"
|
name = "gleam"
|
||||||
version = "0.6.2"
|
version = "0.6.4"
|
||||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||||
dependencies = [
|
dependencies = [
|
||||||
"gl_generator 0.9.0 (registry+https://github.com/rust-lang/crates.io-index)",
|
"gl_generator 0.9.0 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||||
|
@ -1628,7 +1628,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||||
dependencies = [
|
dependencies = [
|
||||||
"cgl 0.2.3 (registry+https://github.com/rust-lang/crates.io-index)",
|
"cgl 0.2.3 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||||
"core-foundation 0.6.2 (registry+https://github.com/rust-lang/crates.io-index)",
|
"core-foundation 0.6.2 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||||
"gleam 0.6.2 (registry+https://github.com/rust-lang/crates.io-index)",
|
"gleam 0.6.4 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||||
"leaky-cow 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)",
|
"leaky-cow 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||||
"libc 0.2.42 (registry+https://github.com/rust-lang/crates.io-index)",
|
"libc 0.2.42 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||||
]
|
]
|
||||||
|
@ -1908,7 +1908,7 @@ dependencies = [
|
||||||
"euclid 0.19.0 (registry+https://github.com/rust-lang/crates.io-index)",
|
"euclid 0.19.0 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||||
"gaol 0.0.1 (git+https://github.com/servo/gaol)",
|
"gaol 0.0.1 (git+https://github.com/servo/gaol)",
|
||||||
"gfx 0.0.1",
|
"gfx 0.0.1",
|
||||||
"gleam 0.6.2 (registry+https://github.com/rust-lang/crates.io-index)",
|
"gleam 0.6.4 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||||
"ipc-channel 0.11.0 (registry+https://github.com/rust-lang/crates.io-index)",
|
"ipc-channel 0.11.0 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||||
"layout_thread 0.0.1",
|
"layout_thread 0.0.1",
|
||||||
"log 0.4.5 (registry+https://github.com/rust-lang/crates.io-index)",
|
"log 0.4.5 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||||
|
@ -2467,7 +2467,7 @@ dependencies = [
|
||||||
"core-foundation 0.6.2 (registry+https://github.com/rust-lang/crates.io-index)",
|
"core-foundation 0.6.2 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||||
"euclid 0.19.0 (registry+https://github.com/rust-lang/crates.io-index)",
|
"euclid 0.19.0 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||||
"gl_generator 0.9.0 (registry+https://github.com/rust-lang/crates.io-index)",
|
"gl_generator 0.9.0 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||||
"gleam 0.6.2 (registry+https://github.com/rust-lang/crates.io-index)",
|
"gleam 0.6.4 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||||
"lazy_static 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
|
"lazy_static 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||||
"libloading 0.5.0 (registry+https://github.com/rust-lang/crates.io-index)",
|
"libloading 0.5.0 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||||
"log 0.4.5 (registry+https://github.com/rust-lang/crates.io-index)",
|
"log 0.4.5 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||||
|
@ -2972,7 +2972,7 @@ dependencies = [
|
||||||
"enum-iterator 0.2.0 (registry+https://github.com/rust-lang/crates.io-index)",
|
"enum-iterator 0.2.0 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||||
"euclid 0.19.0 (registry+https://github.com/rust-lang/crates.io-index)",
|
"euclid 0.19.0 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||||
"fnv 1.0.5 (registry+https://github.com/rust-lang/crates.io-index)",
|
"fnv 1.0.5 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||||
"gleam 0.6.2 (registry+https://github.com/rust-lang/crates.io-index)",
|
"gleam 0.6.4 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||||
"half 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
|
"half 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||||
"html5ever 0.22.3 (registry+https://github.com/rust-lang/crates.io-index)",
|
"html5ever 0.22.3 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||||
"hyper 0.10.13 (registry+https://github.com/rust-lang/crates.io-index)",
|
"hyper 0.10.13 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||||
|
@ -3189,7 +3189,7 @@ dependencies = [
|
||||||
"crossbeam-channel 0.2.5 (registry+https://github.com/rust-lang/crates.io-index)",
|
"crossbeam-channel 0.2.5 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||||
"euclid 0.19.0 (registry+https://github.com/rust-lang/crates.io-index)",
|
"euclid 0.19.0 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||||
"gdi32-sys 0.2.0 (registry+https://github.com/rust-lang/crates.io-index)",
|
"gdi32-sys 0.2.0 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||||
"gleam 0.6.2 (registry+https://github.com/rust-lang/crates.io-index)",
|
"gleam 0.6.4 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||||
"glutin 0.18.0 (registry+https://github.com/rust-lang/crates.io-index)",
|
"glutin 0.18.0 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||||
"lazy_static 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
|
"lazy_static 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||||
"libservo 0.0.1",
|
"libservo 0.0.1",
|
||||||
|
@ -3305,7 +3305,7 @@ dependencies = [
|
||||||
"cmake 0.1.29 (registry+https://github.com/rust-lang/crates.io-index)",
|
"cmake 0.1.29 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||||
"euclid 0.19.0 (registry+https://github.com/rust-lang/crates.io-index)",
|
"euclid 0.19.0 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||||
"expat-sys 2.1.6 (registry+https://github.com/rust-lang/crates.io-index)",
|
"expat-sys 2.1.6 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||||
"gleam 0.6.2 (registry+https://github.com/rust-lang/crates.io-index)",
|
"gleam 0.6.4 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||||
"glutin 0.18.0 (registry+https://github.com/rust-lang/crates.io-index)",
|
"glutin 0.18.0 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||||
"glx 0.2.3 (registry+https://github.com/rust-lang/crates.io-index)",
|
"glx 0.2.3 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||||
"io-surface 0.11.1 (registry+https://github.com/rust-lang/crates.io-index)",
|
"io-surface 0.11.1 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||||
|
@ -4064,7 +4064,7 @@ dependencies = [
|
||||||
"euclid 0.19.0 (registry+https://github.com/rust-lang/crates.io-index)",
|
"euclid 0.19.0 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||||
"freetype 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)",
|
"freetype 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||||
"fxhash 0.2.1 (registry+https://github.com/rust-lang/crates.io-index)",
|
"fxhash 0.2.1 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||||
"gleam 0.6.2 (registry+https://github.com/rust-lang/crates.io-index)",
|
"gleam 0.6.4 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||||
"image 0.19.0 (registry+https://github.com/rust-lang/crates.io-index)",
|
"image 0.19.0 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||||
"lazy_static 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
|
"lazy_static 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||||
"log 0.4.5 (registry+https://github.com/rust-lang/crates.io-index)",
|
"log 0.4.5 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||||
|
@ -4411,7 +4411,7 @@ dependencies = [
|
||||||
"checksum getopts 0.2.17 (registry+https://github.com/rust-lang/crates.io-index)" = "b900c08c1939860ce8b54dc6a89e26e00c04c380fd0e09796799bd7f12861e05"
|
"checksum getopts 0.2.17 (registry+https://github.com/rust-lang/crates.io-index)" = "b900c08c1939860ce8b54dc6a89e26e00c04c380fd0e09796799bd7f12861e05"
|
||||||
"checksum gif 0.10.0 (registry+https://github.com/rust-lang/crates.io-index)" = "ff3414b424657317e708489d2857d9575f4403698428b040b609b9d1c1a84a2c"
|
"checksum gif 0.10.0 (registry+https://github.com/rust-lang/crates.io-index)" = "ff3414b424657317e708489d2857d9575f4403698428b040b609b9d1c1a84a2c"
|
||||||
"checksum gl_generator 0.9.0 (registry+https://github.com/rust-lang/crates.io-index)" = "7a795170cbd85b5a7baa58d6d7525cae6a03e486859860c220f7ebbbdd379d0a"
|
"checksum gl_generator 0.9.0 (registry+https://github.com/rust-lang/crates.io-index)" = "7a795170cbd85b5a7baa58d6d7525cae6a03e486859860c220f7ebbbdd379d0a"
|
||||||
"checksum gleam 0.6.2 (registry+https://github.com/rust-lang/crates.io-index)" = "24ba6539d49223f6bca4f076d9490c001bdbfe07d59cb0ad4079033c75bdc92d"
|
"checksum gleam 0.6.4 (registry+https://github.com/rust-lang/crates.io-index)" = "d6a8901d6854a992b372214fd9cce664df1a29678e362b151de0d7a4efdcd47f"
|
||||||
"checksum glib 0.6.0 (registry+https://github.com/rust-lang/crates.io-index)" = "740f7fda8dde5f5e3944dabdb4a73ac6094a8a7fdf0af377468e98ca93733e61"
|
"checksum glib 0.6.0 (registry+https://github.com/rust-lang/crates.io-index)" = "740f7fda8dde5f5e3944dabdb4a73ac6094a8a7fdf0af377468e98ca93733e61"
|
||||||
"checksum glib-sys 0.7.0 (registry+https://github.com/rust-lang/crates.io-index)" = "3573351e846caed9f11207b275cd67bc07f0c2c94fb628e5d7c92ca056c7882d"
|
"checksum glib-sys 0.7.0 (registry+https://github.com/rust-lang/crates.io-index)" = "3573351e846caed9f11207b275cd67bc07f0c2c94fb628e5d7c92ca056c7882d"
|
||||||
"checksum glob 0.2.11 (registry+https://github.com/rust-lang/crates.io-index)" = "8be18de09a56b60ed0edf84bc9df007e30040691af7acd1c41874faac5895bfb"
|
"checksum glob 0.2.11 (registry+https://github.com/rust-lang/crates.io-index)" = "8be18de09a56b60ed0edf84bc9df007e30040691af7acd1c41874faac5895bfb"
|
||||||
|
|
|
@ -19,7 +19,7 @@ compositing = {path = "../compositing"}
|
||||||
cssparser = "0.24"
|
cssparser = "0.24"
|
||||||
euclid = "0.19"
|
euclid = "0.19"
|
||||||
fnv = "1.0"
|
fnv = "1.0"
|
||||||
gleam = "0.6"
|
gleam = "0.6.4"
|
||||||
ipc-channel = "0.11"
|
ipc-channel = "0.11"
|
||||||
log = "0.4"
|
log = "0.4"
|
||||||
num-traits = "0.2"
|
num-traits = "0.2"
|
||||||
|
|
|
@ -122,6 +122,14 @@ impl<VR: WebVRRenderHandler + 'static> WebGLThread<VR> {
|
||||||
.expect("WebGLContext not found");
|
.expect("WebGLContext not found");
|
||||||
let glsl_version = Self::get_glsl_version(&data.ctx);
|
let glsl_version = Self::get_glsl_version(&data.ctx);
|
||||||
|
|
||||||
|
// FIXME(nox): Should probably be done by offscreen_gl_context.
|
||||||
|
if (glsl_version.major, glsl_version.minor) < (3, 1) {
|
||||||
|
data.ctx.gl().enable(gl::POINT_SPRITE);
|
||||||
|
}
|
||||||
|
if !is_gles() {
|
||||||
|
data.ctx.gl().enable(gl::PROGRAM_POINT_SIZE);
|
||||||
|
}
|
||||||
|
|
||||||
WebGLCreateContextResult {
|
WebGLCreateContextResult {
|
||||||
sender: WebGLMsgSender::new(id, webgl_chan.clone()),
|
sender: WebGLMsgSender::new(id, webgl_chan.clone()),
|
||||||
limits,
|
limits,
|
||||||
|
|
|
@ -605,3 +605,9 @@ parameters! {
|
||||||
}),
|
}),
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
pub fn is_gles() -> bool {
|
||||||
|
// TODO: align this with the actual kind of graphics context in use, rather than
|
||||||
|
// making assumptions based on platform
|
||||||
|
cfg!(any(target_os = "android", target_os = "ios"))
|
||||||
|
}
|
||||||
|
|
|
@ -2,11 +2,11 @@
|
||||||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||||
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
||||||
|
|
||||||
use canvas_traits::webgl::WebGLVersion;
|
use canvas_traits::webgl::{WebGLVersion, is_gles};
|
||||||
use dom::bindings::codegen::Bindings::EXTShaderTextureLodBinding;
|
use dom::bindings::codegen::Bindings::EXTShaderTextureLodBinding;
|
||||||
use dom::bindings::reflector::{DomObject, Reflector, reflect_dom_object};
|
use dom::bindings::reflector::{DomObject, Reflector, reflect_dom_object};
|
||||||
use dom::bindings::root::DomRoot;
|
use dom::bindings::root::DomRoot;
|
||||||
use dom::webglrenderingcontext::{WebGLRenderingContext, is_gles};
|
use dom::webglrenderingcontext::WebGLRenderingContext;
|
||||||
use dom_struct::dom_struct;
|
use dom_struct::dom_struct;
|
||||||
use super::{WebGLExtension, WebGLExtensions, WebGLExtensionSpec};
|
use super::{WebGLExtension, WebGLExtensions, WebGLExtensionSpec};
|
||||||
|
|
||||||
|
|
|
@ -2,11 +2,11 @@
|
||||||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||||
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
||||||
|
|
||||||
use canvas_traits::webgl::WebGLVersion;
|
use canvas_traits::webgl::{WebGLVersion, is_gles};
|
||||||
use dom::bindings::codegen::Bindings::OESElementIndexUintBinding;
|
use dom::bindings::codegen::Bindings::OESElementIndexUintBinding;
|
||||||
use dom::bindings::reflector::{DomObject, Reflector, reflect_dom_object};
|
use dom::bindings::reflector::{DomObject, Reflector, reflect_dom_object};
|
||||||
use dom::bindings::root::DomRoot;
|
use dom::bindings::root::DomRoot;
|
||||||
use dom::webglrenderingcontext::{WebGLRenderingContext, is_gles};
|
use dom::webglrenderingcontext::WebGLRenderingContext;
|
||||||
use dom_struct::dom_struct;
|
use dom_struct::dom_struct;
|
||||||
use super::{WebGLExtension, WebGLExtensions, WebGLExtensionSpec};
|
use super::{WebGLExtension, WebGLExtensions, WebGLExtensionSpec};
|
||||||
|
|
||||||
|
|
|
@ -2,12 +2,12 @@
|
||||||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||||
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
||||||
|
|
||||||
use canvas_traits::webgl::WebGLVersion;
|
use canvas_traits::webgl::{WebGLVersion, is_gles};
|
||||||
use dom::bindings::codegen::Bindings::OESStandardDerivativesBinding;
|
use dom::bindings::codegen::Bindings::OESStandardDerivativesBinding;
|
||||||
use dom::bindings::codegen::Bindings::OESStandardDerivativesBinding::OESStandardDerivativesConstants;
|
use dom::bindings::codegen::Bindings::OESStandardDerivativesBinding::OESStandardDerivativesConstants;
|
||||||
use dom::bindings::reflector::{DomObject, Reflector, reflect_dom_object};
|
use dom::bindings::reflector::{DomObject, Reflector, reflect_dom_object};
|
||||||
use dom::bindings::root::DomRoot;
|
use dom::bindings::root::DomRoot;
|
||||||
use dom::webglrenderingcontext::{WebGLRenderingContext, is_gles};
|
use dom::webglrenderingcontext::WebGLRenderingContext;
|
||||||
use dom_struct::dom_struct;
|
use dom_struct::dom_struct;
|
||||||
use super::{WebGLExtension, WebGLExtensions, WebGLExtensionSpec};
|
use super::{WebGLExtension, WebGLExtensions, WebGLExtensionSpec};
|
||||||
|
|
||||||
|
|
|
@ -3,7 +3,7 @@
|
||||||
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
||||||
|
|
||||||
// https://www.khronos.org/registry/webgl/specs/latest/1.0/webgl.idl
|
// https://www.khronos.org/registry/webgl/specs/latest/1.0/webgl.idl
|
||||||
use canvas_traits::webgl::{webgl_channel, WebGLCommand, WebGLError, WebGLRenderbufferId, WebGLResult};
|
use canvas_traits::webgl::{WebGLCommand, WebGLError, WebGLRenderbufferId, WebGLResult, is_gles, webgl_channel};
|
||||||
use dom::bindings::codegen::Bindings::WebGL2RenderingContextBinding::WebGL2RenderingContextConstants as WebGl2Constants;
|
use dom::bindings::codegen::Bindings::WebGL2RenderingContextBinding::WebGL2RenderingContextConstants as WebGl2Constants;
|
||||||
use dom::bindings::codegen::Bindings::WebGLRenderbufferBinding;
|
use dom::bindings::codegen::Bindings::WebGLRenderbufferBinding;
|
||||||
use dom::bindings::codegen::Bindings::WebGLRenderingContextBinding::WebGLRenderingContextConstants as constants;
|
use dom::bindings::codegen::Bindings::WebGLRenderingContextBinding::WebGLRenderingContextConstants as constants;
|
||||||
|
@ -11,7 +11,7 @@ use dom::bindings::inheritance::Castable;
|
||||||
use dom::bindings::reflector::{DomObject, reflect_dom_object};
|
use dom::bindings::reflector::{DomObject, reflect_dom_object};
|
||||||
use dom::bindings::root::DomRoot;
|
use dom::bindings::root::DomRoot;
|
||||||
use dom::webglobject::WebGLObject;
|
use dom::webglobject::WebGLObject;
|
||||||
use dom::webglrenderingcontext::{WebGLRenderingContext, is_gles};
|
use dom::webglrenderingcontext::WebGLRenderingContext;
|
||||||
use dom_struct::dom_struct;
|
use dom_struct::dom_struct;
|
||||||
use std::cell::Cell;
|
use std::cell::Cell;
|
||||||
|
|
||||||
|
|
|
@ -73,12 +73,6 @@ use std::cmp;
|
||||||
use std::ptr::{self, NonNull};
|
use std::ptr::{self, NonNull};
|
||||||
use webrender_api;
|
use webrender_api;
|
||||||
|
|
||||||
pub fn is_gles() -> bool {
|
|
||||||
// TODO: align this with the actual kind of graphics context in use, rather than
|
|
||||||
// making assumptions based on platform
|
|
||||||
cfg!(any(target_os = "android", target_os = "ios"))
|
|
||||||
}
|
|
||||||
|
|
||||||
// From the GLES 2.0.25 spec, page 85:
|
// From the GLES 2.0.25 spec, page 85:
|
||||||
//
|
//
|
||||||
// "If a texture that is currently bound to one of the targets
|
// "If a texture that is currently bound to one of the targets
|
||||||
|
|
|
@ -15637,9 +15637,7 @@
|
||||||
"conformance/uniforms/out-of-bounds-uniform-array-access.html": [
|
"conformance/uniforms/out-of-bounds-uniform-array-access.html": [
|
||||||
[
|
[
|
||||||
"/_webgl/conformance/uniforms/out-of-bounds-uniform-array-access.html",
|
"/_webgl/conformance/uniforms/out-of-bounds-uniform-array-access.html",
|
||||||
{
|
{}
|
||||||
"timeout": "long"
|
|
||||||
}
|
|
||||||
]
|
]
|
||||||
],
|
],
|
||||||
"conformance/uniforms/uniform-default-values.html": [
|
"conformance/uniforms/uniform-default-values.html": [
|
||||||
|
@ -37324,7 +37322,7 @@
|
||||||
"testharness"
|
"testharness"
|
||||||
],
|
],
|
||||||
"conformance/uniforms/out-of-bounds-uniform-array-access.html": [
|
"conformance/uniforms/out-of-bounds-uniform-array-access.html": [
|
||||||
"a096b5ac7f771ab9b4aa1e5f046de301d22d9c93",
|
"6963b053b79d9e45507f6af10ab50a21240723b0",
|
||||||
"testharness"
|
"testharness"
|
||||||
],
|
],
|
||||||
"conformance/uniforms/uniform-default-values.html": [
|
"conformance/uniforms/uniform-default-values.html": [
|
||||||
|
|
|
@ -1,194 +0,0 @@
|
||||||
[gl-pointcoord.html]
|
|
||||||
bug: https://github.com/servo/servo/issues/21719
|
|
||||||
[WebGL test #48: pixel 48,192 should be 65,125,0\nat (48, 192) expected: 65,125,0 was 0,0,0]
|
|
||||||
expected: FAIL
|
|
||||||
|
|
||||||
[WebGL test #67: pixel 160,208 should be 1,61,0\nat (160, 208) expected: 1,61,0 was 0,0,0]
|
|
||||||
expected: FAIL
|
|
||||||
|
|
||||||
[WebGL test #15: pixel 32,64 should be 1,125,0\nat (32, 64) expected: 1,125,0 was 0,0,0]
|
|
||||||
expected: FAIL
|
|
||||||
|
|
||||||
[WebGL test #45: pixel 64,176 should be 129,189,0\nat (64, 176) expected: 129,189,0 was 0,0,0]
|
|
||||||
expected: FAIL
|
|
||||||
|
|
||||||
[WebGL test #18: pixel 80,64 should be 193,125,0\nat (80, 64) expected: 193,125,0 was 0,0,0]
|
|
||||||
expected: FAIL
|
|
||||||
|
|
||||||
[WebGL test #47: pixel 32,192 should be 1,125,0\nat (32, 192) expected: 1,125,0 was 0,0,0]
|
|
||||||
expected: FAIL
|
|
||||||
|
|
||||||
[WebGL test #42: pixel 80,160 should be 193,253,0\nat (80, 160) expected: 193,253,0 was 0,0,0]
|
|
||||||
expected: FAIL
|
|
||||||
|
|
||||||
[WebGL test #34: pixel 208,64 should be 193,125,0\nat (208, 64) expected: 193,125,0 was 0,0,0]
|
|
||||||
expected: FAIL
|
|
||||||
|
|
||||||
[WebGL test #53: pixel 64,208 should be 129,61,0\nat (64, 208) expected: 129,61,0 was 0,0,0]
|
|
||||||
expected: FAIL
|
|
||||||
|
|
||||||
[WebGL test #29: pixel 192,48 should be 129,189,0\nat (192, 48) expected: 129,189,0 was 0,0,0]
|
|
||||||
expected: FAIL
|
|
||||||
|
|
||||||
[WebGL test #40: pixel 48,160 should be 65,253,0\nat (48, 160) expected: 65,253,0 was 0,0,0]
|
|
||||||
expected: FAIL
|
|
||||||
|
|
||||||
[WebGL test #59: pixel 160,176 should be 1,189,0\nat (160, 176) expected: 1,189,0 was 0,0,0]
|
|
||||||
expected: FAIL
|
|
||||||
|
|
||||||
[WebGL test #26: pixel 208,32 should be 193,253,0\nat (208, 32) expected: 193,253,0 was 0,0,0]
|
|
||||||
expected: FAIL
|
|
||||||
|
|
||||||
[WebGL test #62: pixel 208,176 should be 193,189,0\nat (208, 176) expected: 193,189,0 was 0,0,0]
|
|
||||||
expected: FAIL
|
|
||||||
|
|
||||||
[WebGL test #8: pixel 48,32 should be 65,253,0\nat (48, 32) expected: 65,253,0 was 0,0,0]
|
|
||||||
expected: FAIL
|
|
||||||
|
|
||||||
[WebGL test #31: pixel 160,64 should be 1,125,0\nat (160, 64) expected: 1,125,0 was 0,0,0]
|
|
||||||
expected: FAIL
|
|
||||||
|
|
||||||
[WebGL test #65: pixel 192,192 should be 129,125,0\nat (192, 192) expected: 129,125,0 was 0,0,0]
|
|
||||||
expected: FAIL
|
|
||||||
|
|
||||||
[WebGL test #55: pixel 160,160 should be 1,253,0\nat (160, 160) expected: 1,253,0 was 0,0,0]
|
|
||||||
expected: FAIL
|
|
||||||
|
|
||||||
[WebGL test #10: pixel 80,32 should be 193,253,0\nat (80, 32) expected: 193,253,0 was 0,0,0]
|
|
||||||
expected: FAIL
|
|
||||||
|
|
||||||
[WebGL test #11: pixel 32,48 should be 1,189,0\nat (32, 48) expected: 1,189,0 was 0,0,0]
|
|
||||||
expected: FAIL
|
|
||||||
|
|
||||||
[WebGL test #50: pixel 80,192 should be 193,125,0\nat (80, 192) expected: 193,125,0 was 0,0,0]
|
|
||||||
expected: FAIL
|
|
||||||
|
|
||||||
[WebGL test #51: pixel 32,208 should be 1,61,0\nat (32, 208) expected: 1,61,0 was 0,0,0]
|
|
||||||
expected: FAIL
|
|
||||||
|
|
||||||
[WebGL test #21: pixel 64,80 should be 129,61,0\nat (64, 80) expected: 129,61,0 was 0,0,0]
|
|
||||||
expected: FAIL
|
|
||||||
|
|
||||||
[WebGL test #54: pixel 80,208 should be 193,61,0\nat (80, 208) expected: 193,61,0 was 0,0,0]
|
|
||||||
expected: FAIL
|
|
||||||
|
|
||||||
[WebGL test #33: pixel 192,64 should be 129,125,0\nat (192, 64) expected: 129,125,0 was 0,0,0]
|
|
||||||
expected: FAIL
|
|
||||||
|
|
||||||
[WebGL test #17: pixel 64,64 should be 129,125,0\nat (64, 64) expected: 129,125,0 was 0,0,0]
|
|
||||||
expected: FAIL
|
|
||||||
|
|
||||||
[WebGL test #38: pixel 208,80 should be 193,61,0\nat (208, 80) expected: 193,61,0 was 0,0,0]
|
|
||||||
expected: FAIL
|
|
||||||
|
|
||||||
[WebGL test #49: pixel 64,192 should be 129,125,0\nat (64, 192) expected: 129,125,0 was 0,0,0]
|
|
||||||
expected: FAIL
|
|
||||||
|
|
||||||
[WebGL test #7: pixel 32,32 should be 1,253,0\nat (32, 32) expected: 1,253,0 was 0,0,0]
|
|
||||||
expected: FAIL
|
|
||||||
|
|
||||||
[WebGL test #13: pixel 64,48 should be 129,189,0\nat (64, 48) expected: 129,189,0 was 0,0,0]
|
|
||||||
expected: FAIL
|
|
||||||
|
|
||||||
[WebGL test #46: pixel 80,176 should be 193,189,0\nat (80, 176) expected: 193,189,0 was 0,0,0]
|
|
||||||
expected: FAIL
|
|
||||||
|
|
||||||
[WebGL test #9: pixel 64,32 should be 129,253,0\nat (64, 32) expected: 129,253,0 was 0,0,0]
|
|
||||||
expected: FAIL
|
|
||||||
|
|
||||||
[WebGL test #28: pixel 176,48 should be 65,189,0\nat (176, 48) expected: 65,189,0 was 0,0,0]
|
|
||||||
expected: FAIL
|
|
||||||
|
|
||||||
[WebGL test #25: pixel 192,32 should be 129,253,0\nat (192, 32) expected: 129,253,0 was 0,0,0]
|
|
||||||
expected: FAIL
|
|
||||||
|
|
||||||
[WebGL test #20: pixel 48,80 should be 65,61,0\nat (48, 80) expected: 65,61,0 was 0,0,0]
|
|
||||||
expected: FAIL
|
|
||||||
|
|
||||||
[WebGL test #57: pixel 192,160 should be 129,253,0\nat (192, 160) expected: 129,253,0 was 0,0,0]
|
|
||||||
expected: FAIL
|
|
||||||
|
|
||||||
[WebGL test #30: pixel 208,48 should be 193,189,0\nat (208, 48) expected: 193,189,0 was 0,0,0]
|
|
||||||
expected: FAIL
|
|
||||||
|
|
||||||
[WebGL test #36: pixel 176,80 should be 65,61,0\nat (176, 80) expected: 65,61,0 was 0,0,0]
|
|
||||||
expected: FAIL
|
|
||||||
|
|
||||||
[WebGL test #37: pixel 192,80 should be 129,61,0\nat (192, 80) expected: 129,61,0 was 0,0,0]
|
|
||||||
expected: FAIL
|
|
||||||
|
|
||||||
[WebGL test #52: pixel 48,208 should be 65,61,0\nat (48, 208) expected: 65,61,0 was 0,0,0]
|
|
||||||
expected: FAIL
|
|
||||||
|
|
||||||
[WebGL test #23: pixel 160,32 should be 1,253,0\nat (160, 32) expected: 1,253,0 was 0,0,0]
|
|
||||||
expected: FAIL
|
|
||||||
|
|
||||||
[WebGL test #16: pixel 48,64 should be 65,125,0\nat (48, 64) expected: 65,125,0 was 0,0,0]
|
|
||||||
expected: FAIL
|
|
||||||
|
|
||||||
[WebGL test #32: pixel 176,64 should be 65,125,0\nat (176, 64) expected: 65,125,0 was 0,0,0]
|
|
||||||
expected: FAIL
|
|
||||||
|
|
||||||
[WebGL test #24: pixel 176,32 should be 65,253,0\nat (176, 32) expected: 65,253,0 was 0,0,0]
|
|
||||||
expected: FAIL
|
|
||||||
|
|
||||||
[WebGL test #60: pixel 176,176 should be 65,189,0\nat (176, 176) expected: 65,189,0 was 0,0,0]
|
|
||||||
expected: FAIL
|
|
||||||
|
|
||||||
[WebGL test #43: pixel 32,176 should be 1,189,0\nat (32, 176) expected: 1,189,0 was 0,0,0]
|
|
||||||
expected: FAIL
|
|
||||||
|
|
||||||
[WebGL test #63: pixel 160,192 should be 1,125,0\nat (160, 192) expected: 1,125,0 was 0,0,0]
|
|
||||||
expected: FAIL
|
|
||||||
|
|
||||||
[WebGL test #64: pixel 176,192 should be 65,125,0\nat (176, 192) expected: 65,125,0 was 0,0,0]
|
|
||||||
expected: FAIL
|
|
||||||
|
|
||||||
[WebGL test #44: pixel 48,176 should be 65,189,0\nat (48, 176) expected: 65,189,0 was 0,0,0]
|
|
||||||
expected: FAIL
|
|
||||||
|
|
||||||
[WebGL test #56: pixel 176,160 should be 65,253,0\nat (176, 160) expected: 65,253,0 was 0,0,0]
|
|
||||||
expected: FAIL
|
|
||||||
|
|
||||||
[WebGL test #19: pixel 32,80 should be 1,61,0\nat (32, 80) expected: 1,61,0 was 0,0,0]
|
|
||||||
expected: FAIL
|
|
||||||
|
|
||||||
[WebGL test #35: pixel 160,80 should be 1,61,0\nat (160, 80) expected: 1,61,0 was 0,0,0]
|
|
||||||
expected: FAIL
|
|
||||||
|
|
||||||
[WebGL test #70: pixel 208,208 should be 193,61,0\nat (208, 208) expected: 193,61,0 was 0,0,0]
|
|
||||||
expected: FAIL
|
|
||||||
|
|
||||||
[WebGL test #58: pixel 208,160 should be 193,253,0\nat (208, 160) expected: 193,253,0 was 0,0,0]
|
|
||||||
expected: FAIL
|
|
||||||
|
|
||||||
[WebGL test #68: pixel 176,208 should be 65,61,0\nat (176, 208) expected: 65,61,0 was 0,0,0]
|
|
||||||
expected: FAIL
|
|
||||||
|
|
||||||
[WebGL test #22: pixel 80,80 should be 193,61,0\nat (80, 80) expected: 193,61,0 was 0,0,0]
|
|
||||||
expected: FAIL
|
|
||||||
|
|
||||||
[WebGL test #66: pixel 208,192 should be 193,125,0\nat (208, 192) expected: 193,125,0 was 0,0,0]
|
|
||||||
expected: FAIL
|
|
||||||
|
|
||||||
[WebGL test #69: pixel 192,208 should be 129,61,0\nat (192, 208) expected: 129,61,0 was 0,0,0]
|
|
||||||
expected: FAIL
|
|
||||||
|
|
||||||
[WebGL test #39: pixel 32,160 should be 1,253,0\nat (32, 160) expected: 1,253,0 was 0,0,0]
|
|
||||||
expected: FAIL
|
|
||||||
|
|
||||||
[WebGL test #14: pixel 80,48 should be 193,189,0\nat (80, 48) expected: 193,189,0 was 0,0,0]
|
|
||||||
expected: FAIL
|
|
||||||
|
|
||||||
[WebGL test #12: pixel 48,48 should be 65,189,0\nat (48, 48) expected: 65,189,0 was 0,0,0]
|
|
||||||
expected: FAIL
|
|
||||||
|
|
||||||
[WebGL test #61: pixel 192,176 should be 129,189,0\nat (192, 176) expected: 129,189,0 was 0,0,0]
|
|
||||||
expected: FAIL
|
|
||||||
|
|
||||||
[WebGL test #27: pixel 160,48 should be 1,189,0\nat (160, 48) expected: 1,189,0 was 0,0,0]
|
|
||||||
expected: FAIL
|
|
||||||
|
|
||||||
[WebGL test #41: pixel 64,160 should be 129,253,0\nat (64, 160) expected: 129,253,0 was 0,0,0]
|
|
||||||
expected: FAIL
|
|
||||||
|
|
|
@ -1,4 +1,5 @@
|
||||||
[point-size.html]
|
[point-size.html]
|
||||||
|
bug: https://github.com/servo/servo/issues/21981
|
||||||
[WebGL test #9: should be 255,0,0\nat (0, 0) expected: 255,0,0 was 0,0,0]
|
[WebGL test #9: should be 255,0,0\nat (0, 0) expected: 255,0,0 was 0,0,0]
|
||||||
expected: FAIL
|
expected: FAIL
|
||||||
|
|
||||||
|
|
|
@ -1,4 +0,0 @@
|
||||||
[point-with-gl-pointcoord-in-fragment-shader.html]
|
|
||||||
[WebGL test #0: Center pixel should be green\nat (32, 32) expected: 0,255,0,255 was 0,0,0,255]
|
|
||||||
expected: FAIL
|
|
||||||
|
|
|
@ -0,0 +1,5 @@
|
||||||
|
[out-of-bounds-uniform-array-access.html]
|
||||||
|
expected: TIMEOUT
|
||||||
|
[Overall test]
|
||||||
|
expected: NOTRUN
|
||||||
|
|
|
@ -29,7 +29,6 @@
|
||||||
<html>
|
<html>
|
||||||
<head>
|
<head>
|
||||||
<meta charset="utf-8">
|
<meta charset="utf-8">
|
||||||
<meta name="timeout" content="long">
|
|
||||||
<title>WebGL out of bounds uniform array access.</title>
|
<title>WebGL out of bounds uniform array access.</title>
|
||||||
<link rel="stylesheet" href="../../resources/js-test-style.css"/>
|
<link rel="stylesheet" href="../../resources/js-test-style.css"/>
|
||||||
<script src=/resources/testharness.js></script>
|
<script src=/resources/testharness.js></script>
|
||||||
|
|
|
@ -70,18 +70,6 @@ index 5552a4f82e..539cb33214 100644
|
||||||
<title>WebGL GLSL conformance test: log2_001_to_008.html</title>
|
<title>WebGL GLSL conformance test: log2_001_to_008.html</title>
|
||||||
<link rel="stylesheet" href="../../../../resources/js-test-style.css" />
|
<link rel="stylesheet" href="../../../../resources/js-test-style.css" />
|
||||||
<link rel="stylesheet" href="../../../resources/ogles-tests.css" />
|
<link rel="stylesheet" href="../../../resources/ogles-tests.css" />
|
||||||
diff --git i/conformance/uniforms/out-of-bounds-uniform-array-access.html w/conformance/uniforms/out-of-bounds-uniform-array-access.html
|
|
||||||
index 2758b320ff..4d85c3a53a 100644
|
|
||||||
--- i/conformance/uniforms/out-of-bounds-uniform-array-access.html
|
|
||||||
+++ w/conformance/uniforms/out-of-bounds-uniform-array-access.html
|
|
||||||
@@ -29,6 +29,7 @@
|
|
||||||
<html>
|
|
||||||
<head>
|
|
||||||
<meta charset="utf-8">
|
|
||||||
+<meta name="timeout" content="long">
|
|
||||||
<title>WebGL out of bounds uniform array access.</title>
|
|
||||||
<link rel="stylesheet" href="../../resources/js-test-style.css"/>
|
|
||||||
<script src=/resources/testharness.js></script>
|
|
||||||
diff --git i/conformance/rendering/many-draw-calls.html w/conformance/rendering/many-draw-calls.html
|
diff --git i/conformance/rendering/many-draw-calls.html w/conformance/rendering/many-draw-calls.html
|
||||||
index c1542f4fa9..b3ee786e0b 100644
|
index c1542f4fa9..b3ee786e0b 100644
|
||||||
--- i/conformance/rendering/many-draw-calls.html
|
--- i/conformance/rendering/many-draw-calls.html
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue