Diligent Engine API Reference
Public Member Functions | List of all members
Diligent::ITextureView Class Referenceabstract

Texture view interface. More...

Inheritance diagram for Diligent::ITextureView:
Diligent::IDeviceObject Diligent::ITextureViewD3D11 Diligent::ITextureViewD3D12 Diligent::ITextureViewGL Diligent::RefCountedObject< ITextureViewD3D11 > Diligent::RefCountedObject< ITextureViewD3D12 > Diligent::RefCountedObject< ITextureViewGL > Diligent::ObjectBase< ITextureViewD3D11 > Diligent::ObjectBase< ITextureViewD3D12 > Diligent::ObjectBase< ITextureViewGL > Diligent::DeviceObjectBase< ITextureViewD3D11, TextureViewDesc > Diligent::DeviceObjectBase< ITextureViewD3D12, TextureViewDesc > Diligent::DeviceObjectBase< ITextureViewGL, TextureViewDesc > Diligent::TextureViewBase< ITextureViewD3D11 > Diligent::TextureViewBase< ITextureViewD3D12 > Diligent::TextureViewBase< ITextureViewGL > Diligent::TextureViewD3D11Impl Diligent::TextureViewD3D12Impl Diligent::TextureViewGLImpl

Public Member Functions

virtual void QueryInterface (const Diligent::INTERFACE_ID &IID, IObject **ppInterface)=0
 Queries the specific interface, see IObject::QueryInterface() for details.
 
virtual const TextureViewDescGetDesc () const =0
 Returns the texture view description used to create the object.
 
virtual void SetSampler (class ISampler *pSampler)=0
 Sets the texture sampler to use for filtering operations when accessing a texture from shaders. Only shader resource views can be assigned a sampler. The view will keep strong reference to the sampler.
 
virtual ISamplerGetSampler ()=0
 Returns the pointer to the sampler object set by the ITextureView::SetSampler(). More...
 
virtual class ITextureGetTexture ()=0
 Returns the pointer to the referenced texture object. More...
 
virtual void GenerateMips (IDeviceContext *pContext)=0
 Generates a mipmap chain. More...
 
- Public Member Functions inherited from Diligent::IDeviceObject
virtual void QueryInterface (const INTERFACE_ID &IID, IObject **ppInterface)=0
 Queries the specific interface, see IObject::QueryInterface() for details.
 

Detailed Description

Texture view interface.

Remarks
To create a texture view, call ITexture::CreateView(). Texture view holds strong references to the texture. The texture will not be destroyed until all views are released. The texture view will also keep a strong reference to the texture sampler, if any is set.

Member Function Documentation

◆ GenerateMips()

virtual void Diligent::ITextureView::GenerateMips ( IDeviceContext pContext)
pure virtual

Generates a mipmap chain.

Remarks
This function can only be called for a shader resource view The texture must be created with MISC_TEXTURE_FLAG_GENERATE_MIPS flag

Implemented in Diligent::TextureViewD3D11Impl, Diligent::TextureViewGLImpl, and Diligent::TextureViewD3D12Impl.

◆ GetSampler()

virtual ISampler* Diligent::ITextureView::GetSampler ( )
pure virtual

Returns the pointer to the sampler object set by the ITextureView::SetSampler().

The method does NOT call AddRef() on the returned interface, so Release() must not be called.

Implemented in Diligent::TextureViewBase< ITextureViewD3D11 >, Diligent::TextureViewBase< ITextureViewD3D12 >, and Diligent::TextureViewBase< ITextureViewGL >.

◆ GetTexture()

virtual class ITexture* Diligent::ITextureView::GetTexture ( )
pure virtual

Returns the pointer to the referenced texture object.

The method does NOT call AddRef() on the returned interface, so Release() must not be called.

Implemented in Diligent::TextureViewBase< ITextureViewD3D11 >, Diligent::TextureViewBase< ITextureViewD3D12 >, and Diligent::TextureViewBase< ITextureViewGL >.