pub enum WebGlProgramError {
ShaderCompile(String),
ProgramLink(String),
}Expand description
Errors that can occur while building a WebGL shader program.
Each variant carries the browser-provided info log so the caller can surface the exact GLSL diagnostic without losing fidelity.
Variants§
ShaderCompile(String)
Vertex or fragment shader compilation failed.
Carries the shader info log returned by getShaderInfoLog.
ProgramLink(String)
Program linking failed (or createProgram returned None).
Carries the program info log returned by getProgramInfoLog.
Trait Implementations§
Source§impl Clone for WebGlProgramError
impl Clone for WebGlProgramError
Source§impl Debug for WebGlProgramError
impl Debug for WebGlProgramError
Source§impl Display for WebGlProgramError
Implements the formatted message for WebGlProgramError.
impl Display for WebGlProgramError
Implements the formatted message for WebGlProgramError.
Source§fn fmt(&self, formatter: &mut Formatter<'_>) -> Result
fn fmt(&self, formatter: &mut Formatter<'_>) -> Result
Formats the WebGlProgramError via the supplied formatter.
The browser’s own info log is appended verbatim, because a GLSL diagnostic is only actionable in the driver’s own wording.
§Arguments
&mut Formatter<'_>- The formatter receiving the formatted output.
§Returns
fmt::Result- Result of the formatting operation.
Source§impl Error for WebGlProgramError
impl Error for WebGlProgramError
1.30.0 · Source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
Returns the lower-level source of this error, if any. Read more
1.0.0 · Source§fn description(&self) -> &str
fn description(&self) -> &str
👎Deprecated since 1.42.0:
use the Display impl or to_string()
Auto Trait Implementations§
impl Freeze for WebGlProgramError
impl RefUnwindSafe for WebGlProgramError
impl Send for WebGlProgramError
impl Sync for WebGlProgramError
impl Unpin for WebGlProgramError
impl UnsafeUnpin for WebGlProgramError
impl UnwindSafe for WebGlProgramError
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more