Newer
Older
Import / research / signals-slots / src / gui / png / main.c
@John John on 29 Dec 2020 371 bytes bulk import from macbookpro checkouts
#include <stdlib.h>
#include <stdio.h>
#include <string.h>
#include <pngdec.h>


int main(int argc, char *argv[])
{
    char *file = "./001.png";
    FILE *f = fopen(file, "r");
    uint8_t data[356296+1024];
    int i = 0;
    while ( fread(data+i, 1, 1, f) == 1 )
        i++;
    PNGDecContext *s = malloc(sizeof(PNGDecContext));
    png_decode_frame(s, data, i);
}