| 5852 | |
| 5853 | #ifdef LODEPNG_COMPILE_DISK |
| 5854 | unsigned lodepng_encode_file(const char* filename, const unsigned char* image, unsigned w, unsigned h, |
| 5855 | LodePNGColorType colortype, unsigned bitdepth) |
| 5856 | { |
| 5857 | unsigned char* buffer; |
| 5858 | size_t buffersize; |
| 5859 | unsigned error = lodepng_encode_memory(&buffer, &buffersize, image, w, h, colortype, bitdepth); |
| 5860 | if(!error) error = lodepng_save_file(buffer, buffersize, filename); |
| 5861 | lodepng_free(buffer); |
| 5862 | return error; |
| 5863 | } |
| 5864 | |
| 5865 | unsigned lodepng_encode32_file(const char* filename, const unsigned char* image, unsigned w, unsigned h) |
| 5866 | { |
no test coverage detected