Esempio n. 1
0
        public IContext Create(ContextCreationParameters parameters)
        {
            if (parameters == null)
                throw new ArgumentNullException("parameters");
            if (os == PlatformID.Win32NT)
            {
                var loader = LibraryLoader;
                var libGL = loader.Load("OpenGL32");
                var gdi32 = loader.Load("GDI32");

                var wgl = Mapper.Implement<IWGL>(new CompositeLibraryProvider(libGL, gdi32));

                var context = new WindowsContext(wgl, libGL, null, parameters);
                context.Initialize();
                return context;
            }
            throw new PlatformNotSupportedException();
        }
 public ContextCreationException(string message, ContextCreationParameters parameters)
     : base(message)
 {
     CreationParameters = parameters;
 }
 public ContextCreationException(string message, ContextCreationParameters parameters, Exception innerException)
     : base(message, innerException)
 {
     CreationParameters = parameters;
 }
 public VersionNotSupportedException(ContextCreationParameters parameters)
     : this(parameters, null)
 {
 }
 public VersionNotSupportedException(ContextCreationParameters parameters, Exception innerException)
     : base("OpenGL version is not supported.", parameters, innerException)
 {
 }
 public VersionNotSupportedException(string message, ContextCreationParameters parameters) : base(message, parameters)
 {
 }