/* Write the data to whatever output you are using. The default routine *writestoafilepointer.Notethatthisroutinesometimesgetscalled *withverysmalllengths,soyoushouldimplementsomekindofsimple *bufferingifyouareusingunbufferedwrites.Thisshouldneverbeasked *towritemorethan64Kona16-bitmachine.
*/
void/* PRIVATE */
png_write_data(png_structrp png_ptr, png_const_bytep data, size_t length)
{ /* NOTE: write_data_fn must not change the buffer! */ if (png_ptr->write_data_fn != NULL )
(*(png_ptr->write_data_fn))(png_ptr, png_constcast(png_bytep,data),
length);
else
png_error(png_ptr, "Call to NULL write function");
}
#ifdef PNG_STDIO_SUPPORTED /* This is the function that does the actual writing of data. If you are *notwritingtoastandardCstream,youshouldcreateareplacement *write_datafunctionanduseitatruntimewithpng_set_write_fn(),rather *thanchangingthelibrary.
*/ void PNGCBAPI
png_default_write_data(png_structp png_ptr, png_bytep data, size_t length)
{
size_t check;
if (check != length)
png_error(png_ptr, "Write Error");
} #endif
/* This function is called to output any data pending writing (normally *todisk).Afterpng_flushiscalled,thereshouldbenodatapending *writinginanybuffers.
*/ #ifdef PNG_WRITE_FLUSH_SUPPORTED void/* PRIVATE */
png_flush(png_structrp png_ptr)
{ if (png_ptr->output_flush_fn != NULL)
(*(png_ptr->output_flush_fn))(png_ptr);
}
Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.
Bemerkung:
Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.