PDF generation improved. Now images are rendered correctly.