Example #1
0
 /// <summary>
 /// 调用XNA资源加载函数(禁止重载)
 /// </summary>
 protected sealed override void LoadContent()
 {
     GraphicsDevice.Clear(Color.Black);
     if (process != null)
     {
         process.Load(GraphicsDevice);
         process.Begin();
         isScale = process.IsScale();
     }
     if (useXNAListener)
     {
         xna_listener.LoadContent(this);
     }
     XNA_LoadContent();
 }
Example #2
0
 public override void CreateApp(GL gl, int width, int height)
 {
     if (LSystem.screenRect != null)
     {
         LSystem.screenRect.SetBounds(0, 0, width, height);
     }
     else
     {
         LSystem.screenRect = new RectBox(0, 0, width, height);
     }
     if (m_process == null)
     {
         m_process = new LProcess(this, width, height);
     }
     m_process.Load(gl);
     LSystem.screenProcess = m_process;
 }
Example #3
0
 /// <summary>
 /// 调用XNA资源加载函数(禁止重载)
 /// </summary>
 public void OnNavigatedTo(NavigationEventArgs e)
 {
     try
     {
         SharedGraphicsDeviceManager.Current.GraphicsDevice.SetSharingMode(true);
         SharedGraphicsDeviceManager.Current.GraphicsDevice.Clear(Color.Black);
     }
     catch
     {
     }
     if (process != null)
     {
         process.Load(SharedGraphicsDeviceManager.Current.GraphicsDevice);
         process.Begin();
         isScale = process.IsScale();
     }
     if (useXNAListener)
     {
         sl_listener.LoadContent(GamePage);
     }
     XNA_LoadContent();
     TargetElapsedTime.Start();
 }