Problems exctracting text with PoDoFo

136 Views Asked by At

I am new to PoDoFo and trying to extract the text content of a PDF file with it. I have essentially followed this and it works fine with some PDFs but not with others. That is, std::cout << str << "" prints nothing. I have tried to change if(a[i].IsString()) to if(a[i].IsString() || a[i].IsHexString()) but this doesn't help. Any ideas at all about what could cause this? I'm out of ideas and a bit desperate. I know the text can be extracted with PDFminer.six in Python (and the files are just containing black on white text - nothing fancier) but I'd like to extract the text with with C++. Thanks in advance.

0

There are 0 best solutions below