getMipLevels( texture, width, height ) {

		let mipLevelCount;

		if ( texture.isCompressedTexture ) {

			if ( texture.mipmaps ) {

				mipLevelCount = texture.mipmaps.length;

			} else {

				mipLevelCount = 1;

			}

		} else {

			mipLevelCount = Math.floor( Math.log2( Math.max( width, height ) ) ) + 1;

		}

		return mipLevelCount;

	}
Computes the number of mipmap levels for the given texture.

@param {Texture} texture - The texture.
@param {number} width - The texture's width.
@param {number} height - The texture's height.
@return {number} The number of mipmap levels.