Stl Color

Mar 21, 2013 at 12:09 PM

Thankx for your library !!! So great.

I add a Property Color on StLReader and FileModelVisual3D to set the color of the stl imported File.

and do this on the code : this.Materials.Add(MaterialHelper.CreateMaterial(Brush));
where Brush is my property

Do you think you could add this feature on a next release ?


Apr 15, 2013 at 11:24 AM
Edited Apr 15, 2013 at 11:25 AM
I added a DefaultMaterial property, which should be more general than a color. I hope this is ok!
Apr 15, 2013 at 12:08 PM


It will be include in the next release or is it in the source code now?

Thanks so much.
Apr 15, 2013 at 12:10 PM

i just see your commit of today!!

May 23, 2013 at 10:25 AM
Hi thanks

It's ok fot stl reader but you not include the defaultMatertial Property to FileModelVisual3D

so we can't do this :
            <ht:FileModelVisual3D x:Name="Vehicle"  DefaultMaterial="{ht:Material Blue}" />

Could you add it in a next release please ?


Jun 7, 2013 at 10:39 AM
done! I also added DefaultMaterial properties to the .off, .obj and .lwo loaders.
Jun 7, 2013 at 10:57 AM

Really Thanks
Jun 7, 2013 at 11:06 AM
I added SourceChanged on DependencyProperty DefaultMaterial for works with datatemplate3D
    /// <summary>
    /// The default material property.
    /// </summary>
    public static readonly DependencyProperty DefaultMaterialProperty =
            "DefaultMaterial", typeof(Material), typeof(FileModelVisual3D), new PropertyMetadata(null, SourceChanged));