TextureLoader.FilterTexture(BaseTexture,PaletteEntry,Int32,Filter) Method (Microsoft.DirectX.Direct3D)
Filters mipmap levels of a texture.
Definition
Visual Basic Public Shared Sub FilterTexture( _
ByVal baseTexture As BaseTexture, _
ByRef palette As PaletteEntry, _
ByVal srcLevel As Integer, _
ByVal filter As Filter _
)C# public static void FilterTexture(
BaseTexture baseTexture,
out PaletteEntry palette,
int srcLevel,
Filter filter
);C++ public:
static void FilterTexture(
BaseTexture^ baseTexture,
[Out] PaletteEntry% palette,
int srcLevel,
Filter filter
);JScript public static function FilterTexture(
baseTexture : BaseTexture,
palette : PaletteEntry,
srcLevel : int,
filter : Filter
);
Parameters
baseTexture Microsoft.DirectX.Direct3D.BaseTexture
A BaseTexture object that represents the texture object to filter.palette Microsoft.DirectX.Direct3D.PaletteEntry[]
Array of PaletteEntry structures that represent a 256-color palette to fill in. For formats that are not palletized, use 0. If a palette is not specified, the default Microsoft Direct3D palette (an all-opaque white palette) is provided. See Remarks.srcLevel System.Int32
Level whose image is used to generate subsequent levels. A common value for this parameter is 0.filter Microsoft.DirectX.Direct3D.Filter
One or more Filter values that control how the mipmap is filtered.
Remarks
A filter is recursively applied to each texture level to generate the next texture level.
Writing to a surface that is not on the "zero" level of the texture does not cause the dirty rectangle to be updated. If FilterTexture is called and the surface is not already dirty (which is unlikely under normal usage scenarios), the application must explicitly call Texture.AddDirtyRectangle on the texture.
Textures created in the default pool (Pool.Default) cannot be used with FilterTexture (unless created with Usage.Dynamic), because a lock operation on the object is necessary. Note that locks are prohibited on textures in the default pool (unless they are dynamic).
Exceptions
The method call is invalid. For example, a method's parameter might contain an invalid value.
The data is invalid.