libscan/test/main.c
2020-03-26 15:30:28 -04:00

28 lines
682 B
C

#include "../libscan/text/text.h"
#include <fcntl.h>
#include "../libscan/arc/arc.h"
#include "../libscan/ebook/ebook.h"
#include "../libscan/ooxml/ooxml.h"
#include "../libscan/font/font.h"
#include <ft2build.h>
#include <freetype/freetype.h>
int main() {
scan_ebook_ctx_t ctx;
ctx.content_size = 100;
vfile_t file;
file.is_fs_file = TRUE;
file.filepath = "/home/simon/Downloads/libscan/CMakeLists.txt";
file.fd = open("/home/simon/Downloads/libscan/CMakeLists.txt", O_RDONLY);
file.read = fs_read;
document_t doc;
doc.meta_head = NULL;
doc.meta_tail = NULL;
doc.size = 200;
parse_ebook(&ctx, &file,"application/pdf", &doc);
}