亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關于我們
? 蟲蟲下載站

?? dxmut.cs

?? VC中使用C#作為腳本引擎編程
?? CS
?? 第 1 頁 / 共 5 頁
字號:
            }

            // Change to a Direct3D device created from the new device settings
            // If there is an existing device, either reset or recreate
            ChangeDevice(settings, null, false);
        }


        /// <summary>
        /// Creates a Direct3D device.  If CreateWindow or SetWindow has not already
        /// been called, it will call CreateWindow with default parameters.
        /// Instead of calling this, you can call SetDevice or CreateDeviceFromSettings
        /// This is the CLS compliant version
        /// </summary>
        public void CreateDevice(int adapterOridinal, bool windowed, int suggestedWidth,
            int suggestedHeight, IDeviceCreation callback)
        {
            CreateDevice((uint)adapterOridinal, windowed, suggestedWidth,
            suggestedHeight, callback);
        }


        /// <summary>
        /// Passes a previously created Direct3D device for use by the framework.  
        /// If CreateWindow() has not already been called, it will call it with the 
        /// default parameters.  Instead of calling this, you can call CreateDevice() or 
        /// CreateDeviceFromSettings() 
        /// </summary>
        public void SetDevice(Device device)
        {
            if (device == null)
                throw new ArgumentNullException("device", "You cannot pass in a null device to SetDevice");

            if (State.IsInsideDeviceCallback)
                throw new InvalidOperationException("You cannot set a device from inside a callback.");

            // Was the window created? If not, create it now
            if (!State.WasWindowCreated)
            {
                // If CreateWindow or SetWindow was already called and failed, then fail again.
                if (State.WasWindowCreateCalled)
                {
                    throw new InvalidOperationException("CreateWindow was already called and failed.");
                }

                // Create a default window
                CreateWindow("Direct3D Window", null, null, -1, -1);
            }

            DeviceSettings deviceSettings = new DeviceSettings();

            // Get the present parameters from the swap chain
            using(Surface backBuffer = device.GetBackBuffer(0, 0, BackBufferType.Mono))
            {
                using (SwapChain swap = backBuffer.GetContainer(InterfaceGuid.SwapChain) as SwapChain)
                {
                    deviceSettings.presentParams = swap.PresentParameters;
                    System.Diagnostics.Debug.Assert(deviceSettings.presentParams != null, "You must have valid present parameters here.");
                }
            }

            DeviceCreationParameters creationParams = device.CreationParameters;

            // Fill out the device settings structure now
            deviceSettings.AdapterOrdinal = (uint)creationParams.AdapterOrdinal;    
            deviceSettings.DeviceType = creationParams.DeviceType;
            deviceSettings.AdapterFormat = FindAdapterFormat(deviceSettings.AdapterOrdinal,
                deviceSettings.DeviceType, deviceSettings.presentParams.BackBufferFormat,
                deviceSettings.presentParams.Windowed);
            deviceSettings.BehaviorFlags = creationParams.Behavior.Value;

            // Change to the Direct3D device passed in
            ChangeDevice(deviceSettings, device, false);
        }

        /// <summary>
        /// Tells the framework to change to a device created from the passed in device settings
        /// If CreateWindow() has not already been called, it will call it with the 
        /// default parameters.  Instead of calling this, you can call CreateDevice() 
        /// or SetDevice() 
        /// </summary>
        public void CreateDeviceFromSettings(DeviceSettings deviceSettings, bool preserveInput)
        {
            // Set the state since this was called
            State.WasDeviceCreateCalled = true;

            // Was the window created? If not, create it now
            if (!State.WasWindowCreated)
            {
                // If CreateWindow or SetWindow was already called and failed, then fail again.
                if (State.WasWindowCreateCalled)
                {
                    throw new InvalidOperationException("CreateWindow was already called and failed.");
                }

                // Create a default window
                CreateWindow("Direct3D Window", null, null, -1, -1);
            }

            if (!preserveInput)
            {
                // If not preserving the input, the find the closest valid to it
                MatchOptions match = new MatchOptions();
                match.AdapterOrdinal = MatchType.ClosestToInput;
                match.DeviceType = MatchType.ClosestToInput;
                match.Windowed = MatchType.ClosestToInput;
                match.AdapterFormat = MatchType.ClosestToInput;
                match.VertexProcessing = MatchType.ClosestToInput;
                match.Resolution = MatchType.ClosestToInput;
                match.BackBufferFormat = MatchType.ClosestToInput;
                match.BackBufferCount = MatchType.ClosestToInput;
                match.MultiSample = MatchType.ClosestToInput;
                match.SwapEffect = MatchType.ClosestToInput;
                match.DepthFormat = MatchType.ClosestToInput;
                match.StencilFormat = MatchType.ClosestToInput;
                match.PresentFlags = MatchType.ClosestToInput;
                match.RefreshRate = MatchType.ClosestToInput;
                match.PresentInterval = MatchType.ClosestToInput;

                try
                {
                    deviceSettings = FindValidDeviceSettings(deviceSettings, match);
                }
                catch(Exception e)
                {
                    // Display any error message
                    DisplayErrorMessage(e);
                    throw;
                }
                // Change to a Direct3D device created from the new device settings.  
                // If there is an existing device, then either reset or recreate the scene
                ChangeDevice(deviceSettings, null, false);
            }
        }
        /// <summary>
        /// Tells the framework to change to a device created from the passed in device settings
        /// If CreateWindow() has not already been called, it will call it with the 
        /// default parameters.  Instead of calling this, you can call CreateDevice() 
        /// or SetDevice() 
        /// </summary>
        public void CreateDeviceFromSettings(DeviceSettings deviceSettings) { CreateDeviceFromSettings(deviceSettings, false); }

        /// <summary>
        /// Toggle between full screen and windowed
        /// </summary>
        public void ToggleFullscreen()
        {
            // Pause the application
            Pause(true, true);

            // Get the current device settings and flip the windowed state then
            // find the closest valid device settings with this change
            DeviceSettings currentSettings = State.CurrentDeviceSettings.Clone();
            currentSettings.presentParams.Windowed = !currentSettings.presentParams.Windowed;

            MatchOptions match = new MatchOptions();
            match.AdapterOrdinal = MatchType.PreserveInput;
            match.DeviceType = MatchType.ClosestToInput;
            match.Windowed = MatchType.PreserveInput;
            match.AdapterFormat = MatchType.IgnoreInput;
            match.VertexProcessing = MatchType.ClosestToInput;
            match.BackBufferFormat = MatchType.IgnoreInput;
            match.BackBufferCount = MatchType.ClosestToInput;
            match.MultiSample = MatchType.ClosestToInput;
            match.SwapEffect = MatchType.ClosestToInput;
            match.DepthFormat = MatchType.ClosestToInput;
            match.StencilFormat = MatchType.ClosestToInput;
            match.PresentFlags = MatchType.ClosestToInput;
            match.RefreshRate = MatchType.IgnoreInput;
            match.PresentInterval = MatchType.IgnoreInput;

            System.Drawing.Rectangle windowClient;
            if (currentSettings.presentParams.Windowed)
                windowClient = State.ClientRectangle;
            else
                windowClient = State.FullScreenClientRectangle;

            if (windowClient.Width > 0 && windowClient.Height > 0)
            {
                match.Resolution = MatchType.ClosestToInput;
                currentSettings.presentParams.BackBufferWidth = windowClient.Width;
                currentSettings.presentParams.BackBufferHeight = windowClient.Height;
            }
            else
            {
                match.Resolution = MatchType.IgnoreInput;
            }

            try
            {
                if ( (!currentSettings.presentParams.Windowed) && (State.IsMaximized))
                {
                    if (WindowForm != null)
                    {
                        WindowForm.WindowState = System.Windows.Forms.FormWindowState.Normal;
                    }
                    toggleMaximized = true;
                }
                currentSettings = FindValidDeviceSettings(currentSettings, match);
                ChangeDevice(currentSettings, null, false);
                Window.Size = State.WindowBoundsRectangle.Size;                
                Window.Location = State.WindowBoundsRectangle.Location;                
                if (currentSettings.presentParams.Windowed)
                {
                    if (toggleMaximized)
                    {
                        if (WindowForm != null)
                        {
                            WindowForm.WindowState = System.Windows.Forms.FormWindowState.Maximized;
                        }
                    }
                    toggleMaximized = false;
                }
            }
            finally
            {
                // Well, unpause no matter what
                Pause(false, false);
                State.CurrentDeviceSettings = currentSettings;
            }
        }

        
        /// <summary>
        /// Toggle between Hardware and Reference
        /// </summary>
        public void ToggleReference()
        {
            // Get the current device settings 
            DeviceSettings currentSettings = State.CurrentDeviceSettings.Clone();
            if (currentSettings.DeviceType == DeviceType.Hardware)
                currentSettings.DeviceType = DeviceType.Reference;
            else if (currentSettings.DeviceType == DeviceType.Reference)
                currentSettings.DeviceType = DeviceType.Hardware;

            MatchOptions match = new MatchOptions();
            match.AdapterOrdinal = MatchType.PreserveInput;
            match.DeviceType = MatchType.PreserveInput;
            match.Windowed = MatchType.ClosestToInput;
            match.AdapterFormat = MatchType.ClosestToInput;
            match.VertexProcessing = MatchType.ClosestToInput;
            match.Resolution = MatchType.ClosestToInput;
            match.BackBufferFormat = MatchType.ClosestToInput;
            match.BackBufferCount = MatchType.ClosestToInput;
            match.MultiSample = MatchType.ClosestToInput;
            match.SwapEffect = MatchType.ClosestToInput;
            match.DepthFormat = MatchType.ClosestToInput;
            match.StencilFormat = MatchType.ClosestToInput;
            match.PresentFlags = MatchType.ClosestToInput;
            match.RefreshRate = MatchType.ClosestToInput;
            match.PresentInterval = MatchType.ClosestToInput;

            try
            {
                currentSettings = FindValidDeviceSettings(currentSettings, match);
                ChangeDevice(currentSettings, null, false);
            }
#if(DEBUG)
            catch (Exception e)
            {
                // In debug mode show this error (maybe - depending on settings)
                DisplayErrorMessage(e);
#else
            catch
            {
                // In release mode fail silently
#endif
            }
            finally
            {
                // Update the current settings
                State.CurrentDeviceSettings = currentSettings;
            }
        }

        /// <summary>
        /// This function tries to find valid device settings based upon the input device settings 
        /// struct and the match options.  For each device setting a match option in the 

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
日韩一区二区三| 1000部国产精品成人观看| www.66久久| 久久99久久久欧美国产| 亚洲综合色成人| 国产精品污网站| 精品第一国产综合精品aⅴ| 欧美视频在线播放| 99视频精品全部免费在线| 激情六月婷婷综合| 毛片基地黄久久久久久天堂| 一区二区三区欧美久久| 亚洲少妇30p| 国产精品网站一区| 久久精品一二三| 日韩美女天天操| 日韩一区二区三区在线观看| 欧美天天综合网| 欧美综合色免费| 色94色欧美sute亚洲线路一久| 成人国产一区二区三区精品| 国产精品系列在线观看| 久久精品国产精品亚洲综合| 日韩影视精彩在线| 午夜视黄欧洲亚洲| 亚洲大型综合色站| 亚洲成精国产精品女| 亚洲国产精品尤物yw在线观看| 亚洲精品乱码久久久久久| 日韩伦理免费电影| 亚洲精品成人天堂一二三| 亚洲精品精品亚洲| 艳妇臀荡乳欲伦亚洲一区| 亚洲啪啪综合av一区二区三区| 亚洲天堂精品视频| 亚洲天堂福利av| 亚洲影院理伦片| 视频一区视频二区中文| 视频一区二区不卡| 免费一级欧美片在线观看| 日韩精品一级二级| 精品亚洲成a人| 国产一区二区0| 粉嫩av一区二区三区粉嫩| av网站免费线看精品| 91蜜桃婷婷狠狠久久综合9色| 91美女视频网站| 在线看一区二区| 9191国产精品| 精品国产一区二区亚洲人成毛片| 2024国产精品视频| 国产精品美女一区二区| 亚洲精品视频在线看| 天堂在线亚洲视频| 国产在线视频一区二区三区| 丁香婷婷综合五月| 色国产精品一区在线观看| 69av一区二区三区| 精品国产亚洲在线| 国产精品理伦片| 亚洲午夜视频在线观看| 青娱乐精品在线视频| 国产精品18久久久久久久久久久久 | 久久久不卡影院| 国产精品毛片久久久久久久| 亚洲国产一区二区三区青草影视| 美洲天堂一区二卡三卡四卡视频 | 欧洲在线/亚洲| 欧美一区二区三级| 欧美激情艳妇裸体舞| 亚洲国产欧美另类丝袜| 国产精品一区免费视频| 在线亚洲精品福利网址导航| 日韩精品在线网站| 亚洲精品高清在线观看| 精品一区二区国语对白| 91啪亚洲精品| 精品国产一区二区亚洲人成毛片| 日韩美女视频19| 精品无人区卡一卡二卡三乱码免费卡| 成人午夜激情视频| 欧美男女性生活在线直播观看| 国产日韩欧美不卡| 午夜精品一区二区三区电影天堂| 国产精品一区二区久激情瑜伽 | 在线观看免费成人| 337p粉嫩大胆色噜噜噜噜亚洲| 亚洲欧美日本韩国| 国产一区二区调教| 欧美日本韩国一区二区三区视频 | 日韩一区二区三区免费看| 国产精品国产三级国产aⅴ无密码 国产精品国产三级国产aⅴ原创 | 国产在线精品一区在线观看麻豆| 91小视频免费观看| 久久久久久亚洲综合影院红桃 | 亚洲靠逼com| 国产成人在线色| 91精品婷婷国产综合久久 | 亚洲图片欧美激情| 激情深爱一区二区| 欧美高清激情brazzers| 日韩一区中文字幕| 国产精品一区在线观看乱码 | 成人午夜在线播放| 精品日韩99亚洲| 天天综合天天综合色| 91久久久免费一区二区| 欧美激情一区二区三区不卡| 韩国成人精品a∨在线观看| 欧美日韩一本到| 亚洲精品亚洲人成人网| 成人av在线网| 国产女人18水真多18精品一级做 | 国产在线视视频有精品| 91精品国产欧美一区二区成人| 亚洲精品免费看| 99久久综合国产精品| 国产欧美日韩卡一| 国产一区视频在线看| 日韩欧美高清dvd碟片| 天堂精品中文字幕在线| 91精彩视频在线| 亚洲码国产岛国毛片在线| 成人白浆超碰人人人人| 国产精品午夜免费| aa级大片欧美| 亚洲女爱视频在线| 色哟哟国产精品免费观看| 亚洲少妇30p| 一本一本久久a久久精品综合麻豆| 一区二区中文字幕在线| av高清不卡在线| 亚洲欧美区自拍先锋| 日本大香伊一区二区三区| 亚洲一线二线三线视频| 欧美顶级少妇做爰| 全国精品久久少妇| 欧美精品一区二区三区久久久 | 日韩精品成人一区二区三区| 欧美乱妇20p| 麻豆传媒一区二区三区| 欧美va亚洲va| 国模一区二区三区白浆| 国产肉丝袜一区二区| 丁香五精品蜜臀久久久久99网站 | 黑人巨大精品欧美一区| 久久久一区二区三区| 成人av在线看| 亚洲福利一区二区| 欧美一区二区三区视频免费| 久久精品国产**网站演员| 久久久99精品免费观看不卡| 成人av午夜影院| 一区二区三区在线看| 91精品久久久久久久91蜜桃| 九九久久精品视频| 亚洲欧美在线另类| 欧美高清视频一二三区 | 欧美在线观看一区二区| 日韩主播视频在线| 国产亚洲制服色| 色琪琪一区二区三区亚洲区| 日韩av电影免费观看高清完整版| 久久久久久一二三区| 色呦呦国产精品| 蜜桃视频一区二区三区在线观看| 久久久久99精品一区| 91网站在线播放| 日av在线不卡| 亚洲婷婷综合色高清在线| 91精品在线一区二区| 成人av在线一区二区三区| 亚洲成人免费电影| 国产情人综合久久777777| 精品视频在线视频| 丁香五精品蜜臀久久久久99网站| 亚洲国产成人91porn| 国产午夜精品在线观看| 在线观看91精品国产入口| 国产伦精品一区二区三区在线观看| 亚洲视频在线观看三级| 日韩一区二区影院| 色美美综合视频| 国产精品中文字幕日韩精品 | 亚洲美女免费在线| 久久久亚洲欧洲日产国码αv| 欧美日韩在线观看一区二区 | 久久精品夜夜夜夜久久| 欧美三级中文字幕| kk眼镜猥琐国模调教系列一区二区| 丝袜美腿亚洲一区| 一区二区三区中文字幕在线观看| 久久久五月婷婷| 欧美一级搡bbbb搡bbbb| 96av麻豆蜜桃一区二区| 国产永久精品大片wwwapp| 日韩国产欧美在线观看| 夜夜嗨av一区二区三区四季av| 欧美国产日本视频| 欧美大片一区二区|