Exemplo n.º 1
0
        // CActivity 実装

        public override void OnManagedリソースの作成()
        {
            if (!base.b活性化してない)
            {
                try                                     // #xxxxx 2012.12.31 yyagi: to prepare flush, first of all, I create q queue to the GPU.
                {
                    IDirect3DQuery9 = new SlimDX.Direct3D9.Query(CDTXMania.app.Device.UnderlyingDevice, QueryType.Occlusion);
                }
                catch (Exception e)
                {
                    Trace.TraceError(e.Message);
                }
                base.OnManagedリソースの作成();
            }
        }
Exemplo n.º 2
0
        // CActivity 実装

        public override void OnManagedリソースの作成()
        {
            if (!base.b活性化してない)
            {
                try                                     // #xxxxx 2012.12.31 yyagi: to prepare flush, first of all, I create q queue to the GPU.
                {
                    IDirect3DQuery9 = new SlimDX.Direct3D9.Query(TJAPlayer3.app.Device.UnderlyingDevice, QueryType.Occlusion);
                }
                catch (Exception e)
                {
                    Trace.TraceError(e.ToString());
                    Trace.TraceError("例外が発生しましたが処理を継続します。 (e5c7cd0b-f7bb-4bf1-9ad9-db27b43ff63d)");
                }
                base.OnManagedリソースの作成();
            }
        }
Exemplo n.º 3
0
		/// <summary>
		///		Default constructor.
		/// </summary>
		/// <param name="device">Reference to a Direct3D device.</param>
		public D3DHardwareOcclusionQuery( D3D.Device device )
		{
			this.device = device;

			isQueryResultStillOutstanding = true;

			// check if queries are supported
			isSupported = Root.Instance.RenderSystem.Capabilities.HasCapability( Capabilities.HardwareOcculusion );

			if ( isSupported )
			{
				// attempt to create an occlusion query
				query = new D3D.Query( device, D3D.QueryType.Occlusion );
			}
		}