3ds Max C++ API Reference
IFrameBufferProcessor Class Referenceabstract

Generic interface for processing the contents of an frame buffer. More...

#include <IFrameBufferProcessor.h>

Classes

class  IFrameBufferReader
 Generic interface for reading frame buffer data. More...
 

Public Member Functions

virtual bool ProcessFrameBuffer (const bool process_tone_operator, const TimeValue t, IFrameBufferReader &frame_buffer_access)=0
 Processes the given frame buffer. More...
 

Protected Member Functions

virtual ~IFrameBufferProcessor ()
 Protected destructor prevents deletion through this interface. More...
 

Detailed Description

Generic interface for processing the contents of an frame buffer.

This interface abstracts functionality for processing the contents of a frame buffer - typically for storing a frame buffer into an output representation. The most common use case should be to transfer the contents of a renderer's internal frame buffer into a 3ds Max Bitmap, in a thread-safe and efficient manner.

Constructor & Destructor Documentation

◆ ~IFrameBufferProcessor()

virtual ~IFrameBufferProcessor ( )
inlineprotectedvirtual

Protected destructor prevents deletion through this interface.

54 {}

Member Function Documentation

◆ ProcessFrameBuffer()

virtual bool ProcessFrameBuffer ( const bool  process_tone_operator,
const TimeValue  t,
IFrameBufferReader frame_buffer_access 
)
pure virtual

Processes the given frame buffer.

The exact behaviour of this method is defined by the particular implementation of this interface. For example, class IRenderSessionContext returns a frame buffer processor which transfers the data to the output Bitmap. But other implementations could, for example, store the result in a render element Bitmap, or to an entirely different output device.

Parameters
process_tone_operatorWhether the active ToneOperator should be applied to the contents of the frame buffer.
tThe time at which the ToneOperator will be evaluated.
frame_buffer_accessThe interface, implemented by the caller, from which the frame buffer data is extracted. The implementation would typically fetch the pixels from the renderer's internal frame buffer.
Returns
True on success. False on error, generally if IFrameBufferReader::GetPixelLine() has returned false.