Skip to main content

ShaderResource

Type Alias ShaderResource 

Source
pub type ShaderResource = Resource<Shader>;
Expand description

Type alias for shader resources.

Aliased Type§

pub struct ShaderResource { /* private fields */ }

Trait Implementations§

Source§

impl ShaderResourceExtension for ShaderResource

Source§

fn from_str( id: Uuid, str: &str, kind: ResourceKind, ) -> Result<Self, ShaderError>

Creates new shader from given string. Input string must have the format defined in examples for ShaderResource.
Source§

fn standard() -> Self

Returns an instance of standard shader.
Source§

fn standard_2d() -> Self

Returns an instance of standard 2D shader.
Source§

fn standard_particle_system() -> Self

Returns an instance of standard particle system shader.
Source§

fn standard_sprite() -> Self

Returns an instance of standard sprite shader.
Source§

fn standard_terrain() -> Self

Returns an instance of standard terrain shader.
Source§

fn standard_tile() -> Self

Returns an instance of standard tile shader.
Source§

fn standard_twosides() -> Self

Returns an instance of standard two-sides terrain shader.
Source§

fn standard_widget() -> Self

Returns an instance of standard widget shader.
Source§

fn standard_shaders() -> [&'static BuiltInResource<Shader>; 8]

Returns a list of standard shader.