TIFFWRITEENCODEDSTRIP(3tiff) LibTIFF TIFFWRITEENCODEDSTRIP(3tiff) NNAAMMEE TIFFWriteEncodedStrip - compress and write a strip of data to an open TIFF file SSYYNNOOPPSSIISS #include ttssiizzee__tt TTIIFFFFWWrriitteeEEnnccooddeeddSSttrriipp((TTIIFFFF **ttiiff,, ttssttrriipp__tt ssttrriipp,, ttddaattaa__tt bbuuff,, ttssiizzee__tt ssiizzee)) DDEESSCCRRIIPPTTIIOONN Compress _s_i_z_e bytes of raw data from _b_u_f and write the result to the specified strip; replacing any previously written data. Note that the value of _s_t_r_i_p is a raw strip number. That is, the caller must take into account whether or not the data are organized in separate planes (PPllaannaarrCCoonnffiigguurraattiioonn = 2). NNOOTTEESS The library writes encoded data using the native machine byte order. Correctly implemented TIFF readers are expected to do any necessary byte-swapping to correctly process image data with BBiittssPPeerrSSaammppllee greater than 8. The strip number must be valid according to the current settings of the IImmaaggeeLLeennggtthh and RRoowwssPPeerrSSttrriipp tags. An image may be dynamically grown by increasing the value of IImmaaggeeLLeennggtthh prior to each call to TTIIFFFFWWrriitteeEEnnccooddeeddSSttrriipp. RREETTUURRNN VVAALLUUEESS -1 is returned if an error was encountered. Otherwise, the value of _s_i_z_e is returned. DDIIAAGGNNOOSSTTIICCSS All error messages are directed to the _T_I_F_F_E_r_r_o_r_E_x_t_R_(_) routine. %%ss:: FFiillee nnoott ooppeenn ffoorr wwrriittiinngg: The file was opened for reading, not writing. CCaann nnoott wwrriittee ssccaannlliinneess ttoo aa ttiilleedd iimmaaggee: The image is assumed to be organized in tiles because the TTiilleeWWiiddtthh and TTiilleeLLeennggtthh tags have been set with _T_I_F_F_S_e_t_F_i_e_l_d_(_). %%ss:: MMuusstt sseett ""IImmaaggeeWWiiddtthh"" bbeeffoorree wwrriittiinngg ddaattaa\\ffPP: The images width has not be set before the first write. See _T_I_F_F_S_e_t_F_i_e_l_d_(_) for information on how to do this. %%ss:: MMuusstt sseett ""PPllaannaarrCCoonnffiigguurraattiioonn"" bbeeffoorree wwrriittiinngg ddaattaa: The organization of data has not be defined before the first write. See _T_I_F_F_S_e_t_F_i_e_l_d_(_) for information on how to do this. %%ss:: NNoo ssppaaccee ffoorr ssttrriipp aarrrraayyss"": There was not enough space for the arrays that hold strip offsets and byte counts. SSEEEE AALLSSOO _T_I_F_F_O_p_e_n (3tiff), _T_I_F_F_W_r_i_t_e_S_c_a_n_l_i_n_e (3tiff), _T_I_F_F_W_r_i_t_e_R_a_w_S_t_r_i_p (3tiff), _l_i_b_t_i_f_f (3tiff) AAUUTTHHOORR LibTIFF contributors CCOOPPYYRRIIGGHHTT 1988-2022, LibTIFF contributors 4.6 Sep 08, 2023 TIFFWRITEENCODEDSTRIP(3tiff)