This type’s sole purpose is to provide an intermediate buffer for operations that may require it, rather than relying on any internal and implementation-defined buffering or technique to do a conversion. This can allow for optimal conversion rates, especially among bulk conversions performed by the registry-based transcoding APIs.

struct cnc_pivot_info

A structure containing information for a “pivot buffer”.


When a failure happens due to an intermediate conversion failing, the result member of the cnc_pivot_info will be set to a non-cnc_mcerr_ok value reflecting the type of failure that happened within the intermediate conversion.

Public Members

size_t bytes_size

The number of bytes pointed to by bytes.

unsigned char *bytes

A pointer to a byte buffer to use for intermediate conversions.


If this is a null pointer, it signifies that an internal buffer created in some fashion by the implementation should be used instead to perform the conversion. Otherwise, even if the buffer is insufficiently small, it will use this buffer.

cnc_mcerr error

The error code representing any failed conversion specific to the intermediate/pivot step.


If a conversion involving the intermediate buffer / pivot buffer - even the implementation-defined one - fails for any reason, it will be reported in this variable.