png_read_info (png_ptr, info_ptr);
{
png_byte color_type = info_ptr->color_type;
png_byte bit_depth = info_ptr->bit_depth;
...
對於最後兩行,我得到了libpng 1.5.10錯誤:提領指向不完全類型
error: dereferencing pointer to incomplete type
有什麼不對?在libpng 1.4中,這總是好的。
這意味着您還沒有正確的頭。包括 – Shahbaz
@Shahbaz'png.h'。 '-I/usr/include/libpng15'存在。 – askovpen