3ds Max C++ API Reference
IHardwareShader Class Referenceabstract

#include <ihardwareshader.h>

+ Inheritance diagram for IHardwareShader:

Public Member Functions

virtual Interface_ID GetID ()
 
virtual Interface_ID GetVSID ()=0
 
virtual Interface_ID GetPSID ()=0
 
virtual LifetimeType LifetimeControl ()
 
virtual void StartObject (Mesh *mesh)=0
 
virtual void StartObject (MNMesh *mnmesh)=0
 
virtual void InitializeShaders (Mesh *mesh, BaseInterface *pbvs, Material *mtlArray, int numMtl, GFX_ESCAPE_FN fn)=0
 
virtual void InitializeShaders (MNMesh *mnmesh, BaseInterface *pbvs, Material *mtlArray, int numMtl, GFX_ESCAPE_FN fn)=0
 
virtual bool CanTryStrips ()=0
 
virtual DWORD GetRndMode ()=0
 
virtual MaterialGetMaterial (int numMat)=0
 
virtual void SetMaterial (const Material &m, int index=0)=0
 
virtual int GetNumMultiPass (int numMtl)=0
 
virtual void SetNumMultiPass (int numPass)=0
 
virtual void DrawMeshStrips (MeshData *data, GFX_ESCAPE_FN fn)=0
 
virtual void DrawWireMesh (WireMeshData *data, GFX_ESCAPE_FN fn)=0
 
virtual void StartLines (WireMeshData *data)=0
 
virtual void AddLine (DWORD *vert, int vis)=0
 
virtual void DrawLines ()=0
 
virtual void EndLines (GFX_ESCAPE_FN fn)=0
 
virtual void StartTriangles (MeshFaceData *data)=0
 
virtual void AddTriangle (DWORD index, int *edgeVis)=0
 
virtual void DrawTriangles ()=0
 
virtual void EndTriangles (GFX_ESCAPE_FN fn)=0
 
virtual void EndObject (Mesh *mesh)=0
 
virtual void EndObject (MNMesh *mnmesh)=0
 
- Public Member Functions inherited from BaseInterface
virtual UtilExport ~BaseInterface ()
 Destructor. More...
 
UtilExport BaseInterfaceGetInterface (Interface_ID id)
 
virtual bool RegisterNotifyCallback (InterfaceNotifyCallback *incb)
 
virtual void UnRegisterNotifyCallback (InterfaceNotifyCallback *incb)
 
virtual BaseInterfaceAcquireInterface ()
 
virtual void ReleaseInterface ()
 
virtual void DeleteInterface ()
 
virtual BaseInterfaceCloneInterface (void *remapDir=NULL)
 
- Public Member Functions inherited from InterfaceServer
virtual UtilExport ~InterfaceServer ()
 Destructor. More...
 
template<class InterfaceType >
InterfaceType * GetTypedInterface ()
 

Additional Inherited Members

- Public Types inherited from BaseInterface
enum  LifetimeType { noRelease , immediateRelease , wantsRelease , serverControlled }
 
- Static Public Member Functions inherited from MaxHeapOperators
static UtilExport voidoperator new (size_t size)
 Standard new operator used to allocate objects If there is insufficient memory, an exception will be thrown. More...
 
static UtilExport voidoperator new (size_t size, const std::nothrow_t &e)
 Standard new operator used to allocate objects if there is insufficient memory, NULL will be returned. More...
 
static UtilExport voidoperator new (size_t size, const char *filename, int line)
 New operator used to allocate objects that takes the filename and line number where the new was called If there is insufficient memory, an exception will be thrown. More...
 
static UtilExport voidoperator new (size_t size, int block_type, const char *filename, int line)
 New operator used to allocate objects that takes the type of memory, filename and line number where the new was called If there is insufficient memory, an exception will be thrown. More...
 
static UtilExport voidoperator new (size_t size, const std::nothrow_t &e, const char *filename, int line)
 New operator used to allocate objects that takes the filename and line number where the new was called If there is insufficient memory, NULL will be returned. More...
 
static UtilExport voidoperator new (size_t size, unsigned long flags)
 New operator used to allocate objects that takes extra flags to specify special operations If there is insufficient memory, an exception will be thrown. More...
 
static UtilExport voidoperator new (size_t size, const std::nothrow_t &e, unsigned long flags)
 New operator used to allocate objects that takes extra flags to specify special operations If there is insufficient memory, NULL will be returned. More...
 
static UtilExport voidoperator new[] (size_t size)
 New operator used to allocate arrays of objects If there is insufficient memory, an exception will be thrown. More...
 
static UtilExport voidoperator new[] (size_t size, const std::nothrow_t &e)
 New operator used to allocate arrays of objects If there is insufficient memory, NULL will be returned. More...
 
static UtilExport voidoperator new[] (size_t size, const char *filename, int line)
 New operator used to allocate arrays of objects If there is insufficient memory, an exception will be thrown. More...
 
static UtilExport voidoperator new[] (size_t size, int block_type, const char *filename, int line)
 New operator used to allocate arrays of objects. More...
 
static UtilExport voidoperator new[] (size_t size, const std::nothrow_t &e, const char *filename, int line)
 New operator used to allocate arrays of objects If there is insufficient memory, NULL will be returned. More...
 
static UtilExport voidoperator new[] (size_t size, unsigned long flags)
 New operator used to allocate arrays of objects If there is insufficient memory, an exception will be thrown. More...
 
static UtilExport voidoperator new[] (size_t size, const std::nothrow_t &e, unsigned long flags)
 New operator used to allocate arrays of objects If there is insufficient memory, NULL will be returned. More...
 
static UtilExport void operator delete (void *ptr)
 Standard delete operator used to deallocate an object If the pointer is invalid, an exception will be thrown. More...
 
static UtilExport void operator delete (void *ptr, const std::nothrow_t &e)
 Standard delete operator used to deallocate an object If the pointer is invalid, nothing will happen. More...
 
static UtilExport void operator delete (void *ptr, const char *filename, int line)
 Delete operator used to deallocate an object that takes the filename and line number where the delete was called If the pointer is invalid, an exception will be thrown. More...
 
static UtilExport void operator delete (void *ptr, int block_type, const char *filename, int line)
 Delete operator used to deallocate an object that takes the type of memory, filename and line number where the delete was called If the pointer is invalid, an exception will be thrown. More...
 
static UtilExport void operator delete (void *ptr, const std::nothrow_t &e, const char *filename, int line)
 Delete operator used to deallocate an object that takes the filename and line number where the delete was called If the pointer is invalid, nothing will happen. More...
 
static UtilExport void operator delete (void *ptr, unsigned long flags)
 Delete operator used to deallocate an object that takes extra flags to specify special operations If the pointer is invalid, an exception will be thrown. More...
 
static UtilExport void operator delete (void *ptr, const std::nothrow_t &e, unsigned long flags)
 Delete operator used to deallocate an object that takes extra flags to specify special operations If the pointer is invalid, nothing will happen. More...
 
static UtilExport void operator delete[] (void *ptr)
 Standard delete operator used to deallocate an array of objects If the pointer is invalid, an exception will be thrown. More...
 
static UtilExport void operator delete[] (void *ptr, const std::nothrow_t &e)
 Standard delete operator used to deallocate an array of objects If the pointer is invalid, nothing will happen. More...
 
static UtilExport void operator delete[] (void *ptr, const char *filename, int line)
 Delete operator used to deallocate an array of objects that takes the filename and line number where the delete was called If the pointer is invalid, an exception will be thrown. More...
 
static UtilExport void operator delete[] (void *ptr, int block_type, const char *filename, int line)
 Delete operator used to deallocate an array of objects that takes the type of memory, filename and line number where the delete was called If the pointer is invalid, an exception will be thrown. More...
 
static UtilExport void operator delete[] (void *ptr, const std::nothrow_t &e, const char *filename, int line)
 Delete operator used to deallocate an array of objects that takes the filename and line number where the delete was called If the pointer is invalid, nothing will happen. More...
 
static UtilExport void operator delete[] (void *ptr, unsigned long flags)
 Delete operator used to deallocate an array of objects that takes extra flags to specify special operations If the pointer is invalid, an exception will be thrown. More...
 
static UtilExport void operator delete[] (void *ptr, const std::nothrow_t &e, unsigned long flags)
 Delete operator used to deallocate an array of objects that takes extra flags to specify special operations If the pointer is invalid, an exception will be thrown. More...
 
static UtilExport voidoperator new (size_t size, void *placement_ptr)
 Placement new operator. More...
 
static UtilExport void operator delete (void *ptr, void *placement_ptr)
 Placement delete operator. More...
 
static UtilExport voidaligned_malloc (size_t size, size_t alignment)
 Allocates memory on a specified alignment boundary. More...
 
static UtilExport voidaligned_realloc (void *ptr, size_t size, size_t alignment)
 Reallocates memory on a specified alignment boundary. More...
 
static UtilExport void aligned_free (void *ptr)
 Frees a block of memory that was allocated with aligned_malloc/aligned_realloc. More...
 

Member Function Documentation

◆ GetID()

virtual Interface_ID GetID ( )
inlinevirtual
Remarks
This method returns the unique interface ID.

Reimplemented from BaseInterface.

Reimplemented in IHardwareRendererST, and IHardwareRenderer.

#define HARDWARE_SHADER_INTERFACE_ID
Definition: ihardwareshader.h:31

◆ GetVSID()

virtual Interface_ID GetVSID ( )
pure virtual

◆ GetPSID()

virtual Interface_ID GetPSID ( )
pure virtual

◆ LifetimeControl()

virtual LifetimeType LifetimeControl ( )
inlinevirtual
Remarks
This method allows inquiries into the actual lifetime policy of a client and provide a server-controlled delete notify callback.
Returns
One of the following LifetimeTypes:

noRelease

Do not call release, use interface as long as you like. This is the default.

immediateRelease

The interface is only good for one call. The release is implied so a call to release is not required.

wantsRelease

The clients are controlling the lifetime, so the interface needs a Release() when the client has finished.

serverControlled

The server controls the lifetime and will use the InterfaceNotifyCallback to inform the code when it is gone.
Default Implementation:
{ return noRelease; }

Reimplemented from BaseInterface.

Reimplemented in IHardwareRenderer.

291 { return noRelease; }
@ noRelease
Definition: baseinterface.h:104

◆ StartObject() [1/2]

virtual void StartObject ( Mesh mesh)
pure virtual

◆ StartObject() [2/2]

virtual void StartObject ( MNMesh mnmesh)
pure virtual

◆ InitializeShaders() [1/2]

virtual void InitializeShaders ( Mesh mesh,
BaseInterface pbvs,
Material mtlArray,
int  numMtl,
GFX_ESCAPE_FN  fn 
)
pure virtual

◆ InitializeShaders() [2/2]

virtual void InitializeShaders ( MNMesh mnmesh,
BaseInterface pbvs,
Material mtlArray,
int  numMtl,
GFX_ESCAPE_FN  fn 
)
pure virtual

◆ CanTryStrips()

virtual bool CanTryStrips ( )
pure virtual

◆ GetRndMode()

virtual DWORD GetRndMode ( )
pure virtual

◆ GetMaterial()

virtual Material* GetMaterial ( int  numMat)
pure virtual

◆ SetMaterial()

virtual void SetMaterial ( const Material m,
int  index = 0 
)
pure virtual

◆ GetNumMultiPass()

virtual int GetNumMultiPass ( int  numMtl)
pure virtual

◆ SetNumMultiPass()

virtual void SetNumMultiPass ( int  numPass)
pure virtual

◆ DrawMeshStrips()

virtual void DrawMeshStrips ( MeshData data,
GFX_ESCAPE_FN  fn 
)
pure virtual

◆ DrawWireMesh()

virtual void DrawWireMesh ( WireMeshData data,
GFX_ESCAPE_FN  fn 
)
pure virtual

◆ StartLines()

virtual void StartLines ( WireMeshData data)
pure virtual

◆ AddLine()

virtual void AddLine ( DWORD *  vert,
int  vis 
)
pure virtual

◆ DrawLines()

virtual void DrawLines ( )
pure virtual

◆ EndLines()

virtual void EndLines ( GFX_ESCAPE_FN  fn)
pure virtual

◆ StartTriangles()

virtual void StartTriangles ( MeshFaceData data)
pure virtual

◆ AddTriangle()

virtual void AddTriangle ( DWORD  index,
int edgeVis 
)
pure virtual

◆ DrawTriangles()

virtual void DrawTriangles ( )
pure virtual

◆ EndTriangles()

virtual void EndTriangles ( GFX_ESCAPE_FN  fn)
pure virtual

◆ EndObject() [1/2]

virtual void EndObject ( Mesh mesh)
pure virtual

◆ EndObject() [2/2]

virtual void EndObject ( MNMesh mnmesh)
pure virtual