WorkProc method

Called in a response to the IDXTransform::Execute method to render a portion of the output space to the current output surface.

Syntax


HRESULT retVal = object.WorkProc(WorkInfo, pbContinueProcessing);

Parameters

WorkInfo [in, ref]

Type: const CDXTWorkInfoNTo1

CDXTWorkInfoNTo1 object used to describe the rendering request.

pbContinueProcessing [in]

Type: BOOL

Pointer to a Boolean value that is managed externally by the IDXTaskManager interface to control execution of this function. At the start of the method, you should check this value to determine if execution is being prematurely canceled. If TRUE, the work procedure should clean up and exit immediately.

Remarks

This function can be called simultaneously on multiple threads for a given data request. The base class can divide a data request into multiple pieces to be executed on all available processors. If this function is not reentrant, the m_ulMaxImageBands data member must be set to 1 in the FinalConstruct constructor method to assure that this function is called only once per execution request on a single thread. Because the work procedure must be able to render any region of the output space, parallelization on multiprocessor computers is automatic for the developer, as long as the work procedure is reentrant.

 

 

Show: