Ejemplo n.º 1
0
    def select(self, spec, api, version, profile, extensions, config, sink=LoggingSink(__name__)):
        if extensions is not None:
            extensions = set(extensions)

            if config['ALIAS']:
                extensions.update(find_extensions_with_aliases(spec, api, version, profile, extensions))

        return JinjaGenerator.select(self, spec, api, version, profile, extensions, config, sink=sink)
Ejemplo n.º 2
0
    def select(self, spec, api, version, profile, extensions, config, sink=LoggingSink(__name__)):
        if extensions is not None:
            extensions = set(extensions)

            if api == 'wgl':
                # See issue #40: https://github.com/Dav1dde/glad/issues/40
                # > Currently if you generate a loader without these extensions
                # > (WGL_ARB_extensions_string and WGL_EXT_extensions_string) it won't compile.
                # Adds these 2 extensions if they are missing.
                extensions.update(('WGL_ARB_extensions_string', 'WGL_EXT_extensions_string'))

            if config['ALIAS']:
                extensions.update(find_extensions_with_aliases(spec, api, version, profile, extensions))

        return JinjaGenerator.select(self, spec, api, version, profile, extensions, config, sink=sink)