Skip to content

Instantly share code, notes, and snippets.

@MaikKlein
Created June 3, 2013 15:58
Show Gist options
  • Save MaikKlein/5699175 to your computer and use it in GitHub Desktop.
Save MaikKlein/5699175 to your computer and use it in GitHub Desktop.
enum Shader {
VertexShader{shader: BaseShader},
FragmentShader{shader: BaseShader}
}
impl Shader {
fn newVertexShader(source : ~str) -> VertexShader{
VertexShader {shader: BaseShader::new(source)}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment