Axiom.Core.TextureManager.SetPreferredBitDepths C# (CSharp) Method

SetPreferredBitDepths() public method

public SetPreferredBitDepths ( ushort integerBits, ushort floatBits, bool reloadTextures ) : void
integerBits ushort
floatBits ushort
reloadTextures bool
return void
		public void SetPreferredBitDepths( ushort integerBits, ushort floatBits, bool reloadTextures )
		{
			_preferredFloatBitDepth = floatBits;
			_preferredIntegerBitDepth = integerBits;

			if ( reloadTextures )
			{
				// Iterate throught all textures
				foreach ( Texture texture in Resources )
				{
					// Reload loaded and reloadable texture only
					if ( texture.IsLoaded && texture.IsReloadable )
					{
						texture.Unload();
						texture.SetDesiredBitDepths( integerBits, floatBits );
						texture.Load();
					}
					else
					{
						texture.SetDesiredBitDepths( integerBits, floatBits );
					}
				}
			}
		}