Skip to content

Commit

Permalink
Don't unload render dlls to prevent typeids invalidation.
Browse files Browse the repository at this point in the history
  • Loading branch information
nitrocaster committed Nov 25, 2015
1 parent 1f34b32 commit fe7bc5f
Showing 1 changed file with 0 additions and 3 deletions.
3 changes: 0 additions & 3 deletions src/xrEngine/EngineAPI.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -219,7 +219,6 @@ void CEngineAPI::CreateRendererList()
SupportsAdvancedRendering* test_rendering = (SupportsAdvancedRendering*)GetProcAddress(hRender, "SupportsAdvancedRendering");
R_ASSERT(test_rendering);
bSupports_r2_5 = test_rendering();
FreeLibrary(hRender);
}

// try to initialize R3
Expand All @@ -234,7 +233,6 @@ void CEngineAPI::CreateRendererList()
SupportsDX10Rendering* test_dx10_rendering = (SupportsDX10Rendering*)GetProcAddress(hRender, "SupportsDX10Rendering");
R_ASSERT(test_dx10_rendering);
bSupports_r3 = test_dx10_rendering();
FreeLibrary(hRender);
}

// try to initialize R4
Expand All @@ -249,7 +247,6 @@ void CEngineAPI::CreateRendererList()
SupportsDX11Rendering* test_dx11_rendering = (SupportsDX11Rendering*)GetProcAddress(hRender, "SupportsDX11Rendering");
R_ASSERT(test_dx11_rendering);
bSupports_r4 = test_dx11_rendering();
FreeLibrary(hRender);
}
}

Expand Down

1 comment on commit fe7bc5f

@revolucas
Copy link
Contributor

@revolucas revolucas commented on fe7bc5f Sep 8, 2016

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Strangely, when using this specific commit to EngineAPI.cpp the loading times are considerably longer (After a fresh application startup). I can confirm by using -perfhud_hack to skip this step. With -perfhud_hack or with FreeLibrary restored the loading times are back to normal (After a fresh application startup).

Please sign in to comment.