Struct gfx_backend_gl::Version [−][src]
pub struct Version { pub major: u32, pub minor: u32, pub is_embedded: bool, pub revision: Option<u32>, pub vendor_info: String, }
Expand description
A version number for a specific component of an OpenGL implementation
Fields
major: u32
minor: u32
is_embedded: bool
revision: Option<u32>
vendor_info: String
Implementations
Create a new OpenGL version number
Create a new OpenGL ES version number
According to the OpenGL specification, the version information is expected to follow the following syntax:
<major> ::= <number>
<minor> ::= <number>
<revision> ::= <number>
<vendor-info> ::= <string>
<release> ::= <major> "." <minor> ["." <release>]
<version> ::= <release> [" " <vendor-info>]
Note that this function is intentionally lenient in regards to parsing,
and will try to recover at least the first two version numbers without
resulting in an Err
.
Notes
WebGL 2
version returned as OpenGL ES 3.0
Trait Implementations
This method returns an ordering between self
and other
values if one exists. Read more
This method tests less than (for self
and other
) and is used by the <
operator. Read more
This method tests less than or equal to (for self
and other
) and is used by the <=
operator. Read more
This method tests greater than (for self
and other
) and is used by the >
operator. Read more
Auto Trait Implementations
impl RefUnwindSafe for Version
impl UnwindSafe for Version
Blanket Implementations
Mutably borrows from an owned value. Read more
Compare self to key
and return true
if they are equal.