Search code examples
iphonepdfcgpdfdocument

CGPDFScannerCallback -- what does the info parameter point to?


Apple's CGPDFOperatorTable Reference says a PDFOperatorCallback should look like this:

void MyCGPDFOperatorCallback (
   CGPDFScannerRef scanner,
   void *info
);

Parameters

scanner

A CGPDFScanner object. Quartz passes the scanner to your callback function. The scanner contains the PDF content stream that has the PDF operator that corresponds to this callback.

info

A pointer to data passed to the callback.

I am confused what data the info will point to. Is this something I can set somehow? Or does the scanner set it automatically? If so, to what?


Solution

  • It's the info parameter that you passed to the CGPDFScannerCreate function.