Beispiel #1
0
        public static void Initialize()
        {
            lock (s_initializationLock)
            {
                if (s_instance != null)
                {
                    throw new VxException("VxContext has already been initialized.");
                }

                WindowCreateInfo      wci     = new WindowCreateInfo(50, 50, 1280, 720, WindowState.Normal, Assembly.GetEntryAssembly().GetName().Name);
                GraphicsDeviceOptions options = new GraphicsDeviceOptions(false, PixelFormat.R16_UNorm, true, ResourceBindingModel.Improved, true, true);
                VeldridStartup.CreateWindowAndGraphicsDevice(wci, options, out Sdl2Window window, out GraphicsDevice gd);
                s_instance = new VxContext(gd, window);
            }
        }
Beispiel #2
0
Datei: Vx.cs Projekt: mellinoe/Vx
 public static void Terminate() => VxContext.Terminate();
Beispiel #3
0
Datei: Vx.cs Projekt: mellinoe/Vx
 public static void Initialize() => VxContext.Initialize();