mirror of
https://github.com/servo/servo.git
synced 2025-08-04 13:10:20 +01:00
Properly allow FUNC_SUBTRACT and FUNC_REVERSE_SUBTRACT in blendEquation
This commit is contained in:
parent
ae286a518d
commit
15272d2c3b
1 changed files with 7 additions and 4 deletions
|
@ -1477,11 +1477,14 @@ impl WebGLRenderingContextMethods for WebGLRenderingContext {
|
||||||
|
|
||||||
// https://www.khronos.org/registry/webgl/specs/latest/1.0/#5.14.3
|
// https://www.khronos.org/registry/webgl/specs/latest/1.0/#5.14.3
|
||||||
fn BlendEquation(&self, mode: u32) {
|
fn BlendEquation(&self, mode: u32) {
|
||||||
if mode != constants::FUNC_ADD {
|
match mode {
|
||||||
return self.webgl_error(InvalidEnum);
|
constants::FUNC_ADD |
|
||||||
|
constants::FUNC_SUBTRACT |
|
||||||
|
constants::FUNC_REVERSE_SUBTRACT => {
|
||||||
|
self.send_command(WebGLCommand::BlendEquation(mode))
|
||||||
|
},
|
||||||
|
_ => self.webgl_error(InvalidEnum)
|
||||||
}
|
}
|
||||||
|
|
||||||
self.send_command(WebGLCommand::BlendEquation(mode));
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// https://www.khronos.org/registry/webgl/specs/latest/1.0/#5.14.3
|
// https://www.khronos.org/registry/webgl/specs/latest/1.0/#5.14.3
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue