Class RendContext

3DS Max Plug-In SDK

Class RendContext

See Also: Class ObjLightDesc.

class RendContext

Description:

This class is passed into the method ObjLightDesc::Update(). The methods of this class are implemented by the 3ds max scanline renderer. Developer creating other renderer plug-ins may choose to implement the methods of this class if they wish to use the same architecture. Developers who wish to take advantage of the 3ds max volumetric light effects should implement the methods of this class. The volumetric lights are set up to work with this mechanism.

Methods:

Prototype:

virtual int Progress(int done, int total) const;

Remarks:

Implemented by the Plug-In.

This method is used to update the progress bar and check the keyboard and mouse for user cancellation. A plug-in renderer should implement this method by calling the RendProgressCallback::Progress() method on the RendProgressCallback passed in to the Renderer::Render() method.

Parameters:

int done

This is the number completed so far.

int total

This is the total number of things to complete.

Return Value:

Nonzero to continue; zero if the user has canceled.

Default Implementation:

{ return 1; }

Prototype:

virtual Color GlobalLightLevel() const = 0;

Remarks:

This method is available in release 2.0 and later only.

This is a multiplier that scales the brightness of all scene lights: it doesn't affect the ambient light level. It is included in RendContext so the lights can use it to multiply times the light's color.