Axiom.RenderSystems.DirectX9.D3DTexture.createInternalResources C# (CSharp) Метод

createInternalResources() защищенный метод

protected createInternalResources ( ) : void
Результат void
		protected override void createInternalResources()
		{
			// If SrcWidth and SrcHeight are zero, the requested extents have probably been set
			// through Width and Height. Take those values.
			if ( SrcWidth == 0 || SrcHeight == 0 )
			{
				SrcWidth = Width;
				SrcHeight = Height;
			}

			// Determine D3D pool to use
			// Use managed unless we're a render target or user has asked for a dynamic texture
			if ( ( Usage & TextureUsage.RenderTarget ) != 0 ||
				( Usage & TextureUsage.Dynamic ) != 0 )
			{
				this._d3dPool = D3D.Pool.Default;
			}
			else
			{
				this._d3dPool = D3D.Pool.Managed;
			}

			switch ( this.TextureType )
			{
				case TextureType.OneD:
				case TextureType.TwoD:
					this.CreateNormalTexture();
					break;
				case TextureType.CubeMap:
					this.CreateCubeTexture();
					break;
				case TextureType.ThreeD:
					this.CreateVolumeTexture();
					break;
				default:
					FreeInternalResources();
					throw new Exception( "Unknown texture type!" );
			}
		}