[Podofo-users] problem drawing images

2012-08-31 Thread Ismael Schellemberg
Greetings, i'm having some problems when trying to draw an image on a PdfPainter objectI'm trying to create an XObject for a stamp annotation, but I must be doing something wrong because the output looks buggyAlso, the output size is about half the size of what it should be. I've tried hardcoding

Re: [Podofo-users] problem drawing images

2012-08-31 Thread Ismael Schellemberg
It is JPEG encoded data, created like this UIImage *scaledImage = ...; NSData *data = UIImageJPEGRepresentation(scaledImage, 1); (the 1 is the compression quality) I've tried using image.LoadFromFile(path.jpg) but it crashes and I can't figure out where. The Library is compiled into a static

Re: [Podofo-users] problem drawing images

2012-08-31 Thread Ismael Schellemberg
With some testing I found that the problem is that I don't have access to the JPEG library, and in PdfFilter.cpp crashes here m_filter = PdfFilterFactory::Create( eFilter ); if( !m_filter.get() ) { PODOFO_RAISE_ERROR( ePdfError_UnsupportedFilter ); }

Re: [Podofo-users] problem drawing images

2012-08-31 Thread Leonard Rosenthol
What is actually stored in data? Is it raw image data or some image format (like PNG or JPEG)? From: Ismael Schellemberg [mailto:isma...@gmail.com] Sent: Friday, August 31, 2012 11:22 AM To: podofo-users@lists.sourceforge.net Subject: [Podofo-users] problem drawing images Greetings, i'm having

Re: [Podofo-users] problem drawing images

2012-08-31 Thread Leonard Rosenthol
Don't use a JPEG - use raw bits. From: Ismael Schellemberg [mailto:isma...@gmail.com] Sent: Friday, August 31, 2012 12:08 PM To: Leonard Rosenthol Cc: podofo-users@lists.sourceforge.net Subject: Re: [Podofo-users] problem drawing images With some testing I found that the problem is that I don't

Re: [Podofo-users] problem drawing images

2012-08-31 Thread Ismael Schellemberg
Ok, i've managed to work it out!!! thanks for all your help!! One problem remains, and it's the output size, which is about half the size I'm creating it If i tell it to draw in (0, 0, 300, 100), it ends up drawing it in (75, 50, 150, 50) (half height, half width, positioned on the lower

Re: [Podofo-users] problem drawing images

2012-08-31 Thread Leonard Rosenthol
Check the rect for the annotation itself and any transforms there. From: Ismael Schellemberg [mailto:isma...@gmail.com] Sent: Friday, August 31, 2012 1:49 PM To: Leonard Rosenthol Cc: podofo-users@lists.sourceforge.net Subject: Re: [Podofo-users] problem drawing images Ok, i've managed to work