< Summary

Line coverage
100%
Covered lines: 44
Uncovered lines: 0
Coverable lines: 44
Total lines: 130
Line coverage: 100%
Branch coverage
N/A
Covered branches: 0
Total branches: 0
Branch coverage: N/A
Method coverage

Feature is only available for sponsors

Upgrade to PRO version

Metrics

MethodBranch coverage Crap Score Cyclomatic complexity Line coverage
.ctor()100%11100%
.ctor(...)100%11100%
get_Name()100%11100%
get_AmbientColor()100%11100%
get_DiffuseColor()100%11100%
get_EmissiveColor()100%11100%
get_SpecularColor()100%11100%
get_TransmissionColor()100%11100%
get_IlluminationModel()100%11100%
get_DissolveFactor()100%11100%
get_IsHaloDissolve()100%11100%
get_SpecularExponent()100%11100%
get_Sharpness()100%11100%
get_OpticalDensity()100%11100%
get_IsAntiAliasingEnabled()100%11100%
get_AmbientMap()100%11100%
get_DiffuseMap()100%11100%
get_EmissiveMap()100%11100%
get_SpecularMap()100%11100%
get_SpecularExponentMap()100%11100%
get_DissolveMap()100%11100%
get_DecalMap()100%11100%
get_DispMap()100%11100%
get_BumpMap()100%11100%
get_ReflectionMap()100%11100%
get_Roughness()100%11100%
get_RoughnessMap()100%11100%
get_Metallic()100%11100%
get_MetallicMap()100%11100%
get_Sheen()100%11100%
get_SheenMap()100%11100%
get_ClearCoatThickness()100%11100%
get_ClearCoatRoughness()100%11100%
get_Anisotropy()100%11100%
get_AnisotropyRotation()100%11100%
get_Norm()100%11100%

File(s)

https://raw.githubusercontent.com/JeremyAnsel/JeremyAnsel.Media.WavefrontObj/636b700b450d7d3262bf9218a7cc67966be4ced8/JeremyAnsel.Media.WavefrontObj/JeremyAnsel.Media.WavefrontObj/ObjMaterial.cs

#LineLine coverage
 1// <copyright file="ObjMaterial.cs" company="Jérémy Ansel">
 2// Copyright (c) 2017, 2019 Jérémy Ansel
 3// </copyright>
 4// <license>
 5// Licensed under the MIT license. See LICENSE.txt
 6// </license>
 7
 8namespace JeremyAnsel.Media.WavefrontObj
 9{
 10    [System.Diagnostics.DebuggerDisplay("Material:{Name}")]
 11    public class ObjMaterial
 12    {
 140813        public ObjMaterial()
 14        {
 140815            this.ReflectionMap = new ObjMaterialReflectionMap();
 16
 140817            this.IlluminationModel = 2;
 140818            this.DissolveFactor = 1.0f;
 140819            this.Sharpness = 60;
 140820            this.OpticalDensity = 1.0f;
 140821        }
 22
 23        public ObjMaterial(string? name)
 30024            : this()
 25        {
 30026            this.Name = name;
 30027        }
 28
 236429        public string? Name { get; set; }
 30
 57231        public ObjMaterialColor? AmbientColor { get; set; }
 32
 50833        public ObjMaterialColor? DiffuseColor { get; set; }
 34
 50835        public ObjMaterialColor? EmissiveColor { get; set; }
 36
 50837        public ObjMaterialColor? SpecularColor { get; set; }
 38
 50839        public ObjMaterialColor? TransmissionColor { get; set; }
 40
 172441        public int IlluminationModel { get; set; }
 42
 173643        public float DissolveFactor { get; set; }
 44
 31645        public bool IsHaloDissolve { get; set; }
 46
 31247        public float SpecularExponent { get; set; }
 48
 172449        public int Sharpness { get; set; }
 50
 172451        public float OpticalDensity { get; set; }
 52
 32453        public bool IsAntiAliasingEnabled { get; set; }
 54
 108455        public ObjMaterialMap? AmbientMap { get; set; }
 56
 36857        public ObjMaterialMap? DiffuseMap { get; set; }
 58
 36859        public ObjMaterialMap? EmissiveMap { get; set; }
 60
 36861        public ObjMaterialMap? SpecularMap { get; set; }
 62
 36863        public ObjMaterialMap? SpecularExponentMap { get; set; }
 64
 36865        public ObjMaterialMap? DissolveMap { get; set; }
 66
 34467        public ObjMaterialMap? DecalMap { get; set; }
 68
 34469        public ObjMaterialMap? DispMap { get; set; }
 70
 32071        public ObjMaterialMap? BumpMap { get; set; }
 72
 381673        public ObjMaterialReflectionMap ReflectionMap { get; private set; }
 74
 75        /// <summary>
 76        ///     PBR Extension: Pr
 77        /// </summary>
 31678        public float Roughness { get; set; }
 79
 80        /// <summary>
 81        ///     PBR Extension: map_Pr
 82        /// </summary>
 36883        public ObjMaterialMap? RoughnessMap { get; set; }
 84
 85        /// <summary>
 86        ///     PBR Extension: Pm
 87        /// </summary>
 31688        public float Metallic { get; set; }
 89
 90        /// <summary>
 91        ///     PBR Extension: map_Pm
 92        /// </summary>
 36893        public ObjMaterialMap? MetallicMap { get; set; }
 94
 95        /// <summary>
 96        ///     PBR Extension: Ps
 97        /// </summary>
 31698        public float Sheen { get; set; }
 99
 100        /// <summary>
 101        ///     PBR Extension: map_Ps
 102        /// </summary>
 368103        public ObjMaterialMap? SheenMap { get; set; }
 104
 105        /// <summary>
 106        ///     PBR Extension: Pc
 107        /// </summary>
 316108        public float ClearCoatThickness { get; set; }
 109
 110        /// <summary>
 111        ///     PBR Extension: Pcr
 112        /// </summary>
 316113        public float ClearCoatRoughness { get; set; }
 114
 115        /// <summary>
 116        ///     PBR Extension: aniso
 117        /// </summary>
 316118        public float Anisotropy { get; set; }
 119
 120        /// <summary>
 121        ///     PBR Extension: anisor
 122        /// </summary>
 316123        public float AnisotropyRotation { get; set; }
 124
 125        /// <summary>
 126        ///     PBR Extension: norm
 127        /// </summary>
 368128        public ObjMaterialMap? Norm { get; set; }
 129    }
 130}