IDirect3DBaseTexture9 Interface

 

 

' ****************************************************************************************
' IDirect3DBaseTexture9 interface
' $IID_IDirect3DBaseTexture9 = GUID$("{580CA87E-1D3C-4d54-991D-B7D3E3C298CE}")
' ****************************************************************************************

' ****************************************************************************************
' Applications use the methods of the IDirect3DBaseTexture9 interface to manipulate texture
' resources including cube and volume textures.
' The IDirect3DBaseTexture9 interface assigned to a particular stage for a device is obtained
' by calling the IDirect3DDevice9::GetTexture method.
' Interface Information
'    Stock Implementation   d3d9.dll
'    Custom Implementation  No
'    Inherits from  IDirect3DResource9
'    Header     d3d9.h
'    Import library     d3d9.lib
'    Minimum operating systems  Windows 98
' ****************************************************************************************

' ****************************************************************************************
'DECLARE_INTERFACE_(IDirect3DBaseTexture9, IDirect3DResource9)
'{
'    /*** IUnknown methods ***/
'  0.  STDMETHOD(QueryInterface)(THIS_ REFIID riid, void** ppvObj) PURE;
'  1.  STDMETHOD_(ULONG,AddRef)(THIS) PURE;
'  2.  STDMETHOD_(ULONG,Release)(THIS) PURE;

'    /*** IDirect3DResource9 methods ***/
'  3.  STDMETHOD(GetDevice)(THIS_ IDirect3DDevice9** ppDevice) PURE;
'  4.  STDMETHOD(SetPrivateData)(THIS_ REFGUID refguid,CONST void* pData,DWORD SizeOfData,DWORD Flags) PURE;
'  5.  STDMETHOD(GetPrivateData)(THIS_ REFGUID refguid,void* pData,DWORD* pSizeOfData) PURE;
'  6.  STDMETHOD(FreePrivateData)(THIS_ REFGUID refguid) PURE;
'  7.  STDMETHOD_(DWORD, SetPriority)(THIS_ DWORD PriorityNew) PURE;
'  8.  STDMETHOD_(DWORD, GetPriority)(THIS) PURE;
'  9.  STDMETHOD_(void, PreLoad)(THIS) PURE;
' 10.  STDMETHOD_(D3DRESOURCETYPE, GetType)(THIS) PURE;

'    /*** IDirect3DBaseTexture9 methods ***/
' 11.  STDMETHOD_(DWORD, SetLOD)(THIS_ DWORD LODNew) PURE;
' 12.  STDMETHOD_(DWORD, GetLOD)(THIS) PURE;
' 13.  STDMETHOD_(DWORD, GetLevelCount)(THIS) PURE;
' 14.  STDMETHOD(SetAutoGenFilterType)(THIS_ D3DTEXTUREFILTERTYPE FilterType) PURE;
' 15.  STDMETHOD_(D3DTEXTUREFILTERTYPE, GetAutoGenFilterType)(THIS) PURE;
' 16.  STDMETHOD_(void, GenerateMipSubLevels)(THIS) PURE;
'};
' ****************************************************************************************

' ****************************************************************************************
' SetLOD method
' Sets the most detailed level of detail (LOD) for a managed texture.
' DWORD SetLOD(
'   DWORD LODNew
' );
' ****************************************************************************************
FUNCTION IDirect3DBaseTexture9_SetLOD ALIAS "IDirect3DBaseTexture9_SetLOD" ( _
    BYVAL pthis AS DWORD PTR, BYVAL LODNew AS DWORD) EXPORT AS DWORD

    LOCAL DWRESULT AS DWORD
    IF pthis = %NULL THEN EXIT FUNCTION
    CALL DWORD @@pthis[11] USING IDirect3DBaseTexture9_SetLOD(pthis, LODNew) TO DWRESULT
    FUNCTION = DWRESULT

END FUNCTION
' ****************************************************************************************

' ****************************************************************************************
' GetLOD method
' Returns a value clamped to the maximum level of detail (LOD) set for a managed texture.
' DWORD GetLOD();
' ****************************************************************************************
FUNCTION IDirect3DBaseTexture9_GetLOD ALIAS "IDirect3DBaseTexture9_GetLOD" (BYVAL pthis AS DWORD PTR) EXPORT AS DWORD

    LOCAL DWRESULT AS DWORD
    IF pthis = %NULL THEN EXIT FUNCTION
    CALL DWORD @@pthis[12] USING IDirect3DBaseTexture9_GetLOD(pthis) TO DWRESULT
    FUNCTION = DWRESULT

END FUNCTION
' ****************************************************************************************

' ****************************************************************************************
' GetLevelCount method
' Returns the number of texture levels in a multilevel texture.
' DWORD GetLevelCount();
' ****************************************************************************************
FUNCTION IDirect3DBaseTexture9_GetLevelCount ALIAS "IDirect3DBaseTexture9_GetLevelCount" (BYVAL pthis AS DWORD PTR) EXPORT AS DWORD

    LOCAL DWRESULT AS DWORD
    IF pthis = %NULL THEN EXIT FUNCTION
    CALL DWORD @@pthis[13] USING IDirect3DBaseTexture9_GetLevelCount(pthis) TO DWRESULT
    FUNCTION = DWRESULT

END FUNCTION
' ****************************************************************************************

' ****************************************************************************************
' SetAutoGenFilterType method
' Set the filter type that is used for automatically generated mipmap sublevels.
' HRESULT SetAutoGenFilterType(
'   D3DTEXTUREFILTERTYPE FilterType
' );
' ****************************************************************************************
FUNCTION IDirect3DBaseTexture9_SetAutoGenFilterType ALIAS "IDirect3DBaseTexture9_SetAutoGenFilterType" ( _
    BYVAL pthis AS DWORD PTR, BYVAL FilterType AS DWORD) EXPORT AS LONG

    LOCAL HRESULT AS LONG
    IF pthis = %NULL THEN FUNCTION = %E_POINTER : EXIT FUNCTION
    CALL DWORD @@pthis[14] USING IDirect3DBaseTexture9_SetAutoGenFilterType(pthis, FilterType) TO HRESULT
    FUNCTION = HRESULT

END FUNCTION
' ****************************************************************************************

' ****************************************************************************************
' GetAutoGenFilterType method
' Get the filter type that is used for automatically generated mipmap sublevels.
' D3DTEXTUREFILTERTYPE GetAutoGenFilterType();
' ****************************************************************************************
FUNCTION IDirect3DBaseTexture9_GetAutoGenFilterType ALIAS "IDirect3DBaseTexture9_GetAutoGenFilterType" (BYVAL pthis AS DWORD PTR) EXPORT AS DWORD

    LOCAL DWRESULT AS DWORD
    IF pthis = %NULL THEN EXIT FUNCTION
    CALL DWORD @@pthis[15] USING IDirect3DBaseTexture9_GetAutoGenFilterType(pthis) TO DWRESULT
    FUNCTION = DWRESULT

END FUNCTION
' ****************************************************************************************

' ****************************************************************************************
' GenerateMipSubLevels method
' Generate mipmap sublevels.
' VOID GenerateMipSubLevels();
' ****************************************************************************************
SUB IDirect3DBaseTexture9_GenerateMipSubLevels ALIAS "IDirect3DBaseTexture9_GenerateMipSubLevels" (BYVAL pthis AS DWORD PTR) EXPORT

    IF pthis = %NULL THEN EXIT SUB
    CALL DWORD @@pthis[16] USING IDirect3DBaseTexture9_GenerateMipSubLevels(pthis)

END SUB
' ****************************************************************************************
 

 

Page last updated on Tuesday, 14 March 2006 20:01:41 +0100