randomPoison / gunship-rs

An experimental game engine written in Rust.
MIT License
27 stars 3 forks source link

Allow materials to specify default values for properties #79

Open randomPoison opened 7 years ago

randomPoison commented 7 years ago

Currently material properties default to the default value for their type. While this is sometimes fine, there are cases where the default value doesn't work or their is a more reasonable default value for the property. For these cases it would be better if an alternate default value could be specified in the shader, e.g.:

property surface_color: Color = (1.0, 0.0, 0.0, 1.0);
poperty shininess: f32 = 4.0;