Axiom.RenderSystems.OpenGLES.GLESRenderSystem.SetTextureLayerAnisotropy C# (CSharp) Method

SetTextureLayerAnisotropy() public method

public SetTextureLayerAnisotropy ( int unit, int maxAnisotropy ) : void
unit int
maxAnisotropy int
return void
		public override void SetTextureLayerAnisotropy( int unit, int maxAnisotropy )
		{
			if ( !_rsCapabilities.HasCapability( Capabilities.AnisotropicFiltering ) )
				return;

			if ( !ActivateGLTextureUnit( unit ) )
				return;

			float largest_supported_anisotropy = 0;
			GL.GetFloat( All.MaxTextureMaxAnisotropyExt, ref largest_supported_anisotropy );
			if ( maxAnisotropy > largest_supported_anisotropy )
				maxAnisotropy = largest_supported_anisotropy != 0 ? (int)largest_supported_anisotropy : 1;
			if ( GetCurrentAnisotropy( unit ) != maxAnisotropy )
				GL.TexParameter( All.Texture2D, All.TextureMaxAnisotropyExt, maxAnisotropy );

			ActivateGLTextureUnit( 0 );
		}
GLESRenderSystem