Beispiel #1
0
 public MeteoraGame(GameCreateInfo createInfo = null)
 {
     if (createInfo == null)
     {
         createInfo = new GameCreateInfo
         {
             Height = 720,
             Width  = 1280,
             View   = new Meteora3DView()
         };
     }
     Window = new MeteoraWindow(createInfo);
 }
Beispiel #2
0
        public MeteoraWindow(GameCreateInfo createInfo)
        {
            var appInfo = new ApplicationInfo
            {
                ApplicationName    = createInfo.AppName,
                ApplicationVersion = Vulkan.Version.Make(0, 0, 1),
                EngineName         = ENGINE_NAME,
                EngineVersion      = ENGINE_VERSION,
                ApiVersion         = Vulkan.Version.Make(1, 0, 0)
            };

            data.appInfo      = appInfo;
            data.createInfo   = createInfo;
            data.view         = createInfo.View;
            _mainLoopComplete = new AutoResetEvent(false);
            windowCreate      = new ManualResetEvent(false);
            gameInit          = new ManualResetEvent(false);
            windowThread      = new Thread(WindowLoop);
            windowThread.Start();
            windowCreate.WaitOne();
        }