microsoft / glTF-SDK
Conditional Complexity

The distribution of complexity of units (measured with McCabe index).

Intro
  • Conditional complexity (also called cyclomatic complexity) is a term used to measure the complexity of software. The term refers to the number of possible paths through a program function. A higher value ofter means higher maintenance and testing costs (infosecinstitute.com).
  • Conditional complexity is calculated by counting all conditions in the program that can affect the execution path (e.g. if statement, loops, switches, and/or operators, try and catch blocks...).
  • Conditional complexity is measured at the unit level (methods, functions...).
  • Units are classified in four categories based on the measured McCabe index: 1-5 (simple units), 6-10 (medium complex units), 11-25 (complex units), 26+ (very complex units).
Learn more...
Conditional Complexity Overall
  • There are 476 units with 5,576 lines of code in units (35.6% of code).
    • 0 very complex units (0 lines of code)
    • 0 complex units (0 lines of code)
    • 4 medium complex units (258 lines of code)
    • 36 simple units (1,193 lines of code)
    • 436 very simple units (4,125 lines of code)
0% | 0% | 4% | 21% | 73%
Legend:
51+
26-50
11-25
6-10
1-5
Alternative Visuals
Conditional Complexity per Extension
51+
26-50
11-25
6-10
1-5
cpp0% | 0% | 6% | 22% | 70%
h0% | 0% | 0% | 19% | 80%
Conditional Complexity per Logical Component
primary logical decomposition
51+
26-50
11-25
6-10
1-5
GLTFSDK/Source0% | 0% | 7% | 18% | 74%
GLTFSDK/Inc0% | 0% | 0% | 19% | 80%
GLTFSDK.Samples/Deserialize0% | 0% | 0% | 68% | 31%
GLTFSDK.Samples/Serialize0% | 0% | 0% | 58% | 41%
Most Complex Units
Top 20 most complex units
Unit# linesMcCabe index# params
void BufferBuilder::AddAccessors()
in GLTFSDK/Source/BufferBuilder.cpp
64 16 6
rapidjson::Value SerializeMaterial()
in GLTFSDK/Source/Serialize.cpp
80 16 4
void ValidateVertexCount()
in GLTFSDK/Source/Validation.cpp
45 14 3
Material ParseMaterial()
in GLTFSDK/Source/Deserialize.cpp
69 12 2
void GLBResourceReader::Init()
in GLTFSDK/Source/GLBResourceReader.cpp
53 10 0
rapidjson::Value SerializeNode()
in GLTFSDK/Source/Serialize.cpp
49 10 4
std::vector ReadBinaryData()
in GLTFSDK/Inc/GLTFSDK/GLTFResourceReader.h
37 9 2
std::vector MeshPrimitiveUtils::GetColors()
in GLTFSDK/Source/MeshPrimitiveUtils.cpp
27 9 3
rapidjson::Value SerializeAccessor()
in GLTFSDK/Source/Serialize.cpp
59 9 4
void PrintResourceInfo()
in GLTFSDK.Samples/Deserialize/Source/main.cpp
45 8 2
static std::string GetAccessorTypeName()
in GLTFSDK/Inc/GLTFSDK/GLTF.h
22 8 1
static uint8_t GetTypeCount()
in GLTFSDK/Inc/GLTFSDK/GLTF.h
21 8 1
void ReadSparseBinaryData()
in GLTFSDK/Inc/GLTFSDK/GLTFResourceReader.h
42 8 3
inline void Base64Decode()
in GLTFSDK/Inc/GLTFSDK/ResourceReaderUtils.h
39 8 3
Camera ParseCamera()
in GLTFSDK/Source/Deserialize.cpp
54 8 2
44 8 2
std::string AccessorTypeToString()
in GLTFSDK/Source/Serialize.cpp
22 8 1
void SerializePropertyExtensions()
in GLTFSDK/Source/Serialize.cpp
35 8 5
static ComponentType GetComponentType()
in GLTFSDK/Inc/GLTFSDK/GLTF.h
20 7 1
static std::string GetComponentTypeName()
in GLTFSDK/Inc/GLTFSDK/GLTF.h
20 7 1