microsoft / glTF-SDK
Duplication

Places in code with 6 or more lines that are exactly the same.

Intro
  • For duplication, we look at places in code where there are 6 or more lines of code that are exactly the same.
  • Before duplication is calculated, the code is cleaned to remove empty lines, comments, and frequently duplicated constructs such as imports.
  • You should aim at having as little as possible (<5%) of duplicated code as high-level of duplication can lead to maintenance difficulties, poor factoring, and logical contradictions.
Learn more...
Duplication Overall
  • 10% duplication:
    • 12,065 cleaned lines of cleaned code (without empty lines, comments, and frequently duplicated constructs such as imports)
    • 1,285 duplicated lines
  • 112 duplicates
system10% (1,285 lines)
Duplication per Extension
vcxproj80% (466 lines)
ps18% (359 lines)
yml81% (262 lines)
cpp4% (138 lines)
filters12% (30 lines)
h<1% (16 lines)
psm16% (14 lines)
Duplication per Component (primary)
Build/AzureDevOps81% (262 lines)
XPlatScripts/NuGet.macOS8% (236 lines)
GLTFSDK.Samples/Deserialize66% (231 lines)
GLTFSDK.Samples/Serialize69% (231 lines)
GLTFSDK/Source4% (110 lines)
ROOT24% (84 lines)
GLTFSDK16% (62 lines)
Build/Scripts5% (53 lines)
GLTFSDK/Inc<1% (16 lines)
Build/CMake0% (0 lines)
External/RapidJSON0% (0 lines)
External/googletest0% (0 lines)
GLTFSDK.Shared.CPP0% (0 lines)

Duplication Between Components (50+ lines)

G GLTFSDK.Samples/Deserialize GLTFSDK.Samples/Deserialize GLTFSDK.Samples/Serialize GLTFSDK.Samples/Serialize GLTFSDK.Samples/Deserialize--GLTFSDK.Samples/Serialize 462 GLTFSDK GLTFSDK GLTFSDK.Samples/Deserialize--GLTFSDK 52 GLTFSDK.Samples/Serialize--GLTFSDK 52 Build/Scripts Build/Scripts ROOT ROOT Build/Scripts--ROOT 112

Download: SVG DOT (open online Graphviz editor)

Open 3D force graph...

Show more details on duplication between components...
Longest Duplicates
The list of 20 longest duplicates.
See data for all 112 duplicates...
Size#FoldersFilesLinesCode
173 x 2 GLTFSDK.Samples/Deserialize
GLTFSDK.Samples/Serialize
vcxproj
Deserialize.vcxproj
Serialize.vcxproj
42:259 (84%)
42:259 (84%)
view
44 x 2 Build/AzureDevOps
Build/AzureDevOps
azure-pipelines.yml
azure-pipelines.yml
128:175 (13%)
208:255 (13%)
view
32 x 2 Build/AzureDevOps
Build/AzureDevOps
azure-pipelines.yml
azure-pipelines.yml
12:46 (9%)
70:104 (9%)
view
29 x 2 GLTFSDK.Samples/Deserialize
GLTFSDK.Samples/Serialize
vcxproj
Deserialize.vcxproj
Serialize.vcxproj
1:38 (14%)
1:38 (14%)
view
26 x 2 GLTFSDK.Samples/Deserialize
GLTFSDK
vcxproj
Deserialize.vcxproj
GLTFSDK.vcxproj
3:37 (12%)
3:37 (15%)
view
26 x 2 GLTFSDK.Samples/Serialize
GLTFSDK
vcxproj
Serialize.vcxproj
GLTFSDK.vcxproj
3:37 (12%)
3:37 (15%)
view
25 x 2 GLTFSDK/Source
GLTFSDK/Source
Deserialize.cpp
ExtensionsKHR.cpp
17:63 (5%)
11:57 (9%)
view
20 x 2 Build/AzureDevOps
Build/AzureDevOps
azure-pipelines.yml
azure-pipelines.yml
178:201 (6%)
258:281 (6%)
view
16 x 2 ROOT
ROOT
macbuild.ps1
macbuild.ps1
34:50 (14%)
78:94 (14%)
view
16 x 2 ROOT
ROOT
macbuild.ps1
macbuild.ps1
56:72 (14%)
78:94 (14%)
view
16 x 2 GLTFSDK/Inc/GLTFSDK
GLTFSDK/Source
GLTF.h
Serialize.cpp
410:426 (2%)
17:33 (3%)
view
16 x 2 ROOT
ROOT
macbuild.ps1
macbuild.ps1
34:50 (14%)
56:72 (14%)
view
16 x 2 Build/Scripts
ROOT
winbuild.ps1
macbuild.ps1
35:51 (19%)
56:72 (14%)
view
16 x 2 Build/Scripts
ROOT
winbuild.ps1
macbuild.ps1
35:51 (19%)
78:94 (14%)
view
16 x 2 Build/Scripts
ROOT
winbuild.ps1
macbuild.ps1
35:51 (19%)
34:50 (14%)
view
15 x 2 GLTFSDK.Samples/Deserialize
GLTFSDK.Samples/Serialize
filters
Deserialize.vcxproj.filters
Serialize.vcxproj.filters
1:19 (100%)
1:19 (100%)
view
15 x 2 XPlatScripts/NuGet.macOS
XPlatScripts/NuGet.macOS
Invoke-Tests.ps1
Invoke-Tests.ps1
277:292 (2%)
319:334 (2%)
view
14 x 2 GLTFSDK.Samples/Deserialize/Source
GLTFSDK.Samples/Serialize/Source
main.cpp
main.cpp
262:292 (11%)
252:282 (12%)
view
14 x 2 XPlatScripts/NuGet.macOS
XPlatScripts/NuGet.macOS
GetNuGetCommand.ps1
NuGetHelper.psm1
38:55 (32%)
73:90 (18%)
view
13 x 2 GLTFSDK.Samples/Deserialize
GLTFSDK.Samples/Deserialize
vcxproj
Deserialize.vcxproj
Deserialize.vcxproj
217:230 (6%)
234:247 (6%)
view
Duplicated Units
The list of top 9 duplicated units.
See data for all 9 unit duplicates...
Size#FoldersFilesLinesCode
20 x 2 GLTFSDK/Source
GLTFSDK/Source
Deserialize.cpp
ExtensionsKHR.cpp
19:40 
13:34 
view
11 x 2 GLTFSDK/Inc/GLTFSDK
GLTFSDK/Inc/GLTFSDK
RapidJsonUtils.h
RapidJsonUtils.h
59:71 
74:86 
view
11 x 2 GLTFSDK/Source
GLTFSDK/Source
AnimationUtils.cpp
AnimationUtils.cpp
53:66 
90:103 
view
9 x 2 GLTFSDK.Samples/Deserialize/Source
GLTFSDK.Samples/Serialize/Source
main.cpp
main.cpp
37:57 
39:59 
view
9 x 2 GLTFSDK/Source
GLTFSDK/Source
ExtensionsKHR.cpp
Serialize.cpp
100:109 
130:139 
view
9 x 2 GLTFSDK/Source
GLTFSDK/Source
MeshPrimitiveUtils.cpp
MeshPrimitiveUtils.cpp
134:143 
145:154 
view
8 x 2 GLTFSDK/Inc/GLTFSDK
GLTFSDK/Inc/GLTFSDK
RapidJsonUtils.h
RapidJsonUtils.h
201:209 
232:240 
view
8 x 2 GLTFSDK/Source
GLTFSDK/Source
Deserialize.cpp
ExtensionsKHR.cpp
42:50 
36:44 
view
6 x 2 GLTFSDK/Source
GLTFSDK/Source
Deserialize.cpp
ExtensionsKHR.cpp
58:64 
52:58 
view