コード例 #1
0
        /// <summary>
        ///
        /// </summary>
        internal void Present()
        {
            lock (deviceContext) {
                if (requestScreenShotPath != null)
                {
                    var path = requestScreenShotPath;
                    requestScreenShotPath = null;

                    BackbufferColor.SaveToFile(path);
                }

                display.SwapBuffers(Game.Parameters.VSyncInterval);

                display.Update();
            }
        }
コード例 #2
0
ファイル: GraphicsDevice.cs プロジェクト: ttou73/IronStar
        /// <summary>
        ///
        /// </summary>
        internal void Present(int syncInterval)
        {
            syncInterval = MathUtil.Clamp(syncInterval, 0, 3);

            lock (deviceContext) {
                if (requestScreenShotPath != null)
                {
                    var path = requestScreenShotPath;
                    requestScreenShotPath = null;

                    BackbufferColor.SaveToFile(path);
                    //Log.Message("screenshot saved: {0}", path );
                }

                display.SwapBuffers(syncInterval);
            }
        }