void plugin_factory_collection::load_module(const filesystem::path& Path, const load_proxy_t LoadProxies) { // K-3D modules now have the same extension on all platforms ... if(filesystem::extension(Path).lowercase().raw() != ".module") return; // If the module can be proxied for fast startup, do that and return ... if(LoadProxies == LOAD_PROXIES) { filesystem::path proxy_path = Path + ".proxy"; if(filesystem::exists(proxy_path) && m_implementation->proxy_module(Path, proxy_path)) return; } // OK, just load the module ... m_implementation->m_message_signal.emit(string_cast(boost::format(_("Loading plugin module %1%")) % Path.native_utf8_string().raw())); register_plugins_entry_point register_plugins = 0; os_load_module(Path, register_plugins); if(!register_plugins) return; // It's a K-3D module, all-right - give it a chance to register its plugins detail::plugin_registry registry(m_implementation->m_message_signal, m_implementation->m_factories); register_plugins(registry); }
bool OGL4Loader::load_module() { m_hLib = os_load_module("opengl32.dll"); if(m_hLib == nullptr) { return false; } void* pp = _load("glGetStringi"); return true; }