Public Member Functions
GraphicDriver Class Reference

Detailed Description

The GraphicDriver class encapsulates the graphic driver currently set for drawing hardware shaders.

See also:
HardwareShaderContext
Since:
9.0 (2011)

#include <xsi_graphicdriver.h>

Inheritance diagram for GraphicDriver:
Inheritance graph
[legend]

List of all members.

Public Member Functions

 GraphicDriver ()
 ~GraphicDriver ()
 GraphicDriver (const CRef &in_ref)
 GraphicDriver (const GraphicDriver &in_obj)
bool IsA (siClassID in_ClassID) const
siClassID GetClassID () const
GraphicDriveroperator= (const GraphicDriver &in_obj)
GraphicDriveroperator= (const CRef &in_ref)
siGraphicDriver GetGraphicDriverType ()
void * GetHardwareInterface ()
CStatus AddDriverResource (void *in_pRes)

Constructor & Destructor Documentation

Default constructor.

Default destructor.

GraphicDriver ( const CRef in_ref)

Constructor.

Parameters:
in_refconstant reference object.
GraphicDriver ( const GraphicDriver in_obj)

Copy constructor.

Parameters:
in_objconstant class object.

Member Function Documentation

bool IsA ( siClassID  in_ClassID) const [virtual]

Returns true if a given class type is compatible with this API class.

Parameters:
in_ClassIDclass type.
Returns:
true if the class is compatible, false otherwise.

Reimplemented from SIObject.

siClassID GetClassID ( ) const [virtual]

Returns the type of the API class.

Returns:
The class type.

Reimplemented from SIObject.

GraphicDriver& operator= ( const GraphicDriver in_obj)

Creates an object from another object. The newly created object is set to empty if the input object is not compatible.

Parameters:
in_objconstant class object.
Returns:
The new GraphicDriver object.
GraphicDriver& operator= ( const CRef in_ref)

Creates an object from a reference object. The newly created object is set to empty if the input reference object is not compatible.

Parameters:
in_refconstant class object.
Returns:
The new GraphicDriver object.

Reimplemented from SIObject.

siGraphicDriver GetGraphicDriverType ( )

Returns a siGraphicDriver enum indicating the type of graphic driver.

Returns:
The graphic driver type.
void* GetHardwareInterface ( )

Returns a void* which represents the interface to the underlying Graphics API. for OpenGL, this simple returns a HGLRC. For DirectX based divers, you get an IUnknown which can be used to retrieved the DirectX device.

Returns:
Pointer to the hardware graphic interface.
CStatus AddDriverResource ( void *  in_pRes)

Adds a resource to the driver. The implementation and meaning of this method differs from driver to driver. For DirectX9, the parameter is a pointer to an IUnknown. You should use this function when you create a resource that is not automatically managed by the DirectX driver and that needs to be manually restored when the DirectX device is reset. For example, if you create a HLSL shader (ID3DXEffect) in your plugin, you must pass the IUnknown pointer of this effect using AddDriverResource. The driver will then take care of managing the states when the device is released.

Parameters:
Pointerto a resource for a given graphic API type.
Returns:
CStatus::OK for success

The documentation for this class was generated from the following file: