Partager via


BaseTexture.AutoGenerateFilterType Property (Microsoft.DirectX.Direct3D)

Retrieves or sets the filter type used for automatically generated sublevels.

Definition

Visual Basic Public Property AutoGenerateFilterType As TextureFilter
C# public TextureFilter AutoGenerateFilterType { get; set; }
C++ public:
property TextureFilter AutoGenerateFilterType {
        TextureFilter get();
        void set(TextureFilter value);
}
JScript public function get AutoGenerateFilterType() : TextureFilter
public function set AutoGenerateFilterType(TextureFilter);

Property Value

Microsoft.DirectX.Direct3D.TextureFilter
A TextureFilter. A texture must be created with Usage.AutoGenerateMipMap to use this property. Any other usage value sets this property to TextureFilter.None.

This property is read/write. 

Remarks

Changing the filter type "dirties" the mipmap sublevels and causes them to be regenerated.

The (default) filter type set at texture creation time is Linear. If the driver does not support a linear filter, the filter type is set to Point. All filter types supported by the driver for regular texture filtering are supported for autogeneration except None. Setting the AutoGenerateFilterType property fails unless the driver sets the appropriate SupportsMinify* caps. These values are specified in the Caps.FilterCaps and/or Caps.CubeTextureFilterCaps members. For more information about texture filter types, see TextureFilter.

If the texture is not created with AutoGenerateMipMap, this method has no effect. In this case, an exception is not thrown. For more information about usage constants, see Usage.

Exceptions

InvalidCallException

The method call is invalid. For example, a parameter might contain an invalid value.

Applies To

CubeTexture, Texture, VolumeTexture

See Also